diff --git a/client/src/box.js b/client/src/box.js index b9e91ba..24897aa 100644 --- a/client/src/box.js +++ b/client/src/box.js @@ -13,7 +13,14 @@ const Box = ({ boxData, boxHandler, itemHandler }) => { if (menu.current.contains(event.target)) return; setShowMenu(false); } - + const handleClickRemove = () => { + boxHandler.handleRemove(boxData._id); + setShowMenu(false); + } + const handleClickEdit = () => { + boxHandler.handleEdit(boxData._id); + setShowMenu(false); + } const [showMenu, setShowMenu] = useState(false); const handleBoxMenuClick = () => { setShowMenu(true); @@ -21,11 +28,11 @@ const Box = ({ boxData, boxHandler, itemHandler }) => { const moreMenu = () => { return (