Skip to content

Commit

Permalink
refactor: removed layout prop from currentBoard children
Browse files Browse the repository at this point in the history
  • Loading branch information
Keith-Web3 committed Jul 25, 2023
1 parent b18db08 commit 6ec575b
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/components/shared/Body.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,22 +34,21 @@ const Body = function ({
{currentBoard?.status &&
!currentBoard.status.every(el => el.tasks.length === 0) && (
<DragDropContext onDragEnd={handleDragEnd}>
<motion.div className="body__boards">
<div className="body__boards">
{currentBoard.status
.filter(el => el.tasks.length)
.map(el => (
<Board key={nanoid()} {...el} />
))}
<motion.div
layout
<div
onClick={() =>
setModalType({ modalType: 'new-column', showModal: true })
}
className="body__add-board"
>
<motion.p layout>+ new column</motion.p>
</motion.div>
</motion.div>
<p>+ new column</p>
</div>
</div>
</DragDropContext>
)}
<div className="empty">
Expand Down

0 comments on commit 6ec575b

Please sign in to comment.