}
+ />
+ } + /> +
-
- xxxxxxxxxx
-
-
- Customize how the edit view will look like.
Set the display field of your entry @@ -1111,29 +1123,29 @@ exports[`EditSettingsView renders and matches the snapshot 1`] = `
Customize how the edit view will look like.
Set the display field of your entry
@@ -2649,29 +2673,29 @@ exports[`EditSettingsView should add field 1`] = `API ID : restaurant
diff --git a/packages/core/admin/admin/src/content-manager/pages/EditViewLayoutManager/Permissions.js b/packages/core/admin/admin/src/content-manager/pages/EditViewLayoutManager/Permissions.js index 8d4d4eb715..fefbe2629b 100644 --- a/packages/core/admin/admin/src/content-manager/pages/EditViewLayoutManager/Permissions.js +++ b/packages/core/admin/admin/src/content-manager/pages/EditViewLayoutManager/Permissions.js @@ -1,7 +1,7 @@ import React, { memo, useMemo } from 'react'; import PropTypes from 'prop-types'; import { useRBAC, LoadingIndicatorPage } from '@strapi/helper-plugin'; -import isEqual from 'react-fast-compare'; +import isEqual from 'lodash/isEqual'; import EditView from '../EditView'; import { generatePermissionsObject } from '../../utils'; diff --git a/packages/core/admin/admin/src/content-manager/pages/ListSettingsView/components/DraggableCard.js b/packages/core/admin/admin/src/content-manager/pages/ListSettingsView/components/DraggableCard.js index a4b5e22a28..da97957363 100644 --- a/packages/core/admin/admin/src/content-manager/pages/ListSettingsView/components/DraggableCard.js +++ b/packages/core/admin/admin/src/content-manager/pages/ListSettingsView/components/DraggableCard.js @@ -6,8 +6,8 @@ import { getEmptyImage } from 'react-dnd-html5-backend'; import { useIntl } from 'react-intl'; import { Flex, Box, Typography } from '@strapi/design-system'; import { Pencil, Cross, Drag } from '@strapi/icons'; -import CardPreview from './CardPreview'; -import ellipsisCardTitle from '../utils/ellipsisCardTitle'; + +import { CardDragPreview } from '../../App/components/CardDragPreview'; import { getTrad, ItemTypes } from '../../../utils'; const ActionButton = styled.button` @@ -85,7 +85,6 @@ const DraggableCard = ({ const dropRef = useRef(null); const [, forceRerenderAfterDnd] = useState(false); const editButtonRef = useRef(); - const cardEllipsisTitle = ellipsisCardTitle(labelField); const handleClickEditRow = () => { if (editButtonRef.current) { @@ -93,6 +92,7 @@ const DraggableCard = ({ } }; + // TODO: this can be simplified a lot by using the useDragAndDrop() hook const [, drop] = useDrop({ accept: ItemTypes.FIELD, hover(item, monitor) { @@ -176,8 +176,8 @@ const DraggableCard = ({ return (Define the settings of the list view.