From 0f91e78b440aadcd5a4d3c7d916e1533c7edc871 Mon Sep 17 00:00:00 2001 From: nakyong82 Date: Sat, 21 Dec 2024 22:00:39 +0900 Subject: [PATCH] =?UTF-8?q?:bug:=20fix:=20BottomSheet=20=EB=8B=AB=ED=98=94?= =?UTF-8?q?=EC=9D=84=20=EB=95=8C=20=EC=9B=90=EC=83=81=ED=83=9C=EB=A1=9C=20?= =?UTF-8?q?=EB=8F=8C=EC=95=84=EC=98=A4=EB=8F=84=EB=A1=9D=20=EC=88=98?= =?UTF-8?q?=EC=A0=95=ED=95=98=EA=B8=B0=20#135?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ApplicationDetail/ApplicationDetailBottomSheet.tsx | 2 +- src/components/Common/BottomSheetLayout.tsx | 2 +- src/components/Common/WorkDayTimeBottomSheet.tsx | 5 ++++- src/components/Common/WorkDayTimeWithRestBottomSheet.tsx | 7 +++++-- src/components/Employer/PostCreate/Step1.tsx | 6 ++---- .../Employer/WriteDocument/EmployerLaborContractForm.tsx | 3 ++- src/components/Profile/LogoutBottomSheet.tsx | 7 ++++++- src/hooks/useBottomSheet.ts | 2 +- src/pages/Employer/Profile/EmployerProfilePage.tsx | 2 ++ src/pages/Profile/ProfilePage.tsx | 2 ++ 10 files changed, 26 insertions(+), 12 deletions(-) diff --git a/src/components/ApplicationDetail/ApplicationDetailBottomSheet.tsx b/src/components/ApplicationDetail/ApplicationDetailBottomSheet.tsx index a48d0714..25411b32 100644 --- a/src/components/ApplicationDetail/ApplicationDetailBottomSheet.tsx +++ b/src/components/ApplicationDetail/ApplicationDetailBottomSheet.tsx @@ -5,7 +5,7 @@ import { buttonTypeKeys } from '@/constants/components'; type ApplicationDetailBottomSheetType = { isShowBottomsheet: boolean; - setIsShowBottomSheet: React.Dispatch>; + setIsShowBottomSheet: (isShowBottomsheet: boolean) => void; blackButtonTitle: string; onClickBlackButton: () => void; yellowButtonTitle: string; diff --git a/src/components/Common/BottomSheetLayout.tsx b/src/components/Common/BottomSheetLayout.tsx index db208833..735236eb 100644 --- a/src/components/Common/BottomSheetLayout.tsx +++ b/src/components/Common/BottomSheetLayout.tsx @@ -6,7 +6,7 @@ type BottomSheetLayoutProps = { hasHandlebar: boolean; // 최상단의 바 모양 존재 여부 isAvailableHidden: boolean; // 아래로 내렸을 때 사라지도록 하는 여부 isShowBottomsheet: boolean; // BottomSheet 보이기 - setIsShowBottomSheet?: React.Dispatch>; // isShowBottomsheet 값 동기화하기 위한 함수 + setIsShowBottomSheet?: (isShowBottomsheet: boolean) => void; // isShowBottomsheet 값 동기화하기 위한 함수 children: ReactNode; isFixedBackground?: boolean; }; diff --git a/src/components/Common/WorkDayTimeBottomSheet.tsx b/src/components/Common/WorkDayTimeBottomSheet.tsx index e5e1d6a9..a24757c3 100644 --- a/src/components/Common/WorkDayTimeBottomSheet.tsx +++ b/src/components/Common/WorkDayTimeBottomSheet.tsx @@ -23,9 +23,11 @@ type DayType = (typeof DAYS)[keyof typeof DAYS]; const WorkDayTimeBottomSheet = ({ onClose, isShowBottomsheet, + setIsShowBottomSheet, }: { onClose: (value: WorkDayTime[]) => void; isShowBottomsheet: boolean; + setIsShowBottomSheet: (isShowBottomsheet: boolean) => void; }) => { const [isCheckAllWeek, setIsCheckAllWeek] = useState(false); const [isCheckAllTime, setIsCheckAllTime] = useState(false); @@ -86,6 +88,7 @@ const WorkDayTimeBottomSheet = ({ hasHandlebar={true} isAvailableHidden={true} isShowBottomsheet={isShowBottomsheet} + setIsShowBottomSheet={setIsShowBottomSheet} >
@@ -111,7 +114,7 @@ const WorkDayTimeBottomSheet = ({
{Object.keys(DAYS).map((value, index) => (