fix column drag not reordering
the drop target arrives as the column's inner droppable id, so the lookup missed and nothing moved
This commit is contained in:
@@ -281,7 +281,9 @@ export function BoardView() {
|
|||||||
|
|
||||||
if (type === "column") {
|
if (type === "column") {
|
||||||
const activeColumnId = active.id as string;
|
const activeColumnId = active.id as string;
|
||||||
const overColumnId = over.id as string;
|
// the card list inside a column is a droppable of its own, so over.id can be a prefixed id
|
||||||
|
const overColumnId =
|
||||||
|
(over.data.current?.columnId as string | undefined) ?? String(over.id);
|
||||||
|
|
||||||
if (activeColumnId !== overColumnId) {
|
if (activeColumnId !== overColumnId) {
|
||||||
const fromIndex = currentBoard.columns.findIndex(
|
const fromIndex = currentBoard.columns.findIndex(
|
||||||
|
|||||||
Reference in New Issue
Block a user