diff --git a/.gitignore b/.gitignore index bf0baa3966..5eb32336df 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,7 @@ eslint.xml yarn-error.log build .changelog.draft +.registry.loader.js # yarn 3 .pnp.* diff --git a/packages/volto/.eslintrc b/packages/volto/.eslintrc index 992df17e6f..77b2c091ed 100644 --- a/packages/volto/.eslintrc +++ b/packages/volto/.eslintrc @@ -54,7 +54,7 @@ "rootPathSuffix": "src", }, }, - "import/core-modules": ["load-volto-addons"], + "import/core-modules": ["@plone/registry/addons-loader"], "react": { "version": "detect", }, diff --git a/packages/volto/package.json b/packages/volto/package.json index c49b5b4b53..2b9b7023f2 100644 --- a/packages/volto/package.json +++ b/packages/volto/package.json @@ -101,7 +101,7 @@ "~/config": "/src/config", "~/../locales/${lang}.json": "/locales/en.json", "(.*)/locales/(.*)": "/locales/$2", - "load-volto-addons": "/jest-addons-loader.js", + "@plone/registry/addons-loader": "/jest-addons-loader.js", "@package/(.*)$": "/src/$1", "@root/config": "/jest-addons-loader.js", "@root/(.*)$": "/src/$1", diff --git a/packages/volto/src/components/manage/AnchorPlugin/components/LinkButton/AddLinkForm.jsx b/packages/volto/src/components/manage/AnchorPlugin/components/LinkButton/AddLinkForm.jsx index 7523c33205..0b933ea4af 100644 --- a/packages/volto/src/components/manage/AnchorPlugin/components/LinkButton/AddLinkForm.jsx +++ b/packages/volto/src/components/manage/AnchorPlugin/components/LinkButton/AddLinkForm.jsx @@ -16,7 +16,7 @@ import { URLUtils, } from '@plone/volto/helpers/Url/Url'; -import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick/doesNodeContainClick'; +import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick'; import { Input, Form, Button } from 'semantic-ui-react'; import { defineMessages, injectIntl } from 'react-intl'; diff --git a/packages/volto/src/components/manage/BlockChooser/BlockChooserButton.jsx b/packages/volto/src/components/manage/BlockChooser/BlockChooserButton.jsx index 9655937acd..c0d3f9d0cf 100644 --- a/packages/volto/src/components/manage/BlockChooser/BlockChooserButton.jsx +++ b/packages/volto/src/components/manage/BlockChooser/BlockChooserButton.jsx @@ -1,5 +1,5 @@ import React from 'react'; -import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick/doesNodeContainClick'; +import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick'; import addSVG from '@plone/volto/icons/circle-plus.svg'; import { blockHasValue } from '@plone/volto/helpers/Blocks/Blocks'; import Icon from '@plone/volto/components/theme/Icon/Icon'; diff --git a/packages/volto/src/components/manage/Sidebar/SidebarPopup.jsx b/packages/volto/src/components/manage/Sidebar/SidebarPopup.jsx index 3c701e0129..290ac8f1ae 100644 --- a/packages/volto/src/components/manage/Sidebar/SidebarPopup.jsx +++ b/packages/volto/src/components/manage/Sidebar/SidebarPopup.jsx @@ -2,7 +2,7 @@ import React from 'react'; import { createPortal } from 'react-dom'; import { CSSTransition } from 'react-transition-group'; import PropTypes from 'prop-types'; -import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick/doesNodeContainClick'; +import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick'; const DEFAULT_TIMEOUT = 500; diff --git a/packages/volto/src/components/manage/Toolbar/Toolbar.jsx b/packages/volto/src/components/manage/Toolbar/Toolbar.jsx index 5db0b4a3f4..f30d666b90 100644 --- a/packages/volto/src/components/manage/Toolbar/Toolbar.jsx +++ b/packages/volto/src/components/manage/Toolbar/Toolbar.jsx @@ -10,7 +10,7 @@ import { Link } from 'react-router-dom'; import jwtDecode from 'jwt-decode'; import { connect } from 'react-redux'; import { compose } from 'redux'; -import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick/doesNodeContainClick'; +import doesNodeContainClick from '@plone/volto/helpers/Utils/doesNodeContainClick'; import { withCookies } from 'react-cookie'; import filter from 'lodash/filter'; import find from 'lodash/find'; diff --git a/packages/volto/src/components/theme/App/App.jsx b/packages/volto/src/components/theme/App/App.jsx index 3256444617..551a74dacf 100644 --- a/packages/volto/src/components/theme/App/App.jsx +++ b/packages/volto/src/components/theme/App/App.jsx @@ -44,6 +44,7 @@ import clearSVG from '@plone/volto/icons/clear.svg'; import MultilingualRedirector from '@plone/volto/components/theme/MultilingualRedirector/MultilingualRedirector'; import WorkingCopyToastsFactory from '@plone/volto/components/manage/WorkingCopyToastsFactory/WorkingCopyToastsFactory'; import LockingToastsFactory from '@plone/volto/components/manage/LockingToastsFactory/LockingToastsFactory'; +// TODO: RouteAnnouncer fails with hydation error? import RouteAnnouncer from '@plone/volto/components/theme/RouteAnnouncer/RouteAnnouncer'; /** @@ -185,7 +186,7 @@ export class App extends Component { - + {/* */}