feat: disable dnds for mobile

This commit is contained in:
2025-08-08 18:06:42 +04:00
parent d3febcdfb0
commit 5ecdd3d887
7 changed files with 26 additions and 5 deletions

View File

@ -8,6 +8,7 @@ type Props = {
id: number | string;
itemStyle?: CSSProperties;
dragHandleStyle?: CSSProperties;
disabled?: boolean;
};
const SortableItem = ({
@ -15,6 +16,7 @@ const SortableItem = ({
itemStyle,
id,
dragHandleStyle,
disabled,
}: PropsWithChildren<Props>) => {
const {
attributes,
@ -24,7 +26,7 @@ const SortableItem = ({
setActivatorNodeRef,
transform,
transition,
} = useSortable({ id });
} = useSortable({ id, disabled });
const context = useMemo(
() => ({