refactor: separation of shared components
This commit is contained in:
@ -1,3 +0,0 @@
|
||||
import SortableDnd from "@/components/SortableDnd/SortableDnd";
|
||||
|
||||
export default SortableDnd;
|
||||
@ -1,5 +1,5 @@
|
||||
import React, { CSSProperties, ReactNode, useContext } from "react";
|
||||
import SortableItemContext from "@/components/SortableDnd/SortableItemContext";
|
||||
import SortableItemContext from "@/components/dnd/SortableDnd/SortableItemContext";
|
||||
|
||||
type Props = {
|
||||
children: ReactNode;
|
||||
@ -12,8 +12,8 @@ import { SortableContext } from "@dnd-kit/sortable";
|
||||
import { LexoRank } from "lexorank";
|
||||
import { Box, Group } from "@mantine/core";
|
||||
import useDndSensors from "@/app/deals/hooks/useSensors";
|
||||
import { SortableItem } from "@/components/SortableDnd/SortableItem";
|
||||
import { SortableOverlay } from "@/components/SortableDnd/SortableOverlay";
|
||||
import { SortableItem } from "@/components/dnd/SortableDnd/SortableItem";
|
||||
import { SortableOverlay } from "@/components/dnd/SortableDnd/SortableOverlay";
|
||||
import { getNewLexorank, sortByLexorank } from "@/utils/lexorank";
|
||||
|
||||
type BaseItem = {
|
||||
@ -1,7 +1,7 @@
|
||||
import React, { CSSProperties, PropsWithChildren, useMemo } from "react";
|
||||
import { useSortable } from "@dnd-kit/sortable";
|
||||
import { CSS } from "@dnd-kit/utilities";
|
||||
import DragHandle from "@/components/SortableDnd/DragHandle";
|
||||
import DragHandle from "@/components/dnd/SortableDnd/DragHandle";
|
||||
import SortableItemContext from "./SortableItemContext";
|
||||
|
||||
type Props = {
|
||||
3
src/components/dnd/SortableDnd/index.ts
Normal file
3
src/components/dnd/SortableDnd/index.ts
Normal file
@ -0,0 +1,3 @@
|
||||
import SortableDnd from "@/components/dnd/SortableDnd/SortableDnd";
|
||||
|
||||
export default SortableDnd;
|
||||
Reference in New Issue
Block a user