From 356f77a8d285eb0b855130b0db0b8432ad6245d8 Mon Sep 17 00:00:00 2001 From: Giulia Ghisini Date: Tue, 24 Dec 2024 11:52:09 +0100 Subject: [PATCH] chore: removed volto imports from barrel files --- src/components/DropdownMenu.jsx | 11 +++++------ .../components/theme/Navigation/Navigation.jsx | 2 +- src/widget/MenuConfigurationForm.jsx | 6 +++--- src/widget/MenuConfigurationWidget.jsx | 3 ++- src/widget/RadioWidget.jsx | 2 +- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/components/DropdownMenu.jsx b/src/components/DropdownMenu.jsx index 632bdeb..8c4b4d0 100644 --- a/src/components/DropdownMenu.jsx +++ b/src/components/DropdownMenu.jsx @@ -4,14 +4,13 @@ import { defineMessages, useIntl } from 'react-intl'; import { Segment, Container, Icon, Grid, Button } from 'semantic-ui-react'; import { map } from 'lodash'; import cx from 'classnames'; -import { ConditionalLink } from '@plone/volto/components'; +import ConditionalLink from '@plone/volto/components/manage/ConditionalLink/ConditionalLink'; import { - flattenToAppURL, getBlocksFieldname, getBlocksLayoutFieldname, hasBlocksData, - getBaseUrl, -} from '@plone/volto/helpers'; +} from '@plone/volto/helpers/Blocks/Blocks'; +import { flattenToAppURL, getBaseUrl } from '@plone/volto/helpers/Url/Url'; import config from '@plone/volto/registry'; import './dropdownmenu.css'; @@ -38,8 +37,8 @@ const DropdownMenu = ({ menu, open = false, closeMenu }) => { menu.navigationRoot?.length === 1 ? 8 : menu.navigationRoot?.length > 2 || menu.navigationRoot?.length === 0 - ? 12 - : 6; + ? 12 + : 6; let hasBlocks = hasBlocksData(menu); if (menu?.blocks && Object.keys(menu.blocks).length === 1) { let b = menu.blocks[Object.keys(menu.blocks)[0]]; diff --git a/src/customizations/components/theme/Navigation/Navigation.jsx b/src/customizations/components/theme/Navigation/Navigation.jsx index 64cdbcb..502cae7 100644 --- a/src/customizations/components/theme/Navigation/Navigation.jsx +++ b/src/customizations/components/theme/Navigation/Navigation.jsx @@ -12,7 +12,7 @@ import cx from 'classnames'; import OutsideClickHandler from 'react-outside-click-handler'; import config from '@plone/volto/registry'; -import { flattenToAppURL } from '@plone/volto/helpers'; +import { flattenToAppURL } from '@plone/volto/helpers/Url/Url'; import DropdownMenu from '../../../../components/DropdownMenu'; import { getDropdownMenuNavitems } from '../../../../actions'; diff --git a/src/widget/MenuConfigurationForm.jsx b/src/widget/MenuConfigurationForm.jsx index 7458674..409b705 100644 --- a/src/widget/MenuConfigurationForm.jsx +++ b/src/widget/MenuConfigurationForm.jsx @@ -3,13 +3,13 @@ import { defineMessages, useIntl } from 'react-intl'; import { v4 as uuid } from 'uuid'; import { isEmpty } from 'lodash'; import { Form as UIForm, Grid, Button } from 'semantic-ui-react'; +import Sidebar from '@plone/volto/components/manage/Sidebar/Sidebar'; +import { Form } from '@plone/volto/components/manage/Form'; import { - Form, TextWidget, CheckboxWidget, ObjectBrowserWidget, - Sidebar, -} from '@plone/volto/components'; +} from '@plone/volto/components/manage/Widgets'; import { RadioWidget } from 'volto-dropdownmenu/widget'; import { Portal } from 'react-portal'; diff --git a/src/widget/MenuConfigurationWidget.jsx b/src/widget/MenuConfigurationWidget.jsx index f2ba9eb..9e86131 100644 --- a/src/widget/MenuConfigurationWidget.jsx +++ b/src/widget/MenuConfigurationWidget.jsx @@ -9,7 +9,8 @@ import { Segment, Header, } from 'semantic-ui-react'; -import { TextWidget, Component } from '@plone/volto/components'; +import Component from '@plone/volto/components/theme/Component/Component'; +import { TextWidget } from '@plone/volto/components/manage/Widgets'; import { flattenToAppURL } from '@plone/volto/helpers/Url/Url'; import './menu_configuration.css'; diff --git a/src/widget/RadioWidget.jsx b/src/widget/RadioWidget.jsx index b82e609..b862617 100644 --- a/src/widget/RadioWidget.jsx +++ b/src/widget/RadioWidget.jsx @@ -1,6 +1,6 @@ import React from 'react'; import { Button } from 'semantic-ui-react'; -import { FormFieldWrapper } from '@plone/volto/components'; +import { FormFieldWrapper } from '@plone/volto/components/manage/Widgets'; import cx from 'classnames'; import './radio_widget.css';