diff --git a/frontend/src/pages/TaskListPage.tsx b/frontend/src/pages/TaskListPage.tsx index cc97ec7..d19582f 100644 --- a/frontend/src/pages/TaskListPage.tsx +++ b/frontend/src/pages/TaskListPage.tsx @@ -36,6 +36,9 @@ import { import { Task, ToBuy, Stuff } from '../types/types'; import { TASK_ERRORS } from '../constants/errorMessages'; //import { FaCarrot } from "react-icons/fa6"; //エラー起きる いったん保留 +import { useNavigate, Outlet, useLocation } from 'react-router-dom'; +import CategoryDropDown from "../components/CategoryDropDown"; + @@ -50,6 +53,7 @@ const EMPTY_TASK: Omit & { stuff_id: number | nu } const TaskListPage: React.FC = () => { + const navigate = useNavigate(); // タスク一覧の状態管理 const [tobuys, setToBuys] = useState([]); // 新規タスク作成ダイアログの表示状態 @@ -231,7 +235,8 @@ const TaskListPage: React.FC = () => { setOpenDialog(true)} + // onClick={() => setOpenDialog(true)} + onClick={() => navigate('/add1')} >