From 5b3add2bffa435af2ac3022fe669e6b4027d9762 Mon Sep 17 00:00:00 2001 From: Gandharv Date: Thu, 5 Jan 2023 11:26:30 +0530 Subject: [PATCH] fix: dnd on pages section (#5202) --- frontend/src/_components/SortableList/SortableList.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/_components/SortableList/SortableList.jsx b/frontend/src/_components/SortableList/SortableList.jsx index 63f44ce21a..a7c85cff1d 100644 --- a/frontend/src/_components/SortableList/SortableList.jsx +++ b/frontend/src/_components/SortableList/SortableList.jsx @@ -8,7 +8,7 @@ import { SortableItem, SortableOverlay } from './components'; export function SortableList({ items, onChange, renderItem }) { const [active, setActive] = useState(null); - const activeItem = useMemo(() => items.find((item) => item.id === active?.id), [active, items]); + // const activeItem = useMemo(() => items.find((item) => item.id === active?.id), [active, items]); const sensors = useSensors( useSensor(PointerSensor), useSensor(KeyboardSensor, { @@ -40,7 +40,7 @@ export function SortableList({ items, onChange, renderItem }) { {renderItem(item)} ))} - {activeItem ? renderItem(activeItem) : null} + {/* {activeItem ? renderItem(activeItem) : null} */} ); }