diff --git a/.eslintignore b/.eslintignore index 30c8653ae8..7df5c928c1 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,3 +1,6 @@ -webpack/* -karma.conf.js -tests.webpack.js +node_modules +build +packages/volto +packages/volto-guillotina +!.* +dist diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index 2afd91328b..0000000000 --- a/.eslintrc +++ /dev/null @@ -1,60 +0,0 @@ -{ - "extends": ["react-app", "prettier", "plugin:jsx-a11y/recommended"], - "plugins": ["prettier", "react-hooks", "jsx-a11y"], - "env": { - "es6": true, - "browser": true, - "node": true, - "mocha": true, - "jasmine": true - }, - "parser": "babel-eslint", - "parserOptions": { - "ecmaVersion": 6, - "sourceType": "module", - "ecmaFeatures": { - "legacyDecorators": true - } - }, - "rules": { - "import/no-unresolved": 1, - "no-alert": 1, - "no-console": 1, - "no-debugger": 1, - "prettier/prettier": [ - "error", - { "trailingComma": "all", "singleQuote": true } - ], - "react-hooks/rules-of-hooks": "error", - "react-hooks/exhaustive-deps": "warn", - "react/react-in-jsx-scope": "off" - }, - "settings": { - "import/resolver": { - "alias": { - "map": [["@plone/volto", "./src"], ["@package", "./src"], ["@root", "./src"]], - "extensions": [".js", ".jsx", ".json"] - }, - "babel-plugin-root-import": { - "rootPathSuffix": "src" - } - }, - "import/core-modules": [ "load-volto-addons" ] - }, - "globals": { - "root": true, - "__DEVELOPMENT__": true, - "__CLIENT__": true, - "__SERVER__": true, - "__DISABLE_SSR__": true, - "__DEVTOOLS__": true, - "__DEBUG__": true, - "__SSR__": true, - "__SENTRY__": true, - "cy": true, - "Cypress": true, - "jest": true, - "socket": true, - "webpackIsomorphicTools": true - } -} diff --git a/.eslintrc.cjs b/.eslintrc.cjs new file mode 100644 index 0000000000..3a87903fb1 --- /dev/null +++ b/.eslintrc.cjs @@ -0,0 +1,76 @@ +// @ts-check + +/** @type {import('eslint').Linter.Config} */ +const config = { + parser: '@typescript-eslint/parser', // Specifies the ESLint parser + parserOptions: { + ecmaVersion: 'ESNext', // Allows for the parsing of modern ECMAScript features + sourceType: 'module', // Allows for the use of imports + ecmaFeatures: { + jsx: true, // Allows for the parsing of JSX + }, + }, + rules: { + // 'import/no-unresolved': ['error', { ignore: ['^@plone/'] }], + // 'import/extensions': 'off', + // Place to specify ESLint rules. Can be used to overwrite rules specified from the extended configs + // e.g. "@typescript-eslint/explicit-function-return-type": "off", + }, + settings: { + react: { + version: 'detect', // Tells eslint-plugin-react to automatically detect the version of React to use + }, + settings: { + 'import/parsers': { + '@typescript-eslint/parser': ['.ts', '.tsx'], + }, + 'import/resolver': { + // node: { + // extensions: ['.js', '.jsx', '.ts', '.tsx'], + // }, + typescript: { + alwaysTryTypes: true, // always try to resolve types under `@types` directory even it doesn't contain any source code, like `@types/unist` + + // use an array of glob patterns + project: [ + 'packages/*/tsconfig.json', + // 'other-packages/*/tsconfig.json', + ], + }, + }, + }, + }, + overrides: [ + { + files: ['**/*.ts', '**/*.tsx'], + plugins: ['@typescript-eslint', 'import'], + extends: [ + 'plugin:react/recommended', + // 'plugin:@typescript-eslint/eslint-recommended', + // 'plugin:@typescript-eslint/recommended', + // 'plugin:import/recommended', + 'plugin:import/typescript', + 'plugin:prettier/recommended', + 'plugin:react/jsx-runtime', + // 'plugin:storybook/recommended', + ], + }, + { + files: ['**/*.js', '**/*.jsx'], + plugins: ['import'], + extends: [ + 'plugin:react/recommended', + // 'plugin:import/recommended', + 'plugin:prettier/recommended', + 'plugin:react/jsx-runtime', + // 'plugin:storybook/recommended', + ], + rules: { + 'react/prop-types': 0, + 'react/no-unescaped-entities': 0, + }, + }, + ], +}; + +module.exports = config; diff --git a/.github/ISSUE_TEMPLATE/PLIP.md b/.github/ISSUE_TEMPLATE/PLIP.md new file mode 100644 index 0000000000..ba65da284c --- /dev/null +++ b/.github/ISSUE_TEMPLATE/PLIP.md @@ -0,0 +1,64 @@ +--- +name: "\U0001F680 PLIP" +about: Plone Improvement Proposal +title: '' +labels: '' +assignees: '' + +--- + +## PLIP (Plone Improvement Proposal) + + + +## Responsible Persons + +### Proposer: + +### Seconder: + +## Abstract + + + +## Motivation + + + +## Assumptions + + + +## Proposal & Implementation + + + +## Deliverables + + + +## Risks + + + +## Participants + + diff --git a/.github/workflows/acceptance.yml b/.github/workflows/acceptance.yml new file mode 100644 index 0000000000..01d88d3e6e --- /dev/null +++ b/.github/workflows/acceptance.yml @@ -0,0 +1,1232 @@ +name: Acceptance Tests +on: [push, pull_request] +jobs: + core: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Basic + timeout-minutes: 45 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + # We don't want to install until later, + # when the cache and Cypress are in place + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/basic/**/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + corecontent: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Content + timeout-minutes: 45 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/content/**/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + corecontrolpanels: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Control Panels + timeout-minutes: 45 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/controlpanels/**/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + coreblocks: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Blocks + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/blocks/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + coreblockslisting: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Blocks - Listing + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/blocks/listing/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + corevoltoslate: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Volto Slate + timeout-minutes: 45 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/volto-slate/**/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + core5: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Core Basic - Plone 5 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/basic/**/*.js + start: | + make start-test-acceptance-server-5 + make start-test-acceptance-frontend + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + coresandbox: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Coresandbox + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress Coresandbox Acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/coresandbox/**/*.js + start: | + make start-test-acceptance-server-coresandbox + make start-test-acceptance-frontend-coresandbox + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + # guillotina: + # if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + # name: Guillotina + # runs-on: ubuntu-latest + # timeout-minutes: 35 + # strategy: + # fail-fast: false + # matrix: + # node-version: [18.x] + # steps: + # - uses: actions/checkout@v4 + + # # node setup + # - name: Use Node.js ${{ matrix.node-version }} + # uses: actions/setup-node@v4 + # with: + # node-version: ${{ matrix.node-version }} + + # - uses: pnpm/action-setup@v3 + # name: Install pnpm + # with: + # version: 8 + # run_install: false + + # - name: Get pnpm store directory + # shell: bash + # run: | + # echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + # - uses: actions/cache@v4 + # name: Setup pnpm cache + # with: + # path: ${{ env.STORE_PATH }} + # key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + # restore-keys: | + # ${{ runner.os }}-pnpm-store- + + # - run: pnpm i + + # - name: Cypress acceptance tests + # uses: cypress-io/github-action@v6 + # env: + # BABEL_ENV: production + # CYPRESS_API: guillotina + # CYPRESS_RETRIES: 2 + # # Recommended: pass the GitHub token lets this action correctly + # # determine the unique run id necessary to re-run the checks + # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # with: + # install: false + # working-directory: packages/volto + # browser: chrome + # spec: cypress/tests/guillotina/**/*.js + # start: | + # make start-test-acceptance-server-guillotina + # make start-test-acceptance-frontend-guillotina + # wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:8081 http://127.0.0.1:3000' + + # # Upload Cypress screenshots + # - uses: actions/upload-artifact@v1 + # if: failure() + # with: + # name: cypress-screenshots + # path: packages/volto/cypress/screenshots + # # Upload Cypress videos + # - uses: actions/upload-artifact@v1 + # if: failure() + # with: + # name: cypress-videos + # path: packages/volto/cypress/videos + + multilingual: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Multilingual + runs-on: ubuntu-latest + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/multilingual/**/*.js + start: | + make start-test-acceptance-server-multilingual + make start-test-acceptance-frontend-multilingual + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + workingcopy: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Working Copy + runs-on: ubuntu-latest + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + # python-version: [3.7] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + # # python setup (temporary, while p.a.iterate changes are in a PR) + # - name: Set up Python ${{ matrix.python-version }} + # uses: actions/setup-python@v1 + # with: + # python-version: ${{ matrix.python-version }} + + # # python cache + # - uses: actions/cache@v1 + # with: + # path: ~/.cache/pip + # key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} + # restore-keys: | + # ${{ runner.os }}-pip- + # # python install + # - run: pip install virtualenv + # - name: pip install + # working-directory: api + # run: pip install -r requirements.txt + # - name: buildout + # working-directory: api + # run: buildout + # env: + # CI: true + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/workingCopy/**/*.js + start: | + make start-test-acceptance-server-workingcopy + make start-test-acceptance-frontend-workingcopy + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + generator: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Project Generator + runs-on: ubuntu-latest + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + env: + generator-directory: ./packages/generator-volto + project-directory: ./my-volto-app + + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Build packages + run: pnpm build:registry + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + # Generator own tests + - name: Generator tests + run: pnpm test + working-directory: ${{env.generator-directory}} + + # install Yeoman and the generator + - run: npm -g install yo + working-directory: ${{env.generator-directory}} + - run: npm -g install ./ + working-directory: ${{env.generator-directory}} + + # create a project + - run: yo @plone/volto my-volto-app --description "test volto project" --volto . --skip-install --no-interactive + # When main is canary, make sure we use it in the generator + # - run: yo @plone/volto my-volto-app --description "test volto project" --volto . --skip-install --no-interactive --canary + + - name: Install yalc + run: npm -g install yalc + + - name: Install a yalc'ed version of the current Volto in the project - publish + run: | + yalc publish packages/types + (cd packages/registry && yalc add @plone/types --no-pure && yalc publish) + yalc publish packages/scripts + yalc publish packages/volto-slate + (cd packages/volto && yalc add @plone/scripts --no-pure && yalc add @plone/registry --no-pure && yalc add @plone/volto-slate --no-pure && yalc publish) + - name: Install a yalc'ed version of the current Volto in the project - add + run: | + yalc add @plone/volto --no-pure + working-directory: ${{env.project-directory}} + - name: Install a yalc'ed version of the current Volto in the project - install + run: yarn config set -H enableImmutableInstalls false && yarn + working-directory: ${{env.project-directory}} + + - name: Running lint on a project works + run: yarn lint + working-directory: ${{env.project-directory}} + + - name: Running prettier on a project works + run: yarn prettier + working-directory: ${{env.project-directory}} + + - name: Running stylelint on a project works + run: yarn stylelint + working-directory: ${{env.project-directory}} + + - name: Build Storybook + run: yarn build-storybook + working-directory: ${{env.project-directory}} + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/minimal/**/*.js + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend-project + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos + + - name: Test if npm packs correctly + run: npm pack --dry-run + if: success() + working-directory: ${{env.generator-directory}} + + seamless: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Seamless Mode + runs-on: ubuntu-latest + timeout-minutes: 35 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/core/basic/**/*.js + config: baseUrl=http://localhost + start: | + make start-test-acceptance-server + make start-test-acceptance-frontend-seamless + make start-test-acceptance-webserver-seamless + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000 http://localhost' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos-seamless + path: packages/volto/cypress/videos + + multilingualseamless: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Multilingual in Seamless Mode + runs-on: ubuntu-latest + timeout-minutes: 25 + strategy: + fail-fast: false + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Cache Cypress Binary + id: cache-cypress-binary + uses: actions/cache@v4 + with: + path: ~/.cache/Cypress + key: binary-${{ matrix.node-version }}-${{ hashFiles('pnpm-lock.yaml') }} + + - run: pnpm i + + - name: Install Cypress if not in cache + if: steps.cache-cypress-binary.outputs.cache-hit != 'true' + working-directory: packages/volto + run: make cypress-install + + - name: Cypress acceptance tests + uses: cypress-io/github-action@v6 + env: + BABEL_ENV: production + CYPRESS_RETRIES: 2 + # Recommended: pass the GitHub token lets this action correctly + # determine the unique run id necessary to re-run the checks + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + install: false + working-directory: packages/volto + browser: chrome + spec: cypress/tests/multilingual/**/*.js + config: baseUrl=http://localhost + start: | + make start-test-acceptance-server-seamless-multilingual + make start-test-acceptance-frontend-seamless-multilingual + make start-test-acceptance-webserver-seamless + wait-on: 'npx wait-on --httpTimeout 20000 http-get://127.0.0.1:55001/plone http://127.0.0.1:3000 http://localhost' + + # Upload Cypress screenshots + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-screenshots + path: packages/volto/cypress/screenshots + # Upload Cypress videos + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: cypress-videos + path: packages/volto/cypress/videos diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml new file mode 100644 index 0000000000..04b8739752 --- /dev/null +++ b/.github/workflows/changelog.yml @@ -0,0 +1,117 @@ +name: Changelog check +on: + pull_request: + types: [assigned, opened, synchronize, reopened, labeled, unlabeled] + branches: + - main + +env: + node-version: 20.x + +jobs: + towncrier: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + # Fetch all history + fetch-depth: '0' + + - name: Install towncrier + run: pip install towncrier + + - uses: dorny/paths-filter@v2 + id: filter + with: + filters: | + volto: + - 'packages/volto/**' + client: + - 'packages/client/**' + registry: + - 'packages/registry/**' + components: + - 'packages/components/**' + types: + - 'packages/types/**' + generator: + - 'packages/generator-volto/**' + scripts: + - 'packages/scripts/**' + voltoSlate: + - 'packages/volto-slate/**' + wrongNews: + - added|modified: 'news/**' + + - name: Volto changelog check + if: steps.filter.outputs.volto == 'true' + run: | + # Fetch the pull request' base branch so towncrier will be able to + # compare the current branch with the base branch. + # Source: https://github.com/actions/checkout/#fetch-all-branches. + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/volto + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Client changelog check + if: steps.filter.outputs.client == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/client + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Registry changelog check + if: steps.filter.outputs.registry == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/registry + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Components changelog check + if: steps.filter.outputs.components == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/components + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Types changelog check + if: steps.filter.outputs.types == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/types + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Generator changelog check + if: steps.filter.outputs.generator == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/generator-volto + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: scripts changelog check + if: steps.filter.outputs.scripts == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/scripts + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: volto-slate changelog check + if: steps.filter.outputs.voltoSlate == 'true' + run: | + git fetch --no-tags origin main + towncrier check --compare-with origin/main --dir packages/volto-slate + env: + BASE_BRANCH: ${{ github.base_ref }} + + - name: Wrong location of news changelog check + if: steps.filter.outputs.wrongNews == 'true' + run: echo "News items should be moved from the repository root to the appropriate package root in `packages/package-name`." && exit 1 + env: + BASE_BRANCH: ${{ github.base_ref }} diff --git a/.github/workflows/code-analysis.yml b/.github/workflows/code-analysis.yml index ea14029782..a4dad86bde 100644 --- a/.github/workflows/code-analysis.yml +++ b/.github/workflows/code-analysis.yml @@ -1,40 +1,160 @@ name: Code Analysis Check -on: [push] +on: [push, pull_request] + +env: + node-version: 20.x + jobs: - build: + prettier: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Prettier runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 + - name: Use Node.js ${{ env.node-version }} + uses: actions/setup-node@v4 with: - node-version: ${{ matrix.node-version }} + node-version: ${{ env.node-version }} - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) + - uses: pnpm/action-setup@v3 + name: Install pnpm with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} restore-keys: | - ${{ runner.os }}-yarn- + ${{ runner.os }}-pnpm-store- - # node install - - run: yarn install --frozen-lockfile + - run: pnpm i - # node code analysis - name: Prettier check - run: yarn run prettier - - name: ESlint check - run: yarn run lint + run: pnpm prettier + + eslint: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: ESlint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ env.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ env.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - name: Main ESlint check + run: pnpm lint + + - name: Volto ESlint check + run: pnpm lint:volto + + stylelint: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: Stylelint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ env.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ env.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - name: Volto Stylelint check + run: pnpm --filter @plone/volto stylelint + + - name: Components Stylelint check + run: pnpm --filter @plone/components stylelint + + i18n: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: i18n + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ env.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ env.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + - name: i18n locales in sync - run: yarn run i18n:ci + run: pnpm i18n:ci diff --git a/.github/workflows/core.yml b/.github/workflows/core.yml deleted file mode 100644 index ea4aa3deb5..0000000000 --- a/.github/workflows/core.yml +++ /dev/null @@ -1,62 +0,0 @@ -name: Core Main Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [12.x, 14.x, 16.x] - python-version: [3.7] - steps: - - uses: actions/checkout@v2 - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # node install - - run: yarn install --frozen-lockfile - - # node test - - run: yarn i18n - - run: yarn test:ci - - # # cypress acceptance tests - # - name: Cypress acceptance tests - # uses: cypress-io/github-action@v1 - - - name: Cypress acceptance tests - run: yarn ci:cypress:run - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos - - # Bundlewatch - - uses: jackyef/bundlewatch-gh-action@master - with: - bundlewatch-github-token: ${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }} - diff --git a/.github/workflows/coresandbox.yml b/.github/workflows/coresandbox.yml deleted file mode 100644 index 4a2b7aae95..0000000000 --- a/.github/workflows/coresandbox.yml +++ /dev/null @@ -1,75 +0,0 @@ -name: Core Sandbox Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] - steps: - - uses: actions/checkout@v2 - - name: debug - working-directory: api - run: ls -al - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # node install - - run: yarn install --frozen-lockfile - - # python setup (temporary, while p.volto code-sandbox changes are in a PR) - # - name: Set up Python ${{ matrix.python-version }} - # uses: actions/setup-python@v1 - # with: - # python-version: ${{ matrix.python-version }} - - # # python cache - # - uses: actions/cache@v1 - # with: - # path: ~/.cache/pip - # key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} - # restore-keys: | - # ${{ runner.os }}-pip- - # # python install - # - run: pip install virtualenv - # - name: pip install - # working-directory: api - # run: pip install -r requirements.txt - # - name: buildout - # working-directory: api - # run: buildout - # env: - # CI: true - - - name: Cypress Core Sandbox Acceptance Tests - run: yarn ci:cypress:run:coresandbox - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos diff --git a/.github/workflows/deployment_tests.yml b/.github/workflows/deployment_tests.yml new file mode 100644 index 0000000000..7324662881 --- /dev/null +++ b/.github/workflows/deployment_tests.yml @@ -0,0 +1,197 @@ +name: Deployment Tests +on: [push, pull_request] +jobs: + vitessr: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Vite SSR + timeout-minutes: 5 + strategy: + fail-fast: false + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js 20.x + uses: actions/setup-node@v4 + with: + node-version: 20.x + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + # We don't want to install until later, + # when the cache and Cypress are in place + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + - name: Build packages + run: pnpm build:deps && pnpm build:components + + - name: Start backend + run: make start-backend-docker-detached + + - name: Build + run: pnpm --filter plone-vite-ssr build + + - name: Start server + run: nohup pnpm --filter plone-vite-ssr start:prod & + + - name: Wait + run: packages/scripts/node_modules/.bin/wait-on --httpTimeout 20000 http-get://127.0.0.1:8080/Plone + + - name: Run tests + run: curl http://localhost:3000 || true + + - name: Run tests + run: curl http://127.0.0.1:3000 || true + + - name: Run tests + run: node packages/scripts/check_deployment.js + + - name: Stop backend + run: make stop-backend-docker-detached + + nextjs: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Next.JS + timeout-minutes: 5 + strategy: + fail-fast: false + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js 20.x + uses: actions/setup-node@v4 + with: + node-version: 20.x + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + # We don't want to install until later, + # when the cache and Cypress are in place + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + - name: Build packages + run: pnpm build:deps && pnpm build:components + + - name: Start backend + run: make start-backend-docker-detached + + - name: Build + run: pnpm --filter plone-nextjs build + + - name: Start server + run: nohup pnpm --filter plone-nextjs start:prod & + + - name: Wait + run: packages/scripts/node_modules/.bin/wait-on --httpTimeout 20000 http-get://127.0.0.1:8080/Plone + + - name: Run tests + run: curl http://localhost:3000 || true + + - name: Run tests + run: curl http://127.0.0.1:3000 || true + + - name: Run tests + run: node packages/scripts/check_deployment.js + + - name: Stop backend + run: make stop-backend-docker-detached + + remix: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + runs-on: ubuntu-latest + name: Remix + timeout-minutes: 5 + strategy: + fail-fast: false + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js 20.x + uses: actions/setup-node@v4 + with: + node-version: 20.x + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + # We don't want to install until later, + # when the cache and Cypress are in place + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + - name: Build packages + run: pnpm build:deps && pnpm build:components + + - name: Start backend + run: make start-backend-docker-detached + + - name: Build + run: pnpm --filter plone-remix build + + - name: Start server + run: nohup pnpm --filter plone-remix start:prod & + + - name: Wait + run: packages/scripts/node_modules/.bin/wait-on --httpTimeout 20000 http-get://127.0.0.1:8080/Plone + + - name: Run tests + run: node packages/scripts/check_deployment.js + + - name: Stop backend + run: make stop-backend-docker-detached diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 59338eb266..20ddb58092 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -2,44 +2,47 @@ name: Documentation on: push: branches: - - master + - main paths: - 'docs/**' # Build pull requests pull_request: paths: - 'docs/**' + - 'styles/**' jobs: docs: + name: Documentation runs-on: ubuntu-latest strategy: matrix: - python-version: ['3.10'] + python-version: ['3.12'] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - - - name: Use Python GitHub Actions cache - uses: actions/cache@v2 - with: - path: ~/.cache/pip - key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements-docs.txt') }} - restore-keys: | - ${{ runner.os }}-pip- + cache: 'pip' - name: Create Python virtual environment run: pip install virtualenv - name: pip install requirements - run: pip install -r requirements-docs.txt + run: | + pip install -r requirements-docs.txt + sudo snap install --edge vale - name: Check for broken links - run: make docs-linkcheck + run: make docs-linkcheckbroken - name: Build HTML documentation run: make docs-html + + - name: Run vale + run: | + git clone https://github.com/errata-ai/Microsoft.git + cp -r ./Microsoft/Microsoft ./styles + vale --no-exit ./docs diff --git a/.github/workflows/generator.yml b/.github/workflows/generator.yml deleted file mode 100644 index c08cd504dc..0000000000 --- a/.github/workflows/generator.yml +++ /dev/null @@ -1,88 +0,0 @@ -name: Project Generator Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] - env: - generator-directory: ./packages/generator-volto - project-directory: ./my-volto-app - - steps: - - uses: actions/checkout@v2 - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # Build main Volto environment - - name: Build main Volto environment - run: yarn install --frozen-lockfile - - # Generator own tests - - name: Generator tests - run: yarn && yarn test - working-directory: ${{env.generator-directory}} - - # install Yeoman and the generator - - run: npm -g install yo - working-directory: ${{env.generator-directory}} - - run: npm -g install ./ - working-directory: ${{env.generator-directory}} - - # create a project - - run: yo @plone/volto my-volto-app --description "test volto project" --no-interactive - - - name: Install yalc - run: npm -g install yalc - - - name: Install a yalc'ed version of the current Volto in the project - publish - run: yalc publish - - name: Install a yalc'ed version of the current Volto in the project - add - run: yalc add @plone/volto --no-pure - working-directory: ${{env.project-directory}} - - name: Install a yalc'ed version of the current Volto in the project - install - run: yarn --force - working-directory: ${{env.project-directory}} - - # Cypress install - - run: yarn cy:install - - - name: Cypress acceptance tests - run: yarn ci:cypress:project:run - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos - - - name: Test if npm packs correctly - run: npm pack --dry-run - if: success() - working-directory: ${{env.generator-directory}} diff --git a/.github/workflows/guillotina.yml b/.github/workflows/guillotina.yml deleted file mode 100644 index 393818fc6e..0000000000 --- a/.github/workflows/guillotina.yml +++ /dev/null @@ -1,51 +0,0 @@ -name: Guillotina Backend Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] - steps: - - uses: actions/checkout@v2 - - name: debug - working-directory: api - run: ls -al - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # node install - - run: yarn install --frozen-lockfile - - - name: Cypress acceptance tests - run: yarn ci:cypress:run:guillotina - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos diff --git a/.github/workflows/multilingual.yml b/.github/workflows/multilingual.yml deleted file mode 100644 index 1175d15d18..0000000000 --- a/.github/workflows/multilingual.yml +++ /dev/null @@ -1,51 +0,0 @@ -name: Multilingual Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] - steps: - - uses: actions/checkout@v2 - - name: debug - working-directory: api - run: ls -al - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # node install - - run: yarn install --frozen-lockfile - - - name: Cypress Multilingual Acceptance Tests - run: yarn ci:cypress:run:multilingual - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos diff --git a/.github/workflows/readme-link-check.yml b/.github/workflows/readme-link-check.yml new file mode 100644 index 0000000000..41b0b13f34 --- /dev/null +++ b/.github/workflows/readme-link-check.yml @@ -0,0 +1,23 @@ +# Check links in all README.mds with awesome_bot +# https://github.com/dkhamsing/awesome_bot +name: readme-link-check + +on: + push: + branches: [ '*' ] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Set up Ruby 3.2 + uses: ruby/setup-ruby@v1 + with: + ruby-version: 3.2 + - name: Check links in README.md with awesome_bot + run: | + gem install awesome_bot + awesome_bot --request-delay 1 --allow-dupe --white-list http://localhost:8080/Plone,http://localhost:3000,https://github.com/kitconcept/volto-blocks-grid.git,https://my-server-DNS-name.tld/api --files PACKAGES.md,README.md,packages/blocks/README.md,packages/client/README.md,packages/components/README.md,packages/generator-volto/README.md,packages/parcel-optimizer-react-client/README.md,packages/registry/README.md,packages/scripts/README.md,packages/tsconfig/README.md,packages/types/README.md,packages/volto-slate/README.md,apps/nextjs/README.md,apps/remix/README.md,apps/vite-ssr/README.md diff --git a/.github/workflows/unit.yml b/.github/workflows/unit.yml new file mode 100644 index 0000000000..4ba3638654 --- /dev/null +++ b/.github/workflows/unit.yml @@ -0,0 +1,216 @@ +name: Unit Tests +on: [push, pull_request] + +env: + node-version: 20.x + +jobs: + volto: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: '@plone/volto' + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + # Locales in place are needed for the tests to pass + - run: pnpm --filter @plone/volto i18n + + - name: Run unit tests Volto + run: pnpm --filter @plone/volto test + + # Bundlewatch + # - run: yarn build + # - uses: jackyef/bundlewatch-gh-action@master + # with: + # bundlewatch-github-token: ${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }} + + registry: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: '@plone/registry' + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - name: Run unit tests @plone/registry + run: pnpm --filter @plone/registry test + + components: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: '@plone/components' + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - name: Run unit tests @plone/components + run: pnpm --filter @plone/components test + + client: + name: '@plone/client' + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Use Node.js ${{ env.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ env.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - run: make start-test-acceptance-server-detached + + - run: npx wait-on --httpTimeout 20000 http-get://localhost:55001/plone && pnpm --filter @plone/client test + working-directory: packages/client + + helpers: + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name + name: '@plone/helpers' + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + node-version: [18.x, 20.x] + steps: + - uses: actions/checkout@v4 + + # node setup + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + + - uses: pnpm/action-setup@v3 + name: Install pnpm + with: + version: 8 + run_install: false + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- + + - run: pnpm i + + - name: Run unit tests @plone/helpers + run: pnpm --filter @plone/helpers test diff --git a/.github/workflows/update_remote_docs.yml b/.github/workflows/update_remote_docs.yml new file mode 100644 index 0000000000..ec75bd410c --- /dev/null +++ b/.github/workflows/update_remote_docs.yml @@ -0,0 +1,19 @@ +name: Trigger build and deploy of Plone 6 documentation + +on: + push: + branches: + - "main" + paths: + - "docs/*" + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - run: | + curl -X POST \ + -H "Authorization: Bearer ${{secrets.DOCUMENTATION_BUILD_APPLICATION_KEY}}" \ + -H "Accept: application/vnd.github.v3+json" \ + https://api.github.com/repos/plone/documentation/actions/workflows/update_submodule.yml/dispatches \ + -d '{"ref": "6-dev"}' diff --git a/.github/workflows/workingCopy.yml b/.github/workflows/workingCopy.yml deleted file mode 100644 index a3611491fe..0000000000 --- a/.github/workflows/workingCopy.yml +++ /dev/null @@ -1,72 +0,0 @@ -name: Working Copy Tests -on: [push] -jobs: - build: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - python-version: [3.7] - steps: - - uses: actions/checkout@v2 - - # node setup - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - # node cache - - name: Get yarn cache directory path - id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v1 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - restore-keys: | - ${{ runner.os }}-yarn- - - # node install - - run: yarn install --frozen-lockfile - - # # python setup (temporary, while p.a.iterate changes are in a PR) - # - name: Set up Python ${{ matrix.python-version }} - # uses: actions/setup-python@v1 - # with: - # python-version: ${{ matrix.python-version }} - - # # python cache - # - uses: actions/cache@v1 - # with: - # path: ~/.cache/pip - # key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} - # restore-keys: | - # ${{ runner.os }}-pip- - # # python install - # - run: pip install virtualenv - # - name: pip install - # working-directory: api - # run: pip install -r requirements.txt - # - name: buildout - # working-directory: api - # run: buildout - # env: - # CI: true - - - name: Cypress Working Copy Acceptance Tests - run: yarn ci:cypress:run:workingCopy - - # Upload Cypress screenshots - - uses: actions/upload-artifact@v1 - if: failure() - with: - name: cypress-screenshots - path: cypress/screenshots - # Upload Cypress videos - - uses: actions/upload-artifact@v1 - if: always() - with: - name: cypress-videos - path: cypress/videos diff --git a/.gitignore b/.gitignore index e362291f2f..5d92feff8c 100644 --- a/.gitignore +++ b/.gitignore @@ -9,14 +9,28 @@ junit.xml eslint.xml yarn-error.log build +.changelog.draft + +# yarn 3 +.pnp.* +.yarn/* +!.yarn/patches +!.yarn/plugins +!.yarn/releases +!.yarn/sdks +!.yarn/versions # Other +.vscode +/cache +.yarn/ .DS_Store .idea lighthouse-report.html -.vscode/ .#* *~ +/.settings/ +.*project # Python /api/.installed.cfg @@ -61,10 +75,18 @@ selenium-screenshot-*.png /selenium/ cypress/videos/ cypress/screenshots +/styles/Microsoft # Local environment setup .env public/critical.css # Sphinx and MyST -docs/_build/ \ No newline at end of file +docs/_build/ +/.python-version +/.tool-versions +docs/source/news + +.turbo +.parcel-cache/ +tsconfig.tsbuildinfo diff --git a/.husky/post-checkout b/.husky/post-checkout new file mode 100755 index 0000000000..8ec99a06f9 --- /dev/null +++ b/.husky/post-checkout @@ -0,0 +1,2 @@ +[ -n "$CI" ] && exit 0 +pnpm lockhook diff --git a/.husky/post-merge b/.husky/post-merge new file mode 100755 index 0000000000..8ec99a06f9 --- /dev/null +++ b/.husky/post-merge @@ -0,0 +1,2 @@ +[ -n "$CI" ] && exit 0 +pnpm lockhook diff --git a/.husky/post-rebase b/.husky/post-rebase new file mode 100755 index 0000000000..8ec99a06f9 --- /dev/null +++ b/.husky/post-rebase @@ -0,0 +1,2 @@ +[ -n "$CI" ] && exit 0 +pnpm lockhook diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100755 index 0000000000..17092dc583 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,2 @@ +[ -n "$CI" ] && exit 0 +pnpm lint-staged diff --git a/.lintstagedrc b/.lintstagedrc new file mode 100644 index 0000000000..e2d1cf3190 --- /dev/null +++ b/.lintstagedrc @@ -0,0 +1,18 @@ +{ + "packages/!(volto)/**/*.{js,jsx,ts,tsx}": [ + "pnpm eslint --max-warnings=0 --fix", + "pnpm prettier --single-quote --write" + ], + "packages/volto/**/*.{js,jsx,ts,tsx}": [ + "pnpm --filter @plone/volto lint:husky", + "pnpm --filter @plone/volto prettier:husky" + ], + "packages/volto/src/**/*.{jsx, tsx}": ["pnpm --filter @plone/volto i18n"], + "packages/!(volto)/**/*.{css,less,scss}": ["pnpm stylelint --fix"], + "packages/volto/**/*.{css,less,scss}": [ + "pnpm --filter @plone/volto stylelint --fix" + ], + "packages/volto/**/*.overrides": [ + "pnpm --filter @plone/volto stylelint --fix" + ] +} diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 80e49c25c8..0000000000 --- a/.npmignore +++ /dev/null @@ -1,100 +0,0 @@ -# https://docs.npmjs.com/using-npm/developers.html#keeping-files-out-of-your-package - -# Directories -api/ -bin/ -build/ -lib/ -g-api/ -tests/ - -# Docs -docs/ - -# Cypress -cypress/fixtures -cypress/tests -cypress/screenshots -cypress/videos - -# Tests -__tests__/ -*.snap - -# Files -.travis.yml -requirements-docs.txt -requirements-tests.txt -yarn.lock -.dockerignore -.gitattributes -.yarnrc -.nvmrc -changelogupdater.js -pip-selfcheck.json -Dockerfile -CNAME -entrypoint.sh -Jenkinsfile -Makefile - -# Logs -logs -*.log -npm-debug.log* -yarn-debug.log* -yarn-error.log* - -# Runtime data -pids -*.pid -*.seed -*.pid.lock - -# Directory for instrumented libs generated by jscoverage/JSCover -lib-cov - -# Coverage directory used by tools like istanbul -coverage - -# nyc test coverage -.nyc_output - -# node-waf configuration -.lock-wscript - -# Compiled binary addons (https://nodejs.org/api/addons.html) -build/Release - -# Dependency directories -node_modules/ -jspm_packages/ - -# TypeScript v1 declaration files -typings/ - -# Optional npm cache directory -.npm - -# Optional eslint cache -.eslintcache - -# Optional REPL history -.node_repl_history - -# Output of 'npm pack' -*.tgz - -# Yarn Integrity file -.yarn-integrity - -# dotenv environment variables file -.env - -# next.js build output -.next - -styleguide.config -.vscode -packages -.tx diff --git a/.nvmrc b/.nvmrc deleted file mode 100644 index b009dfb9d9..0000000000 --- a/.nvmrc +++ /dev/null @@ -1 +0,0 @@ -lts/* diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000000..75e827079f --- /dev/null +++ b/.prettierignore @@ -0,0 +1,9 @@ +**/.next +**/build +**/coverage +**/dist +styles/rules/* +node_modules +packages/volto/types/* +storybook-static +app/vite-ssr/src/routeTree.gen.ts diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000000..6e778b4fb9 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,4 @@ +{ + "trailingComma": "all", + "singleQuote": true +} diff --git a/.release-it.json b/.release-it.json new file mode 100644 index 0000000000..2b93e6a44e --- /dev/null +++ b/.release-it.json @@ -0,0 +1,3 @@ +{ + "npm": false +} diff --git a/.storybook/main.js b/.storybook/main.js deleted file mode 100644 index 25e4e36966..0000000000 --- a/.storybook/main.js +++ /dev/null @@ -1,105 +0,0 @@ -const webpack = require('webpack'); -const path = require('path'); -const makeLoaderFinder = require('razzle-dev-utils/makeLoaderFinder'); -const fileLoaderFinder = makeLoaderFinder('file-loader'); - -const projectRootPath = path.resolve('.'); -const createAddonsLoader = require('../create-addons-loader'); -const lessPlugin = require('../webpack-plugins/webpack-less-plugin'); - -const createConfig = require('../node_modules/razzle/config/createConfigAsync.js'); -const razzleConfig = require(path.join(projectRootPath, 'razzle.config.js')); - -const SVGLOADER = { - test: /icons\/.*\.svg$/, - use: [ - { - loader: 'svg-loader', - }, - { - loader: 'svgo-loader', - options: { - plugins: [ - { removeTitle: true }, - { convertPathData: false }, - { removeUselessStrokeAndFill: true }, - { removeViewBox: false }, - ], - }, - }, - ], -}; - -module.exports = { - stories: ['../src/**/*.stories.mdx', '../src/**/*.stories.@(js|jsx|ts|tsx)'], - addons: ['@storybook/addon-links', '@storybook/addon-essentials'], - webpackFinal: async (config, { configType }) => { - // `configType` has a value of 'DEVELOPMENT' or 'PRODUCTION' - // You can change the configuration based on that. - // 'PRODUCTION' is used when building the static version of storybook. - - // Make whatever fine-grained changes you need - let baseConfig; - baseConfig = await createConfig( - 'web', - 'dev', - { - // clearConsole: false, - modifyWebpackConfig: razzleConfig.modifyWebpackConfig, - plugins: razzleConfig.plugins, - }, - webpack, - ); - const AddonConfigurationRegistry = require('../addon-registry'); - - const registry = new AddonConfigurationRegistry(projectRootPath); - - config = lessPlugin({ registry }).modifyWebpackConfig({ - env: { target: 'web', dev: 'dev' }, - webpackConfig: config, - webpackObject: webpack, - options: {}, - }); - - // putting SVG loader on top, fix the fileloader manually (Volto plugin does not - // work) since it needs to go first - config.module.rules.unshift(SVGLOADER); - const fileLoader = config.module.rules.find(fileLoaderFinder); - fileLoader.exclude = [/\.(config|variables|overrides)$/, /icons\/.*\.svg$/]; - - config.plugins.unshift( - new webpack.DefinePlugin({ - __DEVELOPMENT__: true, - __CLIENT__: true, - __SERVER__: false, - }), - ); - - const resultConfig = { - ...config, - resolve: { - ...config.resolve, - alias: { ...config.resolve.alias, ...baseConfig.resolve.alias }, - }, - }; - - // console.dir(resultConfig, { depth: null }); - - return resultConfig; - }, - babel: async (options) => { - return { - ...options, - plugins: [ - ...options.plugins, - [ - './node_modules/babel-plugin-root-import/build/index.js', - { - rootPathSuffix: './src', - }, - ], - ], - // any extra options you want to set - }; - }, -}; diff --git a/.storybook/preview.js b/.storybook/preview.js deleted file mode 100644 index c4a9e39e54..0000000000 --- a/.storybook/preview.js +++ /dev/null @@ -1,21 +0,0 @@ -import '@plone/volto/config'; // This is the bootstrap for the global config - client side -import React from 'react'; -import { StaticRouter } from 'react-router-dom'; -import { IntlProvider } from 'react-intl'; -import enMessages from '@root/../locales/en.json'; - -import '@root/theme'; - -export const parameters = { - actions: { argTypesRegex: '^on[A-Z].*' }, -}; - -export const decorators = [ - (Story) => ( - - - - - - ), -]; diff --git a/.stylelintignore b/.stylelintignore new file mode 100644 index 0000000000..1521c8b765 --- /dev/null +++ b/.stylelintignore @@ -0,0 +1 @@ +dist diff --git a/.tx/config b/.tx/config deleted file mode 100644 index 769a0bb643..0000000000 --- a/.tx/config +++ /dev/null @@ -1,10 +0,0 @@ -[main] -host = https://www.transifex.com - -[plone5.volto-pot] -file_filter = locales//LC_MESSAGES/volto.po -minimum_perc = 0 -source_file = locales/volto.pot -source_lang = en -type = PO - diff --git a/.vale.ini b/.vale.ini new file mode 100644 index 0000000000..0e3bcdf1d5 --- /dev/null +++ b/.vale.ini @@ -0,0 +1,12 @@ +StylesPath = styles + +MinAlertLevel = suggestion + +Vocab = Base,Plone + +Packages = Microsoft + +[*.md] +BasedOnStyles = Vale, Microsoft +Microsoft.Contractions = suggestion +Microsoft.Units = suggestion diff --git a/.yarnrc b/.yarnrc deleted file mode 100644 index fdd705c635..0000000000 --- a/.yarnrc +++ /dev/null @@ -1 +0,0 @@ -save-prefix "" diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index d5a8ab6e68..0000000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,4751 +0,0 @@ -# Change Log - -## 15.5.1 (unreleased) - -### Breaking - -### Feature - -### Bugfix - -### Internal - -### Documentation - -## 15.5.0 (2022-04-25) - -### Feature - -- More Italian translations @giuliaghisini - -### Bugfix - -- Fixed edit internal link and image url in this blocks: image block, leadimage block, video block, objectBrowser. In objectBrowser, if pasted url was internal, it wasn't flatted and wass handled from Plone as an external. @giuliaghisini -- Fix folder content layout @SaraBianchi - -### Documentation - -- Added a `selectableTypes` example to the `ObjectBrowserWidget` storybook @JeffersonBledsoe #3255 -- Add labels for Intersphinx. @stevepiercy - -## 15.4.1 (2022-04-11) - -### Bugfix - -- Fix handling of single reference field in `ObjectBrowser` @robgietema -- Make the parseDateTime function to handle only date as well @iFlameing -- Fix ContextNavigation component with Link type objects @UnaiEtxaburu #3232 - -### Internal - -- Upgrade react-image-gallery to latest to fix a11y problem @sneridagh -- Fixed bug in HTML block edit @giuliaghisini -- Fix cannot read properties of undefined in Content.jsx @iFlameing -- Fix fixed `ObjectBrowserBody` to handle data fields based on `ObjectBrowser` mode @giuliaghisini - -## 15.4.0 (2022-04-08) - -### Feature - -- Add package.json scripts documentation @ksuess - -### Bugfix - -- Fix/Improve the console logging when the server starts. @sneridagh - -### Documentation - -- Added html_meta values to remaining pages. @stevepiercy -- Remove duplicate toctrees and set maxdepth to appropriate values. @stevepiercy - -## 15.3.0 (2022-04-04) - -### Feature - -- Improve the fix for the "user swap" vulnerability @sneridagh @plone/volto-team - Thanks to @ericof and @cekk for their help and efforts at pinpointing the latests culprits! - -### Documentation - -- Added meta-html values in most of the pages. @ktsrivastava29 - -## 15.2.3 (2022-04-01) - -### Bugfix - -- Change which api calls can set specific api errors @robgietema -- Fix helper import. @robgietema -- Move `customStyleMap` to `richtextEditorSettings` -- Pass placeholder and isDisabled properties to EmailWidget and UrlWidget @mihaislobozeanu -- Pass placeholder property to PasswordWidget and NumberWidget @mihaislobozeanu -- Fix getVocabName when vocabNameOrURL is false @avoinea #2955, #2919 - -### Internal - -- Remove offending `Makefile` command that broke on MacOS due to lack of compatibility of the MacOS `make` utility. @tisto -- Upgraded use-deep-compare-effect to version 1.8.1. @pnicolli -- chore(icons): add missing pastanaga icons @nileshgulia1 - -### Documentation - -- Switch from `docs-linkcheckbroken` to `docs-linkcheck` in GitHub Actions because the former is broken. @stevepiercy -- Set the output for storybook to the correct directory. @stevepiercy -- Fix typo in Makefile: docs/\_build @ksuess -- Added language to code-blocks in md files @ktsrivastava29 - -## 15.2.2 (2022-03-23) - -### Bugfix - -- Fix external url append issue of @@download/file @iRohitSingh -- Fix headers in sitemap middleware when errors occur in the sitemap generation @mamico - -## 15.2.1 (2022-03-21) - -### Bugfix - -- `Manage translations` view error on seamless mode, `flattenToAppURL` missing. @sneridagh - -### Documentation - -- Reenable `make docs-linkcheckbroken`. @stevepiercy -- Add html_meta values to add-on best practices, s/addon/add-on. @stevepiercy -- Netlify now only builds on changes to the `./docs/` directory. @stevepiercy -- Replace deprecated `egrep` with `grep` in `make docs-linkcheckbroken`. @stevepiercy - -## 15.2.0 (2022-03-18) - -### Feature - -- Add helper utilities to be used by addons @robgietema - -### Bugfix - -- Fix addon registry regression @sneridagh -- Fix `Bosnian` language @avoinea -- Fix use `settings.internalApiPath` in sitemap genaration @mamico - -### Documentation - -- Reduced build minutes on Netlify by building only on changes to the `docs/**` path on pull requests. See https://github.com/plone/volto/pull/3171. @stevepiercy -- Add "Documentation" heading to the automatic change log updater file `changelogupdater.js`. @stevepiercy - -## 15.1.2 (2022-03-17) - -### Bugfix - -- Fix the alt prop in `PreviewImage` component @sneridagh - -## 15.1.1 (2022-03-16) - -### Bugfix - -- Add optional alt tag to `PreviewImage` props @kindermann -- Remove non add-on names from `addonNames` list in Addons Registry. Update the list in the `addonsInfo` for the addons loader as well. @sneridagh - -## 15.1.0 (2022-03-15) - -### Feature - -- Added a new component, PreviewImage. It renders a preview image for a catalog brain (based on the `image_field` prop). @tiberiuichim - -### Bugfix - -- Clear search results before new query is done. @robgietema - -### Documentation - -- Updated README.md @ktsrivastava29 -- Added language to code-blocks in md files @ktsrivastava29 -- Added html_meta values and labels for Intersphinx cross-references from Trainings. @stevepiercy -- Replaced `docs.voltocms.com` with MyST references. @stevepiercy - -## 15.0.0 (2022-03-14) - -### Breaking - -- Upgrade `react-cookie` to the latest version. @sneridagh @robgietema - See https://6.dev-docs.plone.org/volto/upgrade-guide/index.html for more information. -- Language Switcher no longer takes care of the change of the language on the Redux Store. This responsibility has been unified in the API Redux middleware @sneridagh -- Markup change in `LinkView` component. -- Rename `core-sandbox` to `coresandbox` for sake of consistency @sneridagh -- Extend the original intent and rename `RAZZLE_TESTING_ADDONS` to `ADDONS`. @sneridagh - See https://6.dev-docs.plone.org/volto/upgrade-guide/index.html for more information. -- Lazyload Draft.js library. See the upgrade guide on how that impacts you, in case you have extended the rich text editor configuration @tiberiuichim @kreafox - See https://6.dev-docs.plone.org/volto/upgrade-guide/index.html for more information. -- Deprecating `lang` cookie in favor of Plone official one `I18N_LANGUAGE` @sneridagh - -### Feature - -- Add `cookiesExpire` value to config to control the cookie expiration @giuliaghisini -- DatetimeWidget 'noPastDates' option: Take widgetOptions?.pattern_options?.noPastDates of backend schema into account. @ksuess -- Add a new type of filter facet for the Search block. Heavily refactor some searchblock internals. @tiberiuichim -- Add date range facet to the search block @robgietema -- Introduce the new `BUILD_DIR` runtime environment variable to direct the build to run in a specific location, different than `build` folder. @sneridagh -- Handle redirect permanent calls from the backend in the frontend (e.g. when changing the short name) @robgietema -- Added id widget to manage short name @robgietema -- Refactor language synchronizer. Remove it from the React tree, integrate it into the Api Redux middleware @sneridagh -- Add blocks rendering in Event and NewsItem views (rel plone.volto#32) @nzambello @ksuess -- Add internal volto ids to invalid ids @robgietema -- Complete Basque translation @erral -- Complete Spanish translation @erral -- Sort the choices in Facets in the search block @iFlameing - -### Bugfix - -- Fix the `null` error in SelectAutoComplete Widget @iFlameing -- Prevent the `MultilingualRedirector` to force content load when switching the language @reebalazs -- Fix the upload image in contents view @iFlameing -- add "view" id to contact-form container for main content skiplink @ThomasKindermann -- Fix loading indicator positioning on Login form submit @sneridagh -- Fix redirect bug with URLs containing querystrings @robgietema -- Fixed id widget translations @robgietema -- Contents Rename Modal, use `id` Widget type @sneridagh -- Fix overflow of very long file name in `FileWidget` @sneridagh -- Fix overflowing issue in the toolbar @kreafox -- Overwrite current block on insert new block. @robgietema -- Fix hot reload on updates related to the config object because of `VersionOverview` component @sneridagh -- Fix error when lock data is gone after an invariant error. @robgietema - -### Internal - -- Change prop `name` -> `componentName` in component `Component` @sneridagh -- Add new RawMaterial Volto websites in production @nzambello -- House cleanup, remove some unused files in the root @sneridagh -- Move Webpack related files to `webpack-plugins` folder @sneridagh -- Remove unused Dockerfiles @sneridagh -- Update Docker compose to latest images and best practices @sneridagh -- Improve flaky test in coresandbox search Cypress tests @sneridagh -- Better implementation of the add-on load coming from the environment variable `ADDONS` @sneridagh -- Turn `lazyLibraries` action into a thunk. Added a conditional if the library is loaded or in process to be loaded, do not try to load it again. This fixes the lag on load `draftjs` when having a lot of draftjs blocks. @sneridagh -- Use `@root` alias instead of `~` in several module references. Most of the Volto project code no longer needs the root alias, so it makes sense to phase it out at some point @tiberiuichim -- Alias `lodash` to `lodash-es`, as this will include only one copy of lodash in the bundle @tiberiuichim -- Better Readme, updated to 2022 @sneridagh -- Update to latest versions for Python packages @sneridagh -- Add `id` as widget type as well @sneridagh - -### Documentation - -- Upgrade Guide i18n: Make clear what's project, what add-on. @ksuess -- (Experimental) Prepare documentation for MyST and importing into `plone/documentation@6-dev`. @stevepiercy -- Fix broken links and redirects in documentation to be compatible with MyST. @stevepiercy -- Update add-on internationalization. @ksuess -- Add MyST and Sphinx basic configuration for rapid build and comparison against MkDocs builds. @stevepiercy -- Fix many MyST and Sphinx warnings. @stevepiercy -- Remove MkDocs configuration. See https://github.com/plone/volto/issues/3042 @stevepiercy -- Add Plone docs to Intersphinx and fix broken link. @stevepiercy -- Get version from `package.json` @sneridagh -- Remove legacy folder in docs @sneridagh -- Backport docs of RAZZLE_TESTING_ADDONS environment variables. See https://github.com/plone/volto/pull/3067/files#diff-00609ed769cd40cf3bc3d6fcc4431b714cb37c73cedaaea18fe9fc4c1c589597 @stevepiercy -- Add missing developer-guidelines/typescript to toctree @stevepiercy -- Add Netlify for preview of Sphinx builds for pull requests against `master` and `plone6-docs`. @stevepiercy -- Clean up toctree errors by removing obsolete files, adding `:orphan:` field list, and reorganizing some files. @sneridagh and @stevepiercy -- Switch to using netlify.toml to configure Netlify Python environment. @stevepiercy -- Convert admonition syntax from Markdown to MyST. @sneridagh -- Make links build both in Volto and Plone documentation. See https://github.com/plone/volto/pull/3094 @stevepiercy -- Fix broken links. @stevepiercy -- Update Sphinx configuration to check anchors in links and exclude problematic URLs. @sneridagh and @stevepiercy -- Fix StoryBook links @sneridagh -- Clean up `linkcheck_ignore` values. @stevepiercy - -## 15.0.0-alpha.14 (2022-03-10) - -### Bugfix - -- Contents Rename Modal, use `id` Widget type @sneridagh - -### Internal - -- Better Readme, updated to 2022 @sneridagh -- Update to latest versions for Python packages @sneridagh -- Add `id` as widget type as well @sneridagh - -### Documentation - -- Fix broken links. @stevepiercy - -## 15.0.0-alpha.13 (2022-03-09) - -### Feature - -- Sort the choices in Facets in the search block @iFlameing - -### Bugfix - -- Fix overflow of very long file name in `FileWidget` @sneridagh -- Fix overflowing issue in the toolbar @kreafox - -## 15.0.0-alpha.12 (2022-03-07) - -### Feature - -- Add internal volto ids to invalid ids @robgietema -- Complete basque translation @erral -- Complete spanish translation @erral - -### Internal - -- Change prop `name` -> `componentName` in component `Component` @sneridagh - -## 15.0.0-alpha.11 (2022-03-02) - -### Bugfix - -- Fix redirect bug with URLs containing querystrings @robgietema -- Fixed id widget translations @robgietema - -### Internal - -- Use `@root` alias instead of `~` in several module references. Most of the Volto project code no longer needs the root alias, so it makes sense to phase it out at some point @tiberiuichim -- Alias `lodash` to `lodash-es`, as this will include only one copy of lodash in the bundle @tiberiuichim - -## 15.0.0-alpha.10 (2022-02-28) - -### Bugfix - -- Turn `lazyLibraries` action into a thunk. Added a conditional if the library is loaded or in process to be loaded, do not try to load it again. This fixes the lag on load `draftjs` when having a lot of draftjs blocks. @sneridagh - -## 15.0.0-alpha.9 (2022-02-28) - -### Breaking - -- Deprecating `lang` cookie in favor of Plone official one `I18N_LANGUAGE` @sneridagh - -### Feature - -- Added id widget to manage short name @robgietema -- Refactor language syncronizer. Remove it from the React tree, integrate it into the Api Redux middleware @sneridagh -- Add blocks rendering in Event and NewsItem views (rel plone.volto#32) @nzambello @ksuess - -### Bugfix - -- Fix redirect bug with URLs containing querystrings @robgietema - -## 15.0.0-alpha.8 (2022-02-22) - -### Internal - -- Better implementation of the add-on load coming from the environment variable `ADDONS` @sneridagh - -## 15.0.0-alpha.7 (2022-02-22) - -### Feature - -- Introduce the new `BUILD_DIR` runtime environment variable to direct the build to run in an especific location, different than `build` folder. @sneridagh -- Handle redirect permanent calls from the backend in the frontend (e.g. when changing the short name) @robgietema - -## 15.0.0-alpha.6 (2022-02-21) - -### Feature - -- DatetimeWidget 'noPastDates' option: Take widgetOptions?.pattern_options?.noPastDates of backend schema into account. @ksuess -- Add a new type of filter facet for the Search block. Heavily refactor some searchblock internals. @tiberiuichim -- Add date range facet to the search block @robgietema - -### Internal - -- Improve flaky test in coresandbox search Cypress tests @sneridagh - -### Documentation - -- (Experimental) Prepare documentation for MyST and importing into `plone/documentation@6-dev`. @stevepiercy -- Fix broken links and redirects in documentation to be compatible with MyST. @stevepiercy -- Update add-on internationalization. @ksuess -- Add MyST and Sphinx basic configuration for rapid build and comparison against MkDocs builds. @stevepiercy -- Fix many MyST and Sphinx warnings. @stevepiercy -- Remove MkDocs configuration. See https://github.com/plone/volto/issues/3042 @stevepiercy -- Add Plone docs to Intersphinx and fix broken link. @stevepiercy -- Get version from `package.json` @sneridagh -- Remove legacy folder in docs @sneridagh -- Backport docs of RAZZLE_TESTING_ADDONS environment variables. See https://github.com/plone/volto/pull/3067/files#diff-00609ed769cd40cf3bc3d6fcc4431b714cb37c73cedaaea18fe9fc4c1c589597 @stevepiercy -- Add missing developer-guidelines/typescript to toctree @stevepiercy -- Add Netlify for preview of Sphinx builds for pull requests against `master` and `plone6-docs`. @stevepiercy -- Clean up toctree errors by removing obsolete files, adding `:orphan:` field list, and reorganizing some files. @sneridagh and @stevepiercy -- Switch to using netlify.toml to configure Netlify Python environment. @stevepiercy -- Convert admonition syntax from Markdown to MyST. @sneridagh -- Make links build both in Volto and Plone documentation. See https://github.com/plone/volto/pull/3094 @stevepiercy - -## 15.0.0-alpha.5 (2022-02-16) - -### Breaking - -- Lazyload draftjs library. See the upgrade guide on how that impacts you, in case you have extended the rich text editor configuration @tiberiuichim @kreafox - See https://docs.voltocms.com/upgrade-guide/ for more information. - -### Feature - -- Add `cookiesExpire` value to config to control the cookie expiration @giuliaghisini - -## 15.0.0-alpha.4 (2022-02-16) - -### Breaking - -- Markup change in `LinkView` component. -- Rename `core-sandbox` to `coresandbox` for sake of consistency @sneridagh -- Extend the original intent and rename `RAZZLE_TESTING_ADDONS` to `ADDONS`. @sneridagh - See https://docs.voltocms.com/upgrade-guide/ for more information. - -### Internal - -- House cleanup, remove some unused files in the root @sneridagh -- Move Webpack related files to `webpack-plugins` folder @sneridagh -- Remove unused Dockerfiles @sneridagh -- Update Docker compose to latest images and best practices @sneridagh - -## 15.0.0-alpha.3 (2022-02-11) - -### Bugfix - -- Fix the upload image in contents view @iFlameing -- add "view" id to contact-form container for main content skiplink @ThomasKindermann -- Fix loading indicator positioning on Login form submit @sneridagh - -### Internal - -- Add new RawMaterial Volto websites in production @nzambello - -## 15.0.0-alpha.2 (2022-02-10) - -### Breaking - -- Language Switcher no longer takes care of the change of the language on the Redux Store. This responsability has been unified in the `MultilingualRedirector` @sneridagh - -### Bugfix - -- Prevent the MultilingualRedirector to force 4 content load when switching the language @reebalazs - -### Documentation - -- Upgrade Guide i18n: Make clear what's project, what add-on. @ksuess - -## 15.0.0-alpha.1 (2022-02-09) - -### Bugfix - -- Fix the `null` error in SelectAutoComplete Widget @iFlameing - -## 15.0.0-alpha.0 (2022-02-09) - -### Breaking - -- Upgrade `react-cookie` to latest version. @sneridagh @robgietema - See https://docs.voltocms.com/upgrade-guide/ for more information. - -## 14.10.0 (2022-02-08) - -### Feature - -- Add Pluggable to toolbar user menu. @ksuess - -## 14.9.0 (2022-02-08) - -### Feature - -- Show addons installed in control panel @sneridagh - -### Bugfix - -- Fix italian translations in ObjectBrowser @giuliaghisini - -## 14.8.1 (2022-02-04) - -### Bugfix - -- Fix wrong CSS in language independent class selector @sneridagh - -### Internal - -- Cleanup redundant buildout install run. - -## 14.8.0 (2022-02-03) - -### Feature - -- Enable `components` property in Volto's config registry. Does not expose any direct feature but this will open the door to be able to override registered components using the config registry and avoid using shadowing explicitly. @sneridagh -- Add `resolve` and `register` helper methods for the Volto config. They retrieve and register new components in the registry. @tiberiuichim @sneridagh -- Add `Component` component, given a `name` of a component registered in the registry, it renders it, passing down the props. @tiberiuichim -- Syncronize the content language with the UI language in multilingual sites. So when you are accessing a content in a given language the rest of the interface literals follow along (it updates the language cookie). So the UI remains consistent. @sneridagh - -### Bugfix - -- Fix the a11y violation of UrlWidget @iRohitSingh - -### Internal - -- Update volta pins in package.json @fredvd - -## 14.7.1 (2022-02-02) - -### Internal - -- Add CSS body class in Babel view. Improve marker for language independent fields in Babel view too. @sneridagh - -### Docs - -Update documentation for internal proxy & other smaller reorganisation for quicker onboarding of -new users/evaluators. @fredvd - -## 14.7.0 (2022-01-28) - -### Feature - -- Add `` and `` components. Check their Storybook stories for details. This is part of ongoing work to minimize the use of 'deprecated' momentjs. @sneridagh @tiberiuichim - -### Internal - -- Upgrade jest to latest release, 27 major. @tiberiuichim -- Lazyload momentjs. `parseDateTime` helper now requires passing the momentjs library @tiberiuichim - -## 14.6.0 (2022-01-27) - -### Feature - -- Use `volto.config.js` as dynamic configuration for addons. It adds up to the `package.json` `addons` key, allowing dynamic load of addons (eg. via environment variables) @sneridagh - -### Internal - -- Fix ObjectListWidget story bug caused by lazyloading dnd libraries - @tiberiuichim - -## 14.5.0 (2022-01-26) - -### Feature - -- VocabularyTermsWidget: Token is now on creation of term editable, but stays ineditable afterwards. @ksuess - -### Bugfix - -- Fix A11Y violations in Navigation @iRohitSingh -- Fix `language-independent-field` CSS class styling @sneridagh - -### Internal - -- Lazyload react-beautiful-dnd @tiberiuichim -- Lazyload react-dnd @tiberiuichim -- Improve docs on environment variables, add recipes @sneridagh -- Update p.restapi to 8.20.0 and plone.volto to 4.0.0a1 and plone.rest to 2.0.0a2 @sneridagh - -## 14.4.0 (2022-01-21) - -### Feature - -- Language independent fields support in Volto forms @sneridagh - -## 14.3.0 (2022-01-20) - -### Feature - -- Bump semantic-ui-react to v2.0.3 @nileshgulia1 - -## 14.2.3 (2022-01-20) - -### Bugfix - -- Fix ListingBlock to add "No results" message when there are no messages @erral -- Fix overflow table in Content view @giuliaghisini -- Fixed url validation in FormValidation to admit ip addresses. @giuliaghisini -- Upgrade to plone.restapi 8.19.0 (to support the language independent fields serialization) @sneridagh - -## 14.2.2 (2022-01-13) - -### Bugfix - -- Fix home URL item in Navigation, which was evaluating as non-internal @sneridagh -- Improve the request handling in `getAPIResourceWithAuth` and in `Api` helper. This fixes the "Cannot set headers once the content has being sent" @sneridagh -- Fix when you remove the time from DatetimeWidget @iRohitSingh - -### Internal - -- Fix URL for Climate-Energy, a Volto website @tiberiuichim -- Fix quirky Cypress test in "DX control panel schema" (see https://github.com/plone/volto/runs/4803206906?check_suite_focus=true) @sneridagh - -## 14.2.1 (2022-01-12) - -### Bugfix - -- Fix home URL item in Navigation, which was evaluating as non-internal - -### Internal - -- Use plone-backend docker images for Cypress tests @sneridagh -- Upgrade `query-string` library so it supports Plone `:list` qs marker @sneridagh - -## 14.2.0 (2022-01-04) - -### Feature - -- Allow `creatable` prop to be passed to `ArrayWidgets`, in case they don't have a vocabulary @giuliaghisini -- Added initialBlocksFocus to blocks config, to set default focus on non-first block. @giuliaghisini - -## 14.1.1 (2022-01-03) - -### Internal - -- Update to plone.restapi 8.18.0, remove some defensive code in vocabularies action now that it's fixed in the backend @sneridagh - -## 14.1.0 (2021-12-31) - -### Feature - -- Added custom option to SelectWidget to render custom optionss (for example with icons) @giuliaghisini -- Added form undo support in the form of two buttons in the main toolbar and ctrl+z, ctrl+y as hotkeys for undo/redo. The undo capabilities are provided by a new helper hook, `useUndoManager`. @tiberiuichim - -### Bugfix - -- Fix query data in listing blocks ssr async call @cekk -- In the contact form, only display the "back" button in the toolbar @tiberiuichim -- Fixed selected widget to use isMulti prop @giuliaghisini - -### Internal - -- Allow the draftjs Text block edit to update the editor content when incoming block data is mutated outside the block (to support form undo) @tiberiuichim -- Remove use of internal component state for ArrayWidget, SelectWidget and TokenWidget, (to support form undo) @tiberiuichim -- Use lazy loading of react-dates and momentjs for the DatetimeWidget @tiberiuichim -- Improve widget stories, add a common `WidgetStory` class, show undo capabilities in widget stories @tiberiuichim -- Better SelectAutocompleteWidget and SelectUtils @giuliaghisini @sneridagh @tiberiuichim - -## 14.0.2 (2021-12-22) - -### Internal - -- Better favicon definitions, 2021 bullet proof @sneridagh - -## 14.0.1 (2021-12-21) - -### Bugfix - -- Construct request with list parameters as separate querystring key value pairs according Zope convention @ksuess -- Fix spelling in error message when backend is unreachable @instification - -## 14.0.0 (2021-12-20) - -### Breaking - -- Remove compatibility for old configuration (based on imports) system. Migrate your configuration to the new configuration system for your project before upgrading to Volto 14. See https://docs.voltocms.com/upgrade-guide/#volto-configuration-registry @sneridagh -- Content locking is not a breaking change, but it's worth noting that Volto 14 comes with locking support enabled by default. Latest `plone.restapi` version is required. @avoinea -- Revisited, rethought and refactored Seamless mode @sneridagh - For more information, please read the deploying guide - https://docs.voltocms.com/deploying/seamless-mode/ -- Listing block no longer use `fullobjects` to retrieve backend data. It uses the catalog data instead. This improves the performance of the listing block. @plone/volto-team -- Removed pagination in vocabularies widgets (SelectWidget, ArrayWidget, TokenWidget) and introduced subrequest to vocabulary action. @giuliaghisini -- Use the block's title as the source of the translation instead of using the id of the block. See upgrade guide for more information @sneridagh -- New i18n infrastructure in the new `@plone/scripts` package @sneridagh -- Removed `src/i18n.js` in favor of the above change @sneridagh -- Adjusted main `Logo.jsx` default component styling @sneridagh -- Fix logout action using the backend @logout endpoint, effectively removing the `__ac` cookie. It is recommended to upgrade to the latest p.restapi version to take full advantage of this feature @sneridagh -- Improve mobile navigation menu with a nicer interaction and a fixed overlay with a drawer (customizable via CSSTransitionGroup) animation @sneridagh -- Use title instead of id as a source of translation in "Variation" field in block enhancers @sneridagh -- Move `theme.js` import to top of the client code, so it take precedence over any other inline imported CSS. This is not an strict breaking change, but it's worth to mention it as might be important and kept in mind. @sneridagh - -See https://docs.voltocms.com/upgrade-guide/ for more information about all the breaking changes. - -### Feature - -- Support Node 16 @timo -- Content locking support for Plone (`plone.locking`) @avoinea -- Add the new search block @tiberiuichim @kreafox @sneridagh -- Provide Server-Side Rendering capabilities for blocks with async-based content (such as the listing block). A block needs to provide its own `getAsyncData` implementation, which is similar to an `asyncConnect` wrapper promise. @tiberiuichim @sneridagh -- Defaults are observed in block data if `InlineForm` or `BlockDataForm` are used. @sneridagh @tiberiuichim -- Apply form defaults from RenderBlocks and block Edit using a new helper, `applyBlockDefaults` @tiberiuichim -- Now each block config object can declare a schema factory (a function that can produce a schema) and this will be used to derive the default data for the block @tiberiuichim -- Add `volto-guillotina` addon to core @sneridagh -- Make `VocabularyTermsWidget` orderable @ksuess -- Get widget by tagged values utility function in the `Field` decider @ksuess -- Use Plone logo @ericof -- Update favicon and related tags with best practices @sneridagh -- Enable to be able to use the internal proxy in production as well @sneridagh -- Add runtime configuration for `@babel/plugin-transform-react-jsx` set to `automatic`. This enables the new JSX runtime: https://reactjs.org/blog/2020/09/22/introducing-the-new-jsx-transform.html So no longer `import React from 'react'` is needed anymore. @sneridagh -- Add `autocomplete` Widget component - It holds off the vocabulary endpoint pull until you search (more than 2 chars). Useful when dealing with huge vocabularies @sneridagh @reebalazs -- Add new listing block option "fullobjects" per variation @ksuess -- `FormFieldWrapper` accepts now strings and elements for description @nzambello -- Image block: - - When uploading an image or selecting that from the object browser, Image block will set an empty string as alternative text @nzambello - - Adds a description to the alt-tag with w3c explaination @nzambello -- Support TypeScript usage in Volto projects @pnicolli -- Added `LinkMore` component and link more in `HeroImageLeft` block. @giuliaghisini -- In the search block, allow editors to specify the sort on criteria. - @tiberiuichim -- Added `.storybook` setup in the Volto `app` generator. Volto projects generated from this scafolding are now ready to run Storybook for the project and develop addons (in `src/addons` folder). -- Style checkboxes @nileshgulia1 -- Allow loading .less files also from a Volto project's `src` folder. @tiberiuichim -- Add catalan translation @bloodbare @sneridagh -- Updated Volto production sites list @giuliaghisini -- Japanese translation updated @terapyon -- German translations updated @tisto -- Updated italian translation @pnicolli -- Updated Brazilian Portuguese translations @ericof - -### Bugfix - -- Fix `SelectWidget` vocabulary load on second component mount @avoinea #2655 -- Fix `/edit` and `/add` `nonContentRoutes` to fix `isCmsUi` fn @giuliaghisini -- Register the dev api proxy after the express middleware @tiberiuichim -- Fix on form errors in block editor, not changing to metadata tab @sneridagh -- Fix SSR on `/edit` with dev proxy @tiberiuichim -- Fix logout action, removing the `__ac` cookie as well, if present. @sneridagh -- Do not show lead image block when the content type does not have the behavior enabled @sneridagh -- Missing default messages from JSON EN language file @sneridagh -- Show correct fieldname and not internal field id in Toast error messages on Add/Edit forms @jackahl -- `sitemap.xml.gz` obeys Plone Search settings @erral -- Get `blocks` and `blocks_layout` defaults from existing behavior when enabling TTW editable DX Layout @avoinea -- Yet another attempt at fixing devproxy. Split the devproxy into a separate devproxy verbose @tiberiuichim -- Add spinner on sharing View Button @iRohitSingh -- Fixed `SelectWidget`: when there was a selected value, the selection was lost when the tab was changed. @giuliaghisini -- Bugfixes to search block. By default search block, when empty, makes a simple - query to the nav root, to list all content. Fix reading search text from URL. - Implement a simple compression of URL. Don't count searched text as filter. - Fix an edge case with showSearchInput in schema. Rename title to Section - Title in facet column settings. Avoid double calls to querystring endpoint. - @tiberiuichim -- Use correct shade of black in Plone logo @sneridagh -- Fix loading of cookie on SSR for certain requests, revert slight change in how they are loaded introduced in alpha 16 @sneridagh -- Prevent `ua-parser-js` security breach. See: https://github.com/advisories/GHSA-pjwm-rvh2-c87w @thet -- Fix storybook errors in the connected components, api is undefined. Using now a mock of the store instead of the whole thing @sneridagh -- CSS fix on `QueryWidget` to prevent line jumping for clear button when the multi selection widget has multiple items @kreafox -- Fix disable mode of `QuerystringWidget` when all criteria are deleted @kreafox -- Fix reset pagination in searchblock when changing facet filters @tiberiuichim -- Fix the selection of Maps Block @iRohitSingh -- `UniversalLink`: handle direct download for content-type File if user is not logged. @giuliaghisini -- Fixed `ObjectBrowserWidget` when is multiple or `maximumSelectionSize` is not set @giuliaghisini -- Fix full-width image overlaps the drag handle @iRohitSingh -- Fix move item to top of the folder when clicking on move to top action button @iRohitSingh -- Fix `downloadableObjects` default value @giuliaghisini -- Folder contents table header and breadcrumbs dropdown now appear only from the bottom, fixing an issue where the breadcrumb dropdown content was clipped by the header area @ichim-david -- Folder contents sort dropdown is now also simple as the other dropdowns - ensuring we have the same behavior between adjecent dropdown @ichim-david -- Fix documention on block extensions, replace `render` with `template` to match Listing block @tiberiuichim -- Fix `isInternalURL` when `settings.internalApiPath` is empty @tiberiuichim -- Fix external link not supported by Navigation component #2853. @ericof -- Get Add/Edit schema contextually #2852 @ericof -- Fix regression in actions vocabularies calls because the change to use contextual schemas @sneridagh -- Include block schema enhancers (main block schema enhancer + variation schema enhancer) when calculating block default data @tiberiuichim -- Fixed object browser selected items number. @giuliaghisini -- Fix action vocabularies call avoiding regex look behind @nzambello -- Use subrequest in hero block to not lost locking token. @cekk -- Always add lang attr in html @nzambello -- Fix time widget position on 24h format @nzambello -- QuerystringWidget more resilient on old schemas @nzambello -- In search block, read SearchableText search param, to use it as search text input @tiberiuichim -- Fix missing translation in link content type @iRohitSingh -- Fixed drag-and-drop list placeholder issues @reebalazs -- Update demo address @ksuess -- Update list of trainings documentation @ksuess -- Scroll to window top only when the location pathname changes, no longer take the window location search parameters into account. The search page and the listing block already use custom logic for their "scroll into view" behaviors. @tiberiuichim -- Add missing layout view for `document_view` @MarcoCouto -- Add missing `App.jsx` full paths @jimbiscuit -- Fix z-index value of hamburger-wrapper on mobile resolutions overlapping the sidebar @ichim-david -- Fix UniversalLink handling of remote URLs from Link @nzambello - -### Internal - -- Upgrade to react 17.0.2 @nzambello -- Update to latest `plone.restapi` (8.16.2) @sneridagh -- Upgrade to `@plone/scripts` 1.0.3 @sneridagh -- Upgrade caniuse-lite 1.0.30001286 @tiberiuichim -- fix:correctly checkout plone.volto in buildout @nileshgulia1 -- Add line in upgrade guide about `getVocabulary` API change @tiberiuichim -- Add new Volto websites in production @nzambello -- Remove Pastanaga logos from Toolbar @sneridagh -- Add `omelette` to the local Plone backend build @sneridagh -- Optimize npm package by adding `docs/` `cypress/` and `tests/` to .npmignore @avoinea -- Use released `@plone/scripts`, since the builds are broken if it's a local package @sneridagh -- Use `plone.volto` instead of `kitconcept.volto` @tisto -- Silence customization errors, they are now behind a `debug` library namespace @sneridagh -- Add development dependency on `use-trace-update`, useful for performance debugging @tiberiuichim -- Improved developer documentation. Proof read several chapters, most importantly the upgrade guide @ichim-david -- Footer: Point to `plone.org` instead of `plone.com` @ericof -- Fix `make start-frontend` @tisto -- Update all the tests infrastructure for the new `volto-guillotina` addon @sneridagh -- Add locales to existing block variations @sneridagh -- Add RawMaterial website in Volto production sites @nzambello -- Removing the hardcoded default block type from text block @iRohitSingh -- updated Volto sites list @giuliaghisini -- Cleanup dangling virtualenv files that should not be committed @pnicolli -- Remove bundlesize @tisto -- Upgrade stylelint to v14 (vscode-stylelint requires it now) @sneridagh -- Add several more stories for Storybook @tiberiuichim -- Add 2 new Volto websites by Eau de web for EEA @tiberiuichim -- Fix references to old configuration style in apiExpanders documentation @tiberiuichim -- Add `applySchemaDefaults`, in addition to `applyBlockDefaults`, to allow reuse in object widgets and other advanced scenarios @tiberiuichim -- Fix select family widgets stories in storybook @sneridagh -- Remove getNavigation from `Login.jsx` @iRohitSingh -- Allow listing block to be used in non-content pages (when used in a slot it - shouldn't crash on add/edit pages) @tiberiuichim -- Fix typo "toolbalWidth" @iRohitSingh -- Update all requirements and the reasoning behind them in builds @sneridagh -- Update Plone version in api backend to 5.2.6. Update README and cleanup @fredvd -- Document CI changelog verifier failure details that mislead contributors @rpatterson - -## 14.0.0-alpha.43 (2021-12-20) - -### Breaking - -- Move `theme.js` import to top of the client code, so it take precedence over any other inline imported CSS. This is not an strict breaking change, but it's worth to mention it as might be important and kept in mind. @sneridagh - -### Feature - -- Add runtime configuration for `@babel/plugin-transform-react-jsx` set to `automatic`. This enables the new JSX runtime: https://reactjs.org/blog/2020/09/22/introducing-the-new-jsx-transform.html So no longer `import React from 'react'` is needed anymore. -- Update favicon and related tags with best practices @sneridagh - -### Bugfix - -- Fix z-index value of hamburger-wrapper on mobile resolutions overlapping the sidebar @ichim-david -- Fix UniversalLink handling of remote URLs from Link @nzambello -- Add missing `App.jsx` full paths @jimbiscuit - -### Internal - -- Upgrade to react 17.0.2 @nzambello -- Upgrade caniuse-lite 1.0.30001286 @tiberiuichim -- fix:correctly checkout plone.volto in buildout @nileshgulia1 -- Add line in upgrade guide about `getVocabulary` API change @tiberiuichim -- Add new Volto websites in production @nzambello -- Remove Pastanaga logos from Toolbar @sneridagh - -## 14.0.0-alpha.42 (2021-12-13) - -### Breaking - -- Removed pagination in vocabularies widgets (SelectWidget, ArrayWidget, TokenWidget) and introduced subrequest to vocabulary action. @giuliaghisini - -### Feature - -- Add autocomplete Widget component - It holds off the vocabulary endpoint pull until you search (more than 2 chars). Useful when dealing with huge vocabularies @sneridagh @reebalazs - -### Bugfix - -- Add missing layout view for document_view @MarcoCouto - -## 14.0.0-alpha.41 (2021-12-13) - -### Feature - -- Add catalan translation @bloodbare @sneridagh -- Added `.storybook` setup in the Volto `app` generator. Volto projects - generated from this scafolding are now ready to run Storybook for the project - and develop addons (in `src/addons` folder). -- Add new listing block option "fullobjects" per variation @ksuess -- Style checkboxes @nileshgulia1 -- Allow loading .less files also from a Volto project's `src` folder. @tiberiuichim - -### Bugfix - -- Udate demo address @ksuess -- Update list of trainings documentation @ksuess -- Scroll to window top only when the location pathname changes, no longer take the window location search parameters into account. The search page and the listing block already use custom logic for their "scroll into view" behaviors. @tiberiuichim - -### Internal - -- Update to plone.restapi 8.16.2 (revert missing_value PR) @sneridagh -- Update all requirements and the reasoning behind them in builds @sneridagh -- Update Plone version in api backend to 5.2.6. Update README and cleanup @fredvd -- Various local development build improvements @rpatterson -- Document CI changelog verifier failure details that mislead contributors -- Document CI changelog verifier failure details that mislead contributors @rpatterson -- Updated italian translation @pnicolli - -## 14.0.0-alpha.40 (2021-12-01) - -### Bugfix - -- In search block, read SearchableText search param, to use it as search text input - @tiberiuichim -- Fix missing translation in link content type @iRohitSingh -- Fixed drag-and-drop list placeholder issues @reebalazs - -## 14.0.0-alpha.39 (2021-11-30) - -### Bugfix - -- QuerystringWidget more resilient on old schemas @nzambello - -## 14.0.0-alpha.38 (2021-11-30) - -### Bugfix - -- Use subrequest in hero block to not lost locking token. @cekk -- Always add lang attr in html @nzambello -- Fix time widget position on 24h format @nzambello - -### Internal - -- Remove getNavigation from Login.jsx @iRohitSingh -- Allow listing block to be used in non-content pages (when used in a slot it - shouldn't crash on add/edit pages) @tiberiuichim -- Fix typo "toolbalWidth" @iRohitSingh - -## 14.0.0-alpha.37 (2021-11-26) - -### Bugfix - -- Fixed object browser selected items number. @giuliaghisini -- Fix action vocabularies call avoiding regex look behind @nzambello - -### Internal - -- Fix select family widgets stories in storybook @sneridagh - -## 14.0.0-alpha.36 (2021-11-25) - -### Bugfix - -- Fix regression in actions vocabularies calls because the change to use contextual schemas @sneridagh -- Include block schema enhancers (main block schema enhancer + variation schema enhancer) when calculating block default data @tiberiuichim - -### Internal - -- Fix references to old configuration style in apiExpanders documentation @tiberiuichim -- Add `applySchemaDefaults`, in addition to `applyBlockDefaults`, to allow reuse in object widgets and other advanced scenarios @tiberiuichim - -## 14.0.0-alpha.35 (2021-11-24) - -### Bugfix - -- Fix `isInternalURL` when `settings.internalApiPath` is empty @tiberiuichim -- Fix external link not supported by Navigation component #2853. @ericof -- Get Add/Edit schema contextually #2852 @ericof - -### Internal - -- Upgrade p.restapi to 8.15.2 @sneridagh - -## 14.0.0-alpha.34 (2021-11-20) - -### Feature - -- Apply form defaults from RenderBlocks and block Edit using a new helper, `applyBlockDefaults` @tiberiuichim -- Now each block config object can declare a schema factory (a function that can produce a schema) and this will be used to derive the default data for the block @tiberiuichim - -## 14.0.0-alpha.33 (2021-11-20) - -### Bugfix - -- Fix downloadableObjects default value @giuliaghisini -- Folder contents table header and breadcrumbs dropdown now appear only from the - bottom, fixing an issue where the breadcrumb dropdown content was clipped - by the header area @ichim-david -- Folder contents sort dropdown is now also simple as the other dropdowns - ensuring we have the same behavior between adjecent dropdown @ichim-david -- Fix documention on block extensions, replace `render` with `template` to match Listing block @tiberiuichim - -### Internal - -- Upgrade stylelint to v14 (vscode-stylelint requires it now) @sneridagh -- Add several more stories for Storybook @tiberiuichim -- Add 2 new Volto websites by Eau de web for EEA @tiberiuichim - -## 14.0.0-alpha.32 (2021-11-09) - -### Breaking - -- Listing block no longer use `fullobjects` to retrieve backend data. It uses the catalog data instead. @plone/volto-team - -### Internal - -- Remove bundlesize @tisto -- Upgrade plone.restapi from 8.12.1 -> 8.13.0 @tisto - -## 14.0.0-alpha.31 (2021-11-07) - -### Feature - -- Added LinkMore component and link more in HeroImageLeft block. @giuliaghisini - -### Bugfix - -- Fix the selection of Maps Block @iRohitSingh -- UniversalLink: handle direct download for content-type File if user is not logged. @giuliaghisini -- Fixed ObjectBrowserWidget when is multiple or maximumSelectionSize is not set @giuliaghisini -- Fix full-width image overlaps the drag handle @iRohitSingh -- Fix move item to top of the folder when clicking on move to top action button @iRohitSingh - -### Internal - -- Removing the hardcoded default block type from text block @iRohitSingh -- updated Volto sites list @giuliaghisini -- Cleanup dangling virtualenv files that should not be committed @pnicolli -- Improve italian translation @pnicolli - -## 14.0.0-alpha.30 (2021-11-07) - -### Feature - -- Support typescript usage in Volto sites @pnicolli - -## 14.0.0-alpha.29 (2021-11-06) - -### Bugfix - -- Fix reset pagination in searchblock when changing facet filters @tiberiuichim - -## 14.0.0-alpha.28 (2021-11-03) - -### Feature - -- Defaults are observed in block data if `InlineForm` or `BlockDataForm` are used. @sneridagh @tiberiuichim - -## 14.0.0-alpha.27 (2021-11-02) - -### Breaking - -- Use title instead of id as a source of translation in "Variation" field in block enhancers @sneridagh - -## 14.0.0-alpha.26 (2021-11-01) - -### Feature - -- Provide Server-Side Rendering capabilities for blocks with async-based content (such as the listing block). A block needs to provide its own `getAsyncData` implementation, which is similar to an `asyncConnect` wrapper promise. @tiberiuichim @sneridagh - -## 14.0.0-alpha.25 (2021-11-01) - -### Feature - -- FormFieldWrapper accepts now strings and elements for description @nzambello -- Image block: - - When uploading an image or selecting that from the object browser, Image block will set an empty string as alternative text @nzambello - - Adds a description to the alt-tag with w3c explaination @nzambello - -### Bugfix - -- Fix disable mode of `QuerystringWidget` when all criteria are deleted @kreafox - -### Internal - -- Add RawMaterial website in Volto production sites @nzambello - -## 14.0.0-alpha.24 (2021-10-29) - -### Feature - -- Support Node 16 @timo - -### Bugfix - -- Prevent ua-parser-js security breach. See: https://github.com/advisories/GHSA-pjwm-rvh2-c87w @thet -- Fix storybook errors in the connected components, api is undefined. Using now a mock of the store instead of the whole thing @sneridagh -- CSS fix on `QueryWidget` to prevent line jumping for clear button when the multi selection widget has multiple items @kreafox - -## 14.0.0-alpha.23 (2021-10-21) - -### Feature - -- Enable to be able to use the internal proxy in production as well @sneridagh - -### Bugfix - -- Fix loading of cookie on SSR for certain requests, revert slight change in how they are loaded introduced in alpha 16 @sneridagh - -## 14.0.0-alpha.22 (2021-10-20) - -### Breaking - -- Improve mobile navigation menu with a nicer interaction and a fixed overlay with a drawer (customizable via CSSTransitionGroup) animation @sneridagh - -### Internal - -- Add locales to existing block variations @sneridagh - -## 14.0.0-alpha.21 (2021-10-17) - -### Feature - -- In the search block, allow editors to specify the sort on criteria. - @tiberiuichim -- Updated Volto production sites list @giuliaghisini - -### Bugfix - -- Bugfixes to search block. By default search block, when empty, makes a simple - query to the nav root, to list all content. Fix reading search text from URL. - Implement a simple compression of URL. Don't count searched text as filter. - Fix an edge case with showSearchInput in schema. Rename title to Section - Title in facet column settings. Avoid double calls to querystring endpoint. - @tiberiuichim -- Use correct shade of black in Plone logo @sneridagh - -## 14.0.0-alpha.20 (2021-10-15) - -### Breaking - -- Revisited, rethought and refactored Seamless mode @sneridagh - For more information, please read the deploying guide - https://docs.voltocms.com/deploying/seamless-mode/ - -and the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Bugfix - -- Fixed SelectWidget: when there was a selected value, the selection was lost when the tab was changed. @giuliaghisini - -## 14.0.0-alpha.19 (2021-10-15) - -### Feature - -- Make VocabularyTermsWidget orderable @ksuess -- Get widget by tagged values @ksuess - -## 14.0.0-alpha.18 (2021-10-11) - -### Internal - -- Re-release last release, since it does not show on NPM @sneridagh - -## 14.0.0-alpha.17 (2021-10-11) - -### Breaking - -- Fix logout action using the backend @logout endpoint, effectively removing the `__ac` cookie. It is recommended to upgrade to the latest p.restapi version to take full advantage of this feature @sneridagh - -### Bugfix - -- Add spinner on sharing View Button @iRohitSingh - -## 14.0.0-alpha.16 (2021-10-10) - -### Bugfix - -- Yet another attempt at fixing devproxy. Split the devproxy into a separate - express middleware. Introduce the `DEBUG_HPM` env var to make the devproxy - verbose @tiberiuichim - -## 14.0.0-alpha.15 (2021-10-10) - -### Breaking - -- Adjusted main `Logo` component styling @sneridagh - -For more information, please read the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Feature - -- Add `volto-guillotina` addon to core @sneridagh - -### Internal - -- Improved developer documentation. Proof read several chapters, most importantly the upgrade guide @ichim-david -- Use Plone logo (Closes #2632) @ericof -- Updated Brazilian Portuguese translations @ericof -- Footer: Point to plone.org instead of plone.com @ericof -- Fix "make start-frontend" @tisto -- Update all the tests infrastructure for the new `volto-guillotina` addon @sneridagh - -## 14.0.0-alpha.14 (2021-10-01) - -### Bugfix - -- Get `blocks` and `blocks_layout` defaults from existing behavior when enabling TTW editable DX Layout @avoinea - -### Internal - -- Add development dependency on use-trace-update, useful for performance debugging @tiberiuichim -- Upgrade to `@plone/scripts` 1.0.3 @sneridagh - -## 14.0.0-alpha.13 (2021-09-30) - -### Feature - -- Add the new search block @tiberiuichim @kreafox @sneridagh - -## 14.0.0-alpha.12 (2021-09-29) - -### Bugfix - -- Show correct fieldname and not internal field id in Toast error messages on Add/Edit forms @jackahl -- sitemap.xml.gz obeys Plone Search settings @erral - -### Internal - -- Use plone.volto instead of kitconcept.volto @tisto -- Silence customization errors, they are now behind a `debug` library namespace @sneridagh -- Remove recently introduced `RAZZLE_I18NDEBUGMODE` in favor of a `debug` library namespace @sneridagh - -## 14.0.0-alpha.11 (2021-09-25) - -### Internal - -- Use released @plone/scripts, since the builds are broken if it's a local package @sneridagh - -## 14.0.0-alpha.10 (2021-09-25) - -### Breaking - -- New i18n infrastructure in the new `@plone/scripts` package @sneridagh -- Removed `src/i18n.js` in favor of the above change @sneridagh - -### Feature - -- Add RAZZLE_I18NDEBUGMODE env var and corresponding i18nDebugMode config setting to enable/disable react-intl error messages. @sneridagh - -### Bugfix - -- Missing default messages from JSON EN language file @sneridagh - -## 14.0.0-alpha.9 (2021-09-21) - -### Breaking - -- Use the block's title as the source of the translation instead of using the id of the block. See upgrade guide for more information @sneridagh - -### Bugfix - -- Do not show lead image block when the content type does not have the behavior enabled @sneridagh - -## 14.0.0-alpha.8 (2021-09-20) - -### Bugfix - -- Fix logout action, removing the `__ac` cookie as well, if present. @sneridagh - -## 14.0.0-alpha.7 (2021-09-20) - -### Feature - -- Japanese translation updated @terapyon -- German translations updated @tisto - -## 14.0.0-alpha.6 (2021-09-20) - -### Bugfix - -- Fix SSR on /edit with dev proxy @tiberiuichim - -## 14.0.0-alpha.5 (2021-09-20) - -### Bugfix - -- Fix on form errors in block editor, not changing to metadata tab @sneridagh - -## 14.0.0-alpha.4 (2021-09-20) - -### Internal - -- Bring back the `cypress` folder from the npm ignore files, since the libs in there are required and helpful for projects, remove only the `tests` and `fixtures` @sneridagh - -## 14.0.0-alpha.3 (2021-09-20) - -### Bugfix - -- Fix /edit and /add nonContentRoutes to fix isCmsUi fn @giuliaghisini -- Register the dev api proxy after the express middleware @tiberiuichim - -### Internal - -- Update to latest p.restapi (8.9.1) @sneridagh -- Remove `workingcopy` from checkouts info for kitconcept.volto @sneridagh -- Remove built workingcopy fixture environment based on local, back to docker based one @sneridagh -- Add `omelette` to the local Plone backend build @sneridagh -- Optimize npm package by adding docs/ cypress/ and tests/ to .npmignore @avoinea - -## 14.0.0-alpha.2 (2021-09-14) - -### Internal - -- Revert: Detect when a user has logged in by means other than JWT, such as ZMI `Basic` - authentication or the classic HTML Plone `@login` view @rpatterson - -## 14.0.0-alpha.1 (2021-09-13) - -### Breaking - -- Detect when a user has logged in by means other than JWT, such as ZMI `Basic` - authentication or the classic HTML Plone `@login` view @rpatterson - -### Bugfix - -- Fix SelectWidget vocabulary load on second component mount @avoinea #2655 - -## 14.0.0-alpha.0 (2021-09-08) - -### Breaking - -- Remove compatibility for old configuration (based on imports) system. Migrate your configuration to the new configuration system for your project before upgrading to Volto 14. See https://docs.voltocms.com/upgrade-guide/#volto-configuration-registry @sneridagh -- Content locking is not a breaking change, but it's worth noting that Volto 14 comes with locking support enabled by default. Latest `plone.restapi` versions is required. See https://docs.voltocms.com/upgrade-guide/ for more information - -### Feature - -- Content locking support for Plone (plone.locking) @avoinea - -## 13.15.0 (2021-09-07) - -### Feature - -- Show item title and item type when hovering over item title and item type icon in folder content view @iFlameing -- Change the batch size of folder content @iFlameing -- Show loading indicator for listing view @iFlameing - -### Bugfix - -- Validate `required` touched-only fields in Form everywhere @nileshgulia1 - -### Internal - -- Add placeholder to WysiwygWidget @nzambello -- Update italian translations @nzambello -- Get SchemaWidget field factories from backend @avoinea - -## 13.14.0 (2021-09-02) - -### Feature - -- Refactor users and groups controlpanel @nileshgulia1 - -## 13.13.0 (2021-09-01) - -### Feature - -- Show version in history view @iFlameing -- Contents shows also array indexes @nzambello - -### Bugfix - -- Fix SearchWidget required `pathname` @avoinea #2645 -- Fix for Contents tag modal @nzambello -- Cut/Copy blocks: fixed cut/copy unselected blocks. @giuliaghisini -- Properly style QueryWidget when used standalone, outside of QuerystringWidget @kreafox -- Add location.search as criteria in `ScrollToTop` component @kreafox -- Scroll to top only if the location pathname changes @kreafox - -### Internal - -- Disabled all the other configuration options when user did not choose any criteria in listing block @iFlameing -- Updated Brazilian Portuguese translations @ericof -- Footer: Point to plone.org instead of plone.com @ericof -- Array and token widget available as named widget @nzambello - -## 13.12.0 (2021-08-20) - -### Feature - -- Multilingual routing was added for sitemap, search, contact-form, change-password, register and password-reset @ionlizarazu -- Opening the search input in the object browser, it will get the focus @nzambello - -### Bugfix - -- Fix ObjectBrowserNav items key @nzambello -- Fix ObjectBrowserNav aria label: id => title @nzambello -- Fix missing code in `ArrayWidget` from refactored `SelectWidget` @sneridagh - -## 13.11.0 (2021-08-18) - -### Feature - -- Add select utils `normalizerValue`, add state to the basic select field forcing it to be fully controlled @sneridagh - -### Bugfix - -- Improve consistency of `TokenWidget`'s use of the choice labels as "values" instead of internal uids assigned by `react-select`. @tiberiuichim -- Solve glitch in async loading options in `AsyncSelect` components @sneridagh - -### Internal - -- Add tests for `Select` component, document the use cases propely @sneridagh -- Upgrade `AsyncSelect` to a version compatible with `react-select` v4 @sneridagh -- Upgrade to latest `react-select` @sneridagh - -## 13.10.0 (2021-08-18) - -### Feature - -- Increase clickable area of right-arrow in objectBrowser @iFlameing -- Prevent form submit when clicking on BlockChooserButton @giuliaghisini -- Make selectedItems Filter work in Contents folder @nileshgulia1 - -### Bugfix - -- Fix SearchWidget search by path @giuliaghisini - -## 13.9.0 (2021-08-18) - -### Feature - -- Removed unnecessary set-cookies for the removal of the authentication cookie when the user is not logged in @mamico -- Add additional classnames for the field wrappers and the fieldsets in forms, this helps to be more addressable in CSS if required @sneridagh - -### Bugfix - -- Add title/tooltip on Toolbar buttons @avoinea #1384 -- Slight CSS fix on `ObjectWidget` for supporting long add element button messages @sneridagh -- Fix the babel view cancel button redirect @iFlameing -- Show toast error when trying to delete item and it's not permitted @danielamormocea - -## 13.8.3 (2021-08-16) - -### Bugfix - -- Prevent form submit when clicking on BlockChooserButton @giuliaghisini -- Add missing `publicURL` to the list of `window.env` serialized variables coming from the hosts configuration to complete the support for seamless mode @sneridagh - -## 13.8.2 (2021-07-20) - -### Bugfix - -- Improve `URLWidget` component, so it uses `flattenToURL` for the value @sneridagh - -## 13.8.1 (2021-07-16) - -### Bugfix - -- Missing prop `properties` passed down required for #2579 to work properly @sneridagh - -## 13.8.0 (2021-07-14) - -### Feature - -- A new component was added, `BlockChooserButton`, it encapsulate the logic of show/hiding the `BlockChooser` @tiberiuichim -- Overload `required` property for blocks config, it supports a function as value taken `properties` (current object data) and `block` (the block being evaluated in `BlockChooser`). The purpose is to enable more control over the available blocks in the Blocks chooser. @sneridagh - -### Bugfix - -- Add fallback to the "image" field in Image Gallery if the listingPreviewImageField defined in the project is not available on an object @jackahl - -## 13.7.0 (2021-07-12) - -### Feature - -- VocabularyTermsWidget option with translations for config.settings.supportedLanguages @ksuess - -### Bugfix - -- Fix InlineForm's understanding of missing default values @rexalex -- Guard in `isInternalURL` to catch non-string values @sneridagh - -### Internal - -- Update `browserlist` DB @sneridagh -- Install `luxon` explicitly to fix `rrule` package flickering deps (yarn problem) @sneridagh -- Add a11y cypress test for table block @ThomasKindermann -- Add Cypress test for Link content type @tisto -- Upgrade plone.restapi to 8.4.1 in the dev buildout @tisto - -## 13.6.0 (2021-07-03) - -### Feature - -- Add VocabularyTermsWidget and map to field with widget attribute set to 'vocabularyterms'. @ksuess - -### Bugfix - -- added "Complementary" landmark-role to skiplink-container for a11y @ThomasKindermann -- changed breadcrumb link text-color slightly for a11y color contrast @ThomasKindermann -- changed table headline text color to black for a11y @ThomasKindermann - -### Internal - -- Updated Brazilian Portuguese translations @ericof - -## 13.5.0 (2021-06-30) - -### Feature - -- Add og tags for social sharing @giuliaghisini @nzambello -- Add interface for plone seo extensions to use values added by them as metadata @jackahl - -### Internal - -- Upgrade to Storybook 6.3, refresh deps version for babel @sneridagh - -## 13.4.0 (2021-06-29) - -### Feature - -- Working copy support for Plone (plone.app.iterate) @sneridagh - -## 13.3.1 (2021-06-29) - -### Internal - -- Remove locales .json files pushed again by mistake, now they are no longer needed to be in the repo, since they are generated at runtime, and included in the released versions @sneridagh - -## 13.3.0 (2021-06-29) - -### Feature - -- Allowing user to paste url in search box in objectBrowser @iFlameing -- Allowing user to click on the breadcrumbs of objectBrowser @iFlameing -- `Navigation` and `Breadcrumbs` are `apiExpanders` aware and run the action depending on them @sneridagh - -### Bugfix - -- Fixed docs for config.settings.externalRoutes @giuliaghisini -- Fix `Pluggable` in the use case that a `Plug` is empty @sneridagh -- Fix `Login` component navigation for `INavigationRoot` structures @sneridagh -- Hyphenation block chooser labels (no html changes) @ksuess - -### Internal - -- Bumps prismjs from 1.23.0 to 1.24.0. @timo - -## 13.2.2 (2021-06-18) - -### Bugfix - -- Avoid debugging error in toolbar @tiberiuichim -- Fix the bug related to specific versioning view @iFlameing -- Fix blocks-listing Cypress test @giuliaghisini -- Fix the translation of header in babel view @iFlameing -- Fix German translations for leadimage and listing block @timo -- Show toast success message when adding a new local role @iFlameing -- Bump postcss from 7.0.29 to 7.0.36 @timo -- Complete Spanish translation @erral -- Complete German translation @timo - -## 13.2.1 (2021-06-14) - -### Bugfix - -- Changed 'batch_size' attribute in 'b_size' in querystring widget. @giuliaghisini - -### Internal - -- Upgrade generator deps @sneridagh - -## 13.2.0 (2021-06-12) - -### Feature - -- Allow passing a schemaEnhancer to QuerystringWidget @tiberiuichim -- Add internal URL blacklist to avoid render custom routes in Volto @nzambello -- In listing blocks, scroll to start of listing block instead page start @giuliaghisini - -### Bugfix - -- Fix addBreaklinesInline when string ends with new line @giuliaghisini -- Changed 'batch_size' attribute in 'b_size' in querystring widget. @giuliaghisini -- Properly respect batching and result limits in listing block @tiberiuichim -- Changed 'batch_size' attribute in 'b_size' in querystring widget. @giuliaghisini -- Properly respect batching and result limits in listing block @tiberiuichim -- Improve folder_contents workflow state (#2017) @avoinea -- Making placeholder image of video block to take 100% width when it is right or left aligned @iFlameing -- Showing clear icon when title is too long in objectbrowser selected items in multiple mode @iFlameing -- Use querystring prop in ListingBody @giuliaghisini -- Set default value selected for variation in listing block @giuliaghisini - -### Internal - -- Add [Volta](https://volta.sh) support @nzambello -- Various minor `Makefile` cleanup @rpatterson -- Improve error handling in UniversalLink @nzambello - -## 13.1.2 (2021-05-26) - -### Internal - -- Make the `AddLinkForm` component generic, to allow reuse in volto-slate @tiberiuichim -- Adding hover effect on ObjectBrowserNav icon @iFlameing - -## 13.1.1 (2021-05-25) - -### Bugfix - -- Second try to fix images in dev mode when api path is present (e.g. using the Robot server in Cypress tests) @sneridagh - -## 13.1.0 (2021-05-24) - -### Feature - -- enabled ability to set 'extractScripts' for error pages @giuliaghisini - -### Bugfix - -- Modify Default and Summary templates to render the LinkMore @ionlizarazu -- Revert #2472, this broke normal development mode images @sneridagh - -## 13.0.2 (2021-05-22) - -### Bugfix - -- Apply the `schemaEnhancer` from the main block even if no variations are found @sneridagh - -### Internal - -## 13.0.1 (2021-05-18) - -### Bugfix - -- Backwards compatibility for existing listing blocks with templates @sneridagh - -## 13.0.0 (2021-05-18) - -### Breaking - -- Seamless mode by default in development. Added `Host` header support for production - deployments, so no `RAZZLE_API_PATH` is required in production builds anymore if the - header is present. Not an strictly breaking change, but it's a default behavior change - worth to notice on its own. No change required in your deployments if you suply - currently `RAZZLE_API_PATH` in build time. See documentation for more information. - @sneridagh -- Deprecate Node 10 since it's out of LTS since April 30th, 2021 @sneridagh -- Remove the "inverted" option in Table Block since it was useless with the current CSS - set. Better naming of options and labels in table block (English). Updating the i18n messages for the used translations is advisable, but not required. @iFlameing -- Get rid of the font icons in the control panels overview @sneridagh -- Refactored `src/components/manage/Widgets/QuerystringWidget` using `ObjectWidget` and schemas @sneridagh -- Refactored `Listing` block using the new `src/components/manage/Widgets/QuerystringWidget`. Introducing a new `showLinkMore` block option opt-in for the additional feature instead of always-in. Deprecated `ListingSidebar` and `src/components/manage/Blocks/Listing/QuerystringWidget` in favor of the new `src/components/manage/Widgets/QuerystringWidget` @sneridagh - -For a more information, please read the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Feature - -- Compile i18n json locales only at build time on the fly and at release time @sneridagh -- Change login form fixing accessibility issues @nzambello - -### Bugfix - -- Fix the Listing block with criteria to render correctly on a non-multilingual homepage. @ionlizarazu -- Fix selection of previous block when deleting a block @tiberiuichim -- Disable `Select` components family to lazy load on SSR, since it's breaking and the fix is quite obscure. They are not valuable on SSR responses anyway. @sneridagh -- Fix leftover from the multilingual fix for composed language names @sneridagh @ericof -- Translate 'All' label in Contents view pagination. @giuliaghisini -- Replace `langmap` dependency with internal code that supports composite language names @sneridagh @ericof -- RenderBlocks: Blocks like the listing block need a path. @ksuess -- Normalize language to get the correct filename in lazy imports for composite language names @sneridagh @ericof -- Checkbox not using `null` as false @sneridagh -- Use params prop in api middleware @giuliaghisini -- Fix PORT env var handling, if you have set the PORT in build time, the setting was - removed back to defaults, now the build time setting is kept (unsetting in build time - and set it in runtime is now the recommended setup) @sneridagh -- Fix sort_order restapi call, works on action for existing listing blocks - and in ListingData saving correctly new ones @nzambello -- Fix `contextURL` in `ObjectBrowser` for special (add/edit) views using `getBaseUrl` @sneridagh - -### Internal - -- Full real zero configuration achievement by turning the stock default - `RAZZLE_PUBLIC_DIR` into a relative path, so we can enable truly movable builds - @sneridagh -- Upgrade Cypress to latest @sneridagh -- Remove surge since it's not used anymore @sneridagh -- Upgrade `react-redux` and friends @sneridagh -- Upgrade `yarnhook` and `yarn-deduplicate` @sneridagh -- Add Listing block test for root path @ionlizarazu -- Only log changes to po (`poToJson`) if running as a script @sneridagh -- Remove json locales from the repo to avoid merge conflicts @sneridagh -- All the `Select` components family in core are loaded through `Loadables` helper @sneridagh -- Updated Brazilian Portuguese translations @ericof -- Improve Github Actions names, separate the code analysis from the main core @sneridagh - -## 13.0.0-alpha.10 (2021-05-16) - -### Bugfix - -- Fix the Listing block with criteria to render correctly on a non-multilingual homepage. @ionlizarazu -- Fix selection of previous block when deleting a block @tiberiuichim - -### Internal - -- Upgrade Cypress to latest @sneridagh -- Remove surge since it's not used anymore @sneridagh -- Upgrade `react-redux` and friends @sneridagh -- Upgrade `yarnhook` and `yarn-deduplicate` @sneridagh -- Add Listing block test for root path @ionlizarazu -- Only log changes to po (`poToJson`) if running as a script @sneridagh - -## 13.0.0-alpha.9 (2021-05-13) - -### Feature - -- Compile i18n json locales only at build time on the fly and at release time @sneridagh - -### Internal - -- Remove json locales from the repo to avoid merge conflicts @sneridagh - -## 13.0.0-alpha.8 (2021-05-12) - -### Bugfix - -- Disable `Select` components family to lazy load on SSR, since it's breaking and the fix is quite obscure. They are not valuable on SSR responses anyway. @sneridagh - -### Internal - -- All the `Select` components family in core are loaded through `Loadables` helper @sneridagh - -## 13.0.0-alpha.7 (2021-05-11) - -### Bugfix - -- Fix leftover from the multilingual fix for composed language names @sneridagh @ericof - -### Internal - -- Updated Brazilian Portuguese translations @ericof - -## 13.0.0-alpha.6 (2021-05-11) - -### Bugfix - -- Translate 'All' label in Contents view pagination. @giuliaghisini -- Replace langmap dependency with internal code that supports composite language names @sneridagh @ericof - -## 13.0.0-alpha.5 (2021-05-10) - -### Bugfix - -- RenderBlocks: Blocks like the listing block need a path. @ksuess -- Normalize language to get the correct filename in lazy imports for composite language names @sneridagh @ericof - -### Internal - -- Updated Brazilian Portuguese translations @ericof - -## 13.0.0-alpha.4 (2021-05-07) - -### Breaking - -- Refactored `src/components/manage/Widgets/QuerystringWidget` using `ObjectWidget` and schemas @sneridagh -- Refactored `Listing` block using the new `src/components/manage/Widgets/QuerystringWidget`. Introducing a new `showLinkMore` block option opt-in for the additional feature instead of always-in. Deprecated `ListingSidebar` and `src/components/manage/Blocks/Listing/QuerystringWidget` in favor of the new `src/components/manage/Widgets/QuerystringWidget` @sneridagh - -For a more information, please read the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Bugfix - -- Checkbox not using `null` as false @sneridagh - -## 13.0.0-alpha.3 (2021-05-06) - -### Bugfix - -- Use params prop in api middleware @giuliaghisini - -- Fix PORT env var handling, if you have set the PORT in build time, the setting was - removed back to defaults, now the build time setting is kept (unsetting in build time - and set it in runtime is now the recommended setup) @sneridagh - -## 13.0.0-alpha.2 (2021-05-05) - -### Bugfix - -- Fix sort_order restapi call, works on action for existing listing blocks - and in ListingData saving correctly new ones @nzambello - -### Internal - -- Updated Brazilian Portuguese translations @ericof - -## 13.0.0-alpha.1 (2021-05-03) - -### Internal - -- Full real zero configuration achievement by turning the stock default - `RAZZLE_PUBLIC_DIR` into a relative path, so we can enable truly movable builds - @sneridagh - -## 13.0.0-alpha.0 (2021-05-03) - -### Breaking - -- Seamless mode by default. Added `Host` header support for deployments, so no - `RAZZLE_API_PATH` is required in production builds anymore if the header is present. - Not an strictly breaking change, but it's a default behavior change worth to notice on - its own. No change required in your deployments if you suply currently - `RAZZLE_API_PATH` in build time. See documentation for more information. @sneridagh -- Deprecate Node 10 since it's out of LTS since April 30th, 2021 @sneridagh -- Remove the "inverted" option in Table Block since it was useless with the current CSS - set. Better naming of options and labels in table block (English). Updating the i18n messages for the used translations is advisable, but not required. @iFlameing -- Get rid of the font icons in the control panels overview @sneridagh - -For a complete list of actions to follow, please read the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Feature - -- Change login form fixing accessibility issues @nzambello - -### Internal - -- Improve Github Actions names, separate the code analysis from the main core @sneridagh - -## 12.14.0 (2021-05-03) - -### Feature - -- Provide api for block extensions. See `/blocks/extensions` in documentation @tiberiuichim - -### Bugfix - -- In BlockDataForm, always clone schema before applying enhancers @tiberiuichim -- In BlockDataForm, don't add the variations field multiple times @tiberiuichim - -## 12.13.0 (2021-04-30) - -### Feature - -- Making objectBrowserWidget context aware @iFlameing - -### Bugfix - -- Adding `flattenToAppURL` in Link component @iFlameing - -- Disable click event of the outside the engine click detection, since it leads to bad - behavior for custom and library elements that try to mount things attaching them in - the Body or outside the detected container @sneridagh - -## 12.12.0 (2021-04-29) - -### Feature - -- Translations german: Login/Register @ksuess - -### Bugfix - -- Fix image gallery in listing block for contained (non-query based) images @sneridagh - -## 12.11.0 (2021-04-28) - -### Feature - -- Implemented Babel view, to compare translated items in add and edit mode. @giuliaghisini -- as in Plone, hide controlpanel for users that are no 'Manager' or 'Site Administrator'. @giuliaghisini -- Improve the blocks engine by adding a detector for clicking outside in the `BlocksForm` @sneridagh -- Include a pluggable architecture for pluggable render-time insertions (similar to ) @tiberiuichim -- Add parseDateTime helper from DatetimeWidget to handle timezones @nzambello - -### Bugfix - -- Include selected block in multiselections @sneridagh -- Correct the selected values rendering at isMulti SelectWidget @ionlizarazu - -### Internal - -- Implement Github actions workflow to deploy the documentation to the Plone Foundation server @ericof -- Pin `immutable` to an updated version that does not produce continuous deprecation notices in console on every change @sneridagh -- Print console.error in SSR if not an ignored error code @nzambello -- Fetch addons with https using mrs-developer @nzambello -- Fix sitemap URL generation @nzambello - -## 12.10.1 (2021-04-14) - -### Bugfix - -- Better error handling code in SSR when an error occurs in the code @ksuess @sneridagh - -## 12.10.0 (2021-04-14) - -### Feature - -- Add support in FileWidget for raw file data in base64 (control panels, not really NamedFile fields) @sneridagh - -### Bugfix - -- ObjectListWidget: edit mode: expand last added item, not first of list. @ksuess -- Improve error handling in SSR when an error occurs in the code @sneridagh - -### Internal - -- Ignore files in addons when building i18n messages in the i18n script, since it's useless (they should be done in the addon itself) and lead to errors when parsing also internal `node_modules` and other utility files @sneridagh - -## 12.9.0 (2021-04-10) - -### Bugfix - -- Avoid double calling asyncPropsExtenders @ksuess @tiberiuichim - -### Internal - -- Fix server when ECONNRESET is received from the backend @sneridagh -- Remove all appearences of `UNSAFE_componentWillMount` since it loads also on the SSR calls too @sneridagh - -## 12.8.0 (2021-04-08) - -### Feature - -- Add configurable api expanders @csenger @nileshgulia1 @tiberiuichim @sneridagh -- In Text block, keep text selection on focus, and move focus to end of text if there's no selection @giuliaghisini - -### Bugfix - -- Fix `fieldset` instead of `fieldSet` in ObjectWidget component @sneridagh - -## 12.7.0 (2021-04-07) - -### Feature - -- Use `onInsertBlock` callback when adding new blocks if available, otherwise fallback to `onMutateBlock` refs #2330 @avoinea - -### Bugfix - -- fix universal link @nileshgulia1s -- fixed recurrence widget when weekly recurrence is selected and event start date is on sunday. @giuliaghisini -- Fix default value for checkbox widget @alexbueckig -- Fix for forms in content types, the fieldset was not being passed over to the field. This affected form generation ids and labels. @sneridagh -- Add a bit of a11y love to the `ObjectListWidget` @sneridagh -- fix universal link when no item content obj passed @nileshgulia1 - -### Internal - -- Add Blocks helpers docs and tests @avoinea - -## 12.6.1 (2021-04-06) - -### Bugfix - -- Remove duplicated wrapper on block edit form @sneridagh -- Fix small catched up issues in tests @sneridagh - -## 12.6.0 (2021-04-05) - -### Feature - -- Add ObjectWidget and ObjectListWidget @sneridagh -- Add `BlockForm` component, variations and schemaExtender aware @sneridagh -- Improvements to the `InlineForm` @sneridagh - -### Bugfix - -- Remove InlineForm default focus on first input @avoinea - -### Internal - -- Add Storybook to the main docs (docs.voltocms.com/storybook) build @sneridagh - -## 12.5.0 (2021-03-31) - -### Feature - -- New setting, `config.settings.showTags` to be able to configure tags visibility on default View @avoinea - -### Bugfix - -### Internal - -- Add toPublicURL helper @nzambello -- Don't show empty groups in BlockChooser @tiberiuichim -- Fix Text Block placeholder regression refs #2322 @avoinea - -### Internal - -- BlocksForm and RenderBlocks now allow a `blocksConfig` configuration object as a prop @tiberiuichim -- Updated italian translations @nzambello - -## 12.4.2 (2021-03-29) - -### Bugfix - -- Re-add formTitle, formDescription, metadata to BlocksForm @avoinea - -## 12.4.1 (2021-03-29) - -### Bugfix - -- Fixed InlineForm boolean false value @razvanMiu -- Fix warning message in console, move open/close detection to the aside itself @sneridagh -- Revert SidebarPortal min-height @avoinea -- Add proper proptype in `SidebarPopup` @sneridagh - -### Internal - -- Update plone/volto Docker image to use latest yo generator and support ADDONS env @avoinea -- Add `docker-compose.yml` to the repo for quick demoing @sneridagh -- Fixed babel config when loading addons (in testing mode) @sneridagh - -## 12.4.0 (2021-03-25) - -### Feature - -- Improved comments @rexalex @avoinea -- Added SidebarPopup component for extra sidebar handling @avoinea -- Use SidebarPopup component in place of CSS transition sidebar @nileshgulia1 - -### Bugfix - -- Fixed multiSelected propType and BlocksForm multiSelected.includes @avoinea -- Fixed italian translations for block `Maps` @giuliaghisini -- Fixed SidebarPortal min-height @avoinea -- Fixed CheckboxWidget state @razvanMiu - -### Internal - -- Upgrade API to Plone 5.2.4 and p.restapi 7.1.0 @sneridagh -- Reorganization of the Cypress tests, now they live in `cypress/tests` @sneridagh -- Splitted Cypress tests into `core` tests and `guillotina` ones for better overall handling @sneridagh - -### Docs - -- Update internal proxy docs @nzambello - -## 12.3.0 (2021-03-18) - -### Feature - -- Improve `ObjectBrowserWidget` adding a manual input field and allow external URLs. Add feature to paste internal URLs and convert them to selected objects. Added the `allowExternals` prop in order to allow this behavior (opt-in). - -### Bugfix - -- Fix storybook initial config registry setup @sneridagh -- Search page now follows Plone's ISearchSchema settings @tiberiuichim -- Improve `ContextNavigation` component, adding the level you are in each iteration @sneridagh - -### Internal - -- Add testing add-on for enable special testing use cases and configuration options @sneridagh -- Add `RAZZLE_TESTING_ADDONS` environment variable for adding addons for testing purposes @sneridagh -- Add "Humboldt Labor" to show cases. -- Updated "Volto in Production" list @alecghica - -### Docs - -- Explicitly mention `src/config` in the "Internal proxy to API" documentation @pigeonflight - -## 12.2.0 (2021-03-03) - -### Feature - -- Adds skiplinks @nzambello -- Fix some semantic tags as nav @nzambello -- Allow addons to specify their own dependencies in their package.json `addons` key, just like the regular Volto projects. This means that it's no longer required to list all possible addons in the Volto project and they can be bootstrapped as being part of a dependency @tiberiuichim -- insert a dimmer with the loading message in the form when the status changes in the content folder. @martina.bustacchini - -### Bugfix - -- Enable draftjs links to open in target blank if is external url. @giuliaghisini - -### Internal - -- Use correct status code for static files error handling @nzambello -- Remove dangling `.replaces(...` for the apiPath and use flattenToAppURL instead @sneridagh - -## 12.1.2 (2021-02-28) - -### Bugfix - -- Fix addon reducers registration @tiberiuichim - -## 12.1.1 (2021-02-26) - -### Bugfix - -- Import asyncConnected actions directly from actions module, the resolution order is different in projects @tiberiuichim @avoinea - -## 12.1.0 (2021-02-24) - -**This is a brown bag release and should not be used, upgrade to Volto 12.1.1 instead.** - -### Feature - -- A new setting, `config.settings.storeExtenders` which allows customization of used Redux middleware @tiberiuichim -- Introduce `config.settings.asyncPropsExtenders` which allows customizing, per route, the `asyncConnected` actions @tiberiuichim @sneridagh - -### Bugfix - -- Adapt to BlocksForm in Blocks Engine @nileshgulia1 -- a11y improvements in `ObjectBrowser` and `BlockChooser` @sneridagh -- Fix UniversalLink for download link. @giuliaghisini - -### Internal - -- Fork redux-connect code in `src/helpers/AsyncConnect`, to allow mixing in config-based asyncConnects. Provide a webpack alias that overloads the redux-connect imports. @tiberiuichim - -### Docs - -- Update wording @svx - -## 12.0.0 (2021-02-20) - -### Breaking - -- Introduction of the new Volto Configuration Registry @sneridagh @tiberiuichim - For more information about this breaking change: https://docs.voltocms.com/upgrade-guide/#upgrading-to-volto-12xx - -### Feature - -- New breadcrumbs `INavigationRoot` aware for the _Home_ icon. This allows inner subsites navigation and better support for multilingual sites. @sneridagh - -### Internal - -- Upgrade plone.restapi to 7.0.0 and Plone to 5.2.3 @sneridagh - -## 12.0.0-alpha.0 (2021-02-17) - -### Breaking - -- Introduction of the new Volto Configuration Registry @sneridagh @tiberiuichim - For more information about this breaking change: https://docs.voltocms.com/upgrade-guide/#upgrading-to-volto-12xx - -## 11.1.0 (2021-02-08) - -### Feature - -- Add `preloadLazyLibs` and `settings.lazyBundles` to allow preloading bundles of lazy libraries @tiberiuichim @silviubogan -- Added onChangeFormData prop to Form component @giuliaghisini -- Internationalization story for add-ons @sneridagh -- robots.txt from plone as fallback (if /public/robots.txt not exists and .env VOLTO_ROBOTSTXT variable not exists.) @giuliaghisini -- UniversalLink and ConditionalLink accepts also an item to link to. If item is of @type Link, a direct link to remote url is generated if user is not logged. @giuliaghisini - -### Bugfix - -- temporarly removed linkDetectionPlugin for draftjs (for some conflicts with AnchorPlugin) @giuliaghisini -- German translation: aria-label of '/contents' button : "Inhalte" not "Inhaltsverzeichnis" @ksuess -- fix view links and others styles of entities on editing Text Block. @giuliaghisini -- Make sidebar-collapsed visible on small mobile. @giuliaghisini -- Fix regresion on the imagesizes styling due to the removal of the id in 11 @sneridagh - -### Internal - -- Update docs: configuration of routes and addonRoutes @ksuess - -## 11.0.0 (2021-01-29) - -### Breaking - -- [circular deps] Move `AlignBlock` component to its rightful place @sneridagh -- Removing id from FormFieldWrapper @iFlameing -- Change default Listing Template to include only Text and renamed the old default Template to Summary Template @jackahl - -### Feature - -- Add `ContextNavigation` component, it can fetch the `@contextnavigation` plone.restapi - endpoint and display a navigation portlet, similar to Plone's classic - navigation portlet. -- added linkDetectionPlugin plugin to draftjs to automatically create links for urls and mails when editing text. @giuliaghisini -- An initial Storybook setup. Start it with `yarn storybook`. Feel free to contribute more stories! @sneridagh -- Add storybook Wrapper utility component. Add ContactForm initial story @tiberiuichim -- make and load configurable reducers in the client `window.__data`, decreasing the html size @nileshgulia1 @tiberiuichim -- Custom group component for selectStyling @nileshgulia1 -- Add new components: RenderBlocks, BlocksForm, DragDropList and EditBlockWrapper @tiberiuichim -- Add `noValueOption` prop to `SelectWidget` so you can opt-out from the "no-value" option so the choices are a closed list @sneridagh -- Provide `injectLazyLibs()` wrapper and `settings.loadables` config to deal with loadable libraries @tiberiuichim - -### Bugfix - -- Better handling of a condition in the new breadcrumbs @sneridagh - -### Internal - -- Upgrade react-select to 4.0.2 @sneridagh -- Upgrade react ecosystem to 13.14.0 @sneridagh -- Add shouldComponentUpdate to blocks @nileshgulia1 -- Update old entry in upgrade guide @tiberiuichim -- Add `@testing-library/cypress` as a dep @sneridagh -- Fix an internal link in documentation @tiberiuichim - -## 10.10.0 (2021-01-22) - -### Feature - -- Simple optional critical-CSS inclusion feature (without the actual building of - the critical CSS) @silviubogan @tiberiuichim @nileshgulia1 -- added support for allowedBlocks and showRestricted for BlockChooser in Form @giuliaghisini -- added objectBrowser to UrlWidget, and attached UrlWidget to remoteUrl field of ContentType Link @giuliaghisini -- managed tel link in UrlWidget and draftjs @giuliaghisini -- added support for allowedBlocks and showRestricted for BlockChooser in Form @giuliaghisini -- Improvements in InlineForm @nileshgulia1 -- Improved form validation. Tested required fields when field is array or richtext @giuliaghisini - -### Bugfix - -- Fix 'All' button batch size in Contents @nzambello -- Fixed field type for 'from' field in ContactForm @giuliaghisini -- handle SelectWidget null value and isMulti(#1915) &(1878) @nileshgulia1 -- Fix typo in ita locales @nzambello -- Wrap objectBrowserWidget with FormFieldWrapper @nileshgulia1 -- Added preventDefault and stopPropagation for toolbar buttons of Table block. @giuliaghisini -- Fix `Contents` breadcrumbs for multilingual sites @sneridagh - -### Internal - -- Add support for `nav_title` in breadcrumbs and navigation @sneridagh -- Add `settings.serverConfig` in the settings object of `~/config`. Add another module, `config/server.js` which is conditionally imported if `__SERVER__`. This module will host settings that are only relevant to the server. Being conditionally imported means that the code is safe to require server-only nodejs packages. @tiberiuichim -- Update browserlist and caniuse-lite @sneridagh -- Document deprecation of `@plone/create-volto-app` @sneridagh @nileshgulia1 -- Adding classname in TextWidget and ObjectBrowserBody so that we can target those element in tests. @iFlameing -- Add support for `nav_title` in breadcrumbs and navigation @sneridagh - -## 10.9.2 (2021-01-15) - -### Bugfix - -- Make a cypress test more resilient to platform differences @tiberiuichim -- Fix regression introduced by improve CSS in the inner toolbar for the image block to support narrower width (like for using it inside grid blocks) @sneridagh -- Avoid a bug in cypress tests caused by multi-block copy/paste @tiberiuichim - -### Internal - -- i18n for a literal in the table block @sneridagh - -## 10.9.1 (2021-01-14) - -### Bugfix - -- Fix regression introduced by improve CSS in the inner toolbar for the image block to support narrower width (like for using it inside grid blocks) @sneridagh - -## 10.9.0 (2021-01-14) - -### Feature - -- Enhance `BlockChooser` by adding support for `allowedBlocks` and `showRestricted` @avoinea @sneridagh - -### Bugfix - -- Better handling of @@images pipeline errors @tiberiuichim -- Fix `More` menu when using with Plone 4 backend / history action is undefined (#2120) @avoinea -- Fix `/sharing` page when using with Guillotina (#2122) @avoinea -- Improve CSS in the inner toolbar for the image block to support narrower width (like for using it inside grid blocks) @sneridagh - -### Internal - -- Move express middleware routes (sitemap, download, images and robotstxt) out of server.jsx into their own `express-middleware/*.js` modules. All express middleware now has access to the redux store, api middleware and an errorHandler, available under `req.app.locals` @tiberiuichim - -## 10.8.0 (2021-01-11) - -### Feature - -- Add proper icons to the table block @sneridagh - -### Internal - -- Add `packages` directory to the `modulePathIgnorePatterns` for the jest tests @sneridagh -- Add `packages` directory in npmignore @sneridagh - -## 10.7.0 (2021-01-05) - -### Feature - -- Lazy load image in blocks Image and HeroImage @mamico - -### Bugfix - -- Fix redirection for Link objects. @cekk -- Fix import order in server.jsx. @cekk @tiberiuichim -- Make sentry config more resilient to edge cases (SPA, storybook) @sneridagh -- Handle errors on file and image download (#2098) @cekk -- Remove test dependant on the year in `Copyright` footer section @sneridagh -- Increase maxResponseSize for superagent calls. Now is 500mb (#2098) @cekk - -### Internal - -- Translations german: Unauthorized, Login/Register @ksuess -- Removing id from FormFieldWrapper @iFlameing - -## 10.6.1 (2020-12-21) - -### Bugfix - -- Better API helper end request handling, since the existing one was causing problems and rendered the SSR server unusable in case of the request was rejected @sneridagh - -### Internal - -- Add a paragraph on dealing with CORS errors in Deploying doc page @tiberiuichim -- Remove useless RobotFramework related packages, keep only the minimum required ones @sneridagh -- Updated italian translations @nzambello - -## 10.6.0 (2020-12-18) - -### Feature - -- Allow setting a custom robots.txt from environment with the `VOLTO_ROBOTSTXT` environment variable @tiberiuichim - -### Bugfix - -- Replace `__SERVER__` occurrence from table `Edit` component @sneridagh - -## 10.5.0 (2020-12-17) - -### Feature - -- Adding `All` button to folder content @iFlameing - -### Bugfix - -- Fix "is client" check for SidebarPortal @tiberiuichim @sneridagh - -## 10.4.3 (2020-12-15) - -### Internal - -- Bring back `App` to `components/index.js` for now, since it's breaking the projects - where it gets referenced from `routes.js`. @sneridagh - -## 10.4.2 (2020-12-15) - -**This is a brown bag release and should not be used, upgrade to Volto 10.4.3 instead.** - -### Bugfix - -- Fix numeric widget console warnings regarding flex styling refs #2059 @ichim-david -- Fix numeric widget crash once we click inside it refs #2059 @ichim-david - -### Internal - -- Fix some key points to improve the circular imports problem @sneridagh - - - `App` and `View` components are meant to be used only by Volto internals, so it's no - point into having them exported in `components/index.js` that facilitated a path for - circular imports. - - `withObjectBrowser` and friends also are prone to facilitate a path for having - circular imports, so we are using there only absolute imports. - - All these changes are non-breaking and non-intrusive. - -## 10.4.1 (2020-12-12) - -### Bugfix - -- Make sure that prism is loaded before rendering HTML block @tiberiuichim - -## 10.4.0 (2020-12-11) - -### Feature - -- Add ability to filter the attributes that are saved in the ObjectBrowserWidget @sneridagh -- Add `object_browser` as widget @sneridagh - -### Bugfix - -- Adding video thumbnail for the .mp4 extension @iFlameing. - -### Internal - -- Added new in productions sites to README @terapyon - -## 10.3.0 (2020-12-04) - -### Feature - -- added search depth in listing and updated it locales @giuliaghisini -- Add emailSend action @nzambello -- lazy load react-dropzone @nileshgulia1 - -### Bugfix - -- Fix addons loader name generation on Windows @tiberiuichim -- For python3.9 compatibility, install wheel package in build-backend targets @tiberiuichim - -### Internal - -- Tweak Cypress command `waitForResourceToLoad` to timeout after 50 tries. @tiberiuichim - -## 10.2.0 (2020-12-04) - -### Feature - -- Generate language file of added missing German translations by @tisto. @ksuess - -### Bugfix - -- Fix regression in the `getContent` action with the expandable missing @sneridagh - -## 10.1.0 (2020-11-30) - -### Feature - -- Add missing German translations @tisto - -## 10.0.0 (2020-11-30) - -### Feature - -- Provide operations on multiple-selected blocks: delete, cut/copy and paste. You can trigger the "multiselected blocks" by holding the shift key and clicking on another block. You can add/remove blocks to the selection with the Control key. Holding Control when you click on the Paste button doesn't clear the clipboard, so you can paste multiple times. The blocks clipboard uses the browser's local storage to synchronize between tabs. @tiberiuichim -- Allow reducers to be persisted using localstorage @tiberiuichim - -### Breaking - -- Removal of the Razzle patch that was introduced in 9.0.0 @sneridagh - See https://docs.voltocms.com/upgrade-guide/ for more details. -- Fetched content with `getContent` no longer includes fullobjects by default @tiberiuichim - -### Bugfix - -- Fix link to login in the Unauthorised component @sneridagh - -### Internal - -- Add details on how to run Cypress integration tests @tiberiuichim -- Upgrade `@testing-library/react` to 11.2.2. Add `jest-environment-jsdom-sixteen as upgraded jsdom implementation @tiberiuichim -- Split some small prismjs related files (used in HTML block) in separate chunks @tiberiuichim -- Remove dangling analyzer plugin @sneridagh -- Support for Guillotina 6 @bloodbare @sneridagh -- Update Cypress to version 5.6.0 @sneridagh -- Terse `react-intl` errors in console during development turning them into warnings @sneridagh - -## 9.2.0 (2020-11-24) - -**This is a brown bag release and should not be used, upgrade to Volto 10.x.x instead.** -See https://docs.voltocms.com/upgrade-guide/ for more information. - -### Feature - -- Remove the Razzle patch for the local, "inline" Volto Razzle plugins @tiberiuichim @sneridagh - -### Bugfix - -- Move missplaced `appExtras` into settings @sneridagh - -### Internal - -- Make filewidget label more consistent @tisto - -## 9.1.0 (2020-11-20) - -### Feature - -- Extend the internal proxy capabilities, now the target is overridable and SSL aware @sneridagh -- Added new environment variables for the internal proxy `RAZZLE_PROXY_REWRITE_TARGET` and `RAZZLE_PROXY_REWRITE_TARGET` @sneridagh -- Enhance `AppExtras` component to make it pluggable through the - `config.settings.appExtras`. These are router-path filtered components that - are rendered inside the `AppExtras` component @tiberiuichim - -### Bugfix - -- Fix Sentry tags and extra via settings.sentryOptions @avoinea -- Fix `yarn analyze` command by packing our own version of - webpack-bundle-analyzer integration. It has a few changes to the old default - configuration. There is an alternative way of triggering the bundle analyzer, - with the `OFFLINE_BUNDLE_ANALYZE=true` env variable, which avoids starting - the HTTP bundle analyzer server. Also, it always saves a report html file. - @tiberiuichim - -### Internal - -- Improve developer documentation. Add several new chapters @tiberiuichim - -## 9.0.0 (2020-11-15) - -### Breaking - -- Upgrade Razzle to 3.3.7 @tiberiuichim @sneridagh - - Razzle 3.3.7 prepares the transition to the upcoming Razzle 4 so it improves and - unifies the extensibility story at the cost of change the signature of the - `razzle.config.js` and how plugins are declared. It also enables by default the new - _React Fast Refresh_ feature implemented by the React community, which improves the - refresh of the code while in development. - -- Babel plugins housekeeping - - Deprecated proposals: - - - @babel/plugin-proposal-function-bind - - @babel/plugin-proposal-do-expressions - - @babel/plugin-proposal-logical-assignment-operators - - @babel/plugin-proposal-pipeline-operator - - @babel/plugin-proposal-function-sent - -For a complete list of actions to follow, please read the upgrade guide -https://docs.voltocms.com/upgrade-guide/ - -### Feature - -- Add `webpack-relative-resolver` plugin. For addons and Volto, it normalizes local relative imports to package-rooted imports. An import such as `import Something from './Something'` would be rerouted internally as `import Something from '@collective/someaddon/Something'`. By doing so we get easier customization of addons, as they don't have to be so strict with their import and exports @tiberiuichim -- Posibility to configure Sentry via `settings.sentryOptions` configuration key @avoinea -- Catch `console.error` by default with Sentry @avoinea -- Refactor CT icons helper: add getContentIcons @nzambello - -### Bugfix - -- Properly return 404, 401 and 403 on SSR, when appropriate @tiberiuichim -- Fix Guillotina PATCH by adding the `@static_behaviors` field inconditionally @sneridagh - -### Internal - -## 8.10.1 (2020-11-13) - -### Bugfix - -- Fix leaking input CSS in the link widget in draftjs @sneridagh - -### Internal - -- Move Guillotina CI job to GH actions @sneridagh - -## 8.10.0 (2020-11-12) - -### Feature - -- Adding show all button in UsersControlpanel @iFlameing -- Now you can prettify the html code in HTML block @iFlameing -- Adding preview image placeholder in Video Block @iFlameing - -### Bugfix - -- Fix error object in clipboard reducer @iFlameing -- Making QuerystringWidget more resilient by handeling null value @iFlameing -- Fixing bug related to initiation of table block with previous table block data @iFlameing -- enabled no-folderish CT to be translated @giuliaghisini - -### Internal - -- Changing checkbox widget of exclude-nav to select widget @iFlameing - -## 8.9.2 (2020-11-06) - -### Bugfix - -- Revert type-in detection in draftjs link widget, as that leads to a regression @sneridagh -- Fix and refactoring FileWidget @iFlameing - -## 8.9.1 (2020-11-06) - -### Bugfix - -- Fix SSR rendering in table blocks @sneridagh - -## 8.9.0 (2020-11-05) - -### Feature - -- Added Dropzone in FileWidget @iFlameing -- Making inline link toolbar, location aware in content browser @iFlameing. -- Detect if the link typed or pasted in the link widget of the text block is internal @sneridagh - -## 8.8.1 (2020-11-04) - -### Bugfix - -- Improve misleading translations deleted message @sneridagh -- Fixing overlap of labels with each other in select widget @iFlameing -- Throw error in crashReporter; also log sentry errors in server @tiberiuichim - -### Internal - -- Split razzle svg and sentry loaders to separate files @tiberiuichim -- prevent form without blocks. Form always have at least the default block. @giuliaghisini -- Fix default target for links in text blocks @giuliaghisini - -### Internal - -## 8.8.0 (2020-11-02) - -### Feature - -- Add support for the new active LTS NodeJS version 14. NodeJS 10 eol will happen on 2021-04-30 and Volto will update accordingly. More information on https://nodejs.org/en/about/releases @sneridagh - -## 8.7.1 (2020-10-29) - -### Bugfix - -- Added loading icon when doing actions in folder-contents @giuliaghisini -- Fix German translation "from" -> "E-Mail" in contact form @tisto - -## 8.7.0 (2020-10-27) - -### Feature - -- Manage translations view @sneridagh - -### Internal - -- Update docs build and include pygments support for jsx @sneridagh - -## 8.6.0 (2020-10-25) - -### Feature - -- Added placeholder background color same as selected one @iFlameing -- Showing notification when user sort the folder-content @iFlameing -- Render full language name (e.g. "English") instead of 2 character language code in language selector, matching Plone default behavior. @mikejmets - -### Bugfix - -- A pathname like /policy/edit does not show the Unauthorized or Forbidden component when not logged in, ref #1936. @silviubogan -- Fixes secondary views in toolbar @iFlameing @sneridagh -- Fixing overlay expansion during link assign from objectbrowser in edit mode @iFlameing - -### Internal - -- Added new in productions sites to README @wkbkhard -- Writing test for the lisiting block location relative criteria @iFlameing -- Add `UniversalLink` to handle internal/external/download links @nzambello - -## 8.5.4 (2020-10-23) - -### Breaking - -### Feature - -### Bugfix - -- Fixing bug for link when inseting break lines in list tag for view mode @iFlameing - -## 8.5.3 (2020-10-22) - -### Bugfix - -- Removed timezone initialization for DatetimeWidget, ref #1923. @razvanMiu - -## 8.5.2 (2020-10-21) - -### Bugfix - -- Showing error notification when user try to paste disallowed content type. @iFlameing - -### Internal - -- Added environment parameter `RAZZLE_BIND_ADDRESS` to be able to bind server to localhost or other specific IPs instead of 0.0.0.0 @achimwilde - -## 8.5.1 (2020-10-21) - -### Bugfix - -- Fix sharing for when users has dots on them @sneridagh - -## 8.5.0 (2020-10-20) - -### Bugfix - -- Japanese translation updated @terapyon - -## 8.5.0-alpha.2 (2020-10-20) - -### Bugfix - -- Update German translation @ksuess - -### Internal - -- Fix runtimeConfig relative vs absolute import @avoinea - -## 8.5.1-alpha.0 (2020-10-19) - -### Feature - -- Adding softlinebreak in list tag @iFlameing - -### Bugfix - -- Errors catched by the default error handler are sent to sentry @zotya -- Fixed a problem what occured when RAZZLE*SENTRY_DSN was missing but the other RAZZLE_SENTRY*\* variables were set @zotya - -### Internal - -- Fix sentry docs markdown format @avoinea - -## 8.5.0-alpha.0 (2020-10-14) - -### Feature - -- Sentry integration @zotya -- All the environment variables defined at runtime that have the `RAZZLE_` prefix, are now available in the browser under window.env @zotya - -## 8.4.0 (2020-10-14) - -### Feature - -- Add `Style`, a wrapper component that applies float and width classes to wrapped content (typically blocks) @tiberiuichim -- Add `AlignWidget`, a widget that wraps the `AlignBlock` helper @tiberiuichim - -### Bugfix - -- Folder contents view: Save additional columns and updated order of columns @ksuess -- Fixed edit link in draft-js when link is selected from word-end to word-start @giuliaghisini -- Revert PR No. 1820 to fix linebreaks on inline links in draftJS @steffenri - -### Internal - -- Keep `@babel/core` in Volto core in sync with `babel-preset-razzle` it fixes #1897 @sneridagh - -## 8.3.0 (2020-10-12) - -### Feature - -- Adding droppable placeholder for Image Block @iFlameing - -### Bugfix - -- Test if content exists in ListingBody, for addon Dropdownmenu @giuliaghisini - -## 8.2.6 (2020-10-12) - -### Bugfix - -- Fix break-line in view mode @iFlameing - -## 8.2.5 (2020-10-08) - -### Bugfix - -- Fixing the bleed out of the modal for long filename @iFlameing - -## 8.2.4 (2020-10-08) - -### Bugfix - -- Fixing table block edit @iFlameing - -## 8.2.3 (2020-10-07) - -### Bugfix - -- Use Plone `I18N_LANGUAGE` cookie instead of `language` @cekk - -## 8.2.2 (2020-10-06) - -### Bugfix - -- Upgrade react-dropzone from 5.1.0 to 11.1.0 @nileshgulia1 -- Update German translations @tisto - -## 8.2.1 (2020-10-06) - -### Bugfix - -- Querystingsearch action now uses correct relative path, if specified. Fixes #1861 @jackahl -- Fixing ObjectBrowser search input reload @iFlameing -- Fix broken current folder by default in content browser for image links, solves #1860 @sneridagh - -## 8.2.0 (2020-09-27) - -### Feature - -- Add Basque translation @erral - -### Bugfix - -- Added prop resettable to DatetimeWidget @damiDevRT -- Removed the ability to reset the datepicker in the recurrence widget to prevent the uncontrolled creation of recurrences @damiDevRT -- Fix regression in setting selected sidebar tab by blocks @tiberiuichim - -## 8.1.1 (2020-09-27) - -### Bugfix - -- Japanese translation updated @terapyon - -## 8.1.0 (2020-09-22) - -### Breaking - -### Feature - -- Create link in Draftjs using Objectbrowser @giuliaghisini - -### Bugfix - -- Allow select widget to reset when the incoming props change. The react-select widget has its own internal state, so if you initialise the widget without choices, then populate the choices, it wouldn't properly show the default value @tiberiuichim - -### Internal - -- Fix console warning in ToHTML @iFlameing - -## 8.0.1 (2020-09-22) - -### Bugfix - -- Fix word overflow from html-block @iFlameing -- Fix Cypress test for image upload @zotya - -### Internal - -- Improve developer experience, don't logout on hot-reload @tiberiuichim -- Cleanup eslint in razzle.config.js @tiberiuichim - -## 8.0.0 (2020-09-18) - -### Breaking - -- Change dummy-addons-loader.js fixture name to `jest-addons-loader.js`, to match existing `jest-svgsystem-transform.js` @tiberiuichim - -### Feature - -- Added Schema Editor within Dexterity Content-Types Controlpanel @rexalex @avoinea #1517 -- Added Blocks Layout Editor within Dexterity Content-Types Controlpanel @avoinea #1517 -- Added missing components for Email and Url widgets #1246 @rexalex -- Use content title instead of image id in alt tag @nileshgulia1 - -### Bugfix - -- Fix the broken profile view in Toolbar @iFlameing - -### Internal - -- Hide block chooser button using React logic instead of CSS. This makes it easier to support nested blocks @tiberiuichim - -- Wrap addon configuration loaders in a wrapper to check that they return back config @tiberiuichim - -## 7.15.0 (2020-09-15) - -### Feature - -- Added missing components for Email and Url widgets #1246 @rexalex -- Show backend validation errors on corresponding fields #1246 @rexalex -- Validation implemented for add user/group @rexalex -- Show Username when Firstname attr is missing in UsersControlPanelUser @iFlameing - -### Bugfix - -- When dealing with authentication token expiration set to 0, auto-refresh token in one hour instead of logging out use @tiberiuichim -- Fixed front-end field validation #1246 @rexalex -- Fixed date only widget rendering #1246 @rexalex -- Fix errors with SelectWidget when removing the only element @rexalex - -## 7.14.2 (2020-09-10) - -### Bugfix - -- Hyphenate sidebar labels @ksuess -- Update German translations @tisto - -## 7.14.1 (2020-09-09) - -### Bugfix - -- Fix customization mechanism where customization paths end with `/` @tiberiuichim - -## 7.14.0 (2020-09-08) - -### Feature - -- Render form with vertical tabs, setting the property `verticalFormTabs` in config.js @giuliaghisini - -### Bugfix - -- Imported locales by razzle and fixed import locale @giuliaghisini -- Fix console warning due to uncontrolled selectWidget component @nileshgulia1 - -## 7.13.0 (2020-09-07) - -### Feature - -- Add NumberWidget, an input widget for numbers @tiberiuichim - -### Bugfix - -- Fixing the Image size settings in sidebar when Image alignment changes @iFlameing - -## 7.12.1 (2020-09-04) - -### Bugfix - -- Fix checkbox widget styles @nzambello - -## 7.12.0 (2020-09-04) - -### Feature - -- Allow Volto projects to customize (via webpack resolve aliases) addons. Allow addons to customize Volto and other addons. Allow Volto projects to customize Volto in a `src/customizations/volto` folder, for better organization of the customizations folder. @tiberiuichim @sneridagh - -## 7.11.3 (2020-08-28) - -### Bugfix - -- On image upload in a block, don't overwrite the global `state.content.data` with new image data @tiberiuichim @silviubogan - -### Internal - -- Add a `subrequest` option to the `createContent` action @tiberiuichim @silviubogan - -## 7.11.2 (2020-08-28) - -### Bugfix - -- Fix bug introduced in 7.9.0, properly return a list of results when dealing with batched api requests @tiberiuichim -- In folder contents batch upload, use a subrequest to avoid breaking the global `content.data` state @tiberiuichim -- Fix `null` response issue when passing custom `Accept:` headers to actions #1771 @avoinea -- Removed all `<<<<