From 3ed946521bda7754d0e529a90946def420843033 Mon Sep 17 00:00:00 2001 From: Eunseo Sim <55528304+simeunseo@users.noreply.github.com> Date: Sun, 30 Jun 2024 14:58:28 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20clickedUserNames=20->=20timeSlotUserName?= =?UTF-8?q?s=EB=A1=9C=20=EB=84=A4=EC=9D=B4=EB=B0=8D=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/OverallSchedule/contexts/useClickContext.ts | 8 ++++---- src/pages/OverallSchedule/hooks/useSlotClick.ts | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/pages/OverallSchedule/contexts/useClickContext.ts b/src/pages/OverallSchedule/contexts/useClickContext.ts index 4723cb90..6bf04750 100644 --- a/src/pages/OverallSchedule/contexts/useClickContext.ts +++ b/src/pages/OverallSchedule/contexts/useClickContext.ts @@ -3,15 +3,15 @@ import { Dispatch, SetStateAction, createContext, useContext } from 'react'; interface ClickContextType { clickedSlot: string | undefined; setClickedSlot: Dispatch>; - clickedUserNames: string[]; - setClickedUserNames: Dispatch>; + timeSlotUserNames: string[]; + setTimeSlotUserNames: Dispatch>; } export const ClickContext = createContext({ clickedSlot: undefined, setClickedSlot: () => undefined, - clickedUserNames: [], - setClickedUserNames: () => [], + timeSlotUserNames: [], + setTimeSlotUserNames: () => [], }); export function useClickContext() { diff --git a/src/pages/OverallSchedule/hooks/useSlotClick.ts b/src/pages/OverallSchedule/hooks/useSlotClick.ts index f49c5cd7..53e1e212 100644 --- a/src/pages/OverallSchedule/hooks/useSlotClick.ts +++ b/src/pages/OverallSchedule/hooks/useSlotClick.ts @@ -1,11 +1,11 @@ import { useClickContext } from '../contexts/useClickContext'; export const useSlotClick = () => { - const { clickedSlot, setClickedSlot, setClickedUserNames } = useClickContext(); + const { clickedSlot, setClickedSlot, setTimeSlotUserNames } = useClickContext(); const onClickSlot = (targetSlot: string, targetUserNames: string[]) => { setClickedSlot(targetSlot); - setClickedUserNames(targetUserNames); + setTimeSlotUserNames(targetUserNames); }; return { clickedSlot, onClickSlot };