From 80508eb432acea4559cff7ed721cb2a370628d44 Mon Sep 17 00:00:00 2001 From: JeonDoGyun Date: Sun, 22 Oct 2023 00:02:56 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20prevMonth,=20nextMonth=20=ED=99=94?= =?UTF-8?q?=EB=A9=B4=20=EC=A0=84=ED=99=98=20=EC=97=90=EB=9F=AC=20=ED=95=B4?= =?UTF-8?q?=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 회색 글씨 눌렀을 때 연도가 다르면 예상했던 결과가 나오지 않는 문제 해결 --- src/commons/MonthDays.tsx | 6 +- src/pages/register/Calendar.tsx | 120 +++++++++++++++++++++----------- 2 files changed, 82 insertions(+), 44 deletions(-) diff --git a/src/commons/MonthDays.tsx b/src/commons/MonthDays.tsx index d7da5b0e..28ea7ce8 100644 --- a/src/commons/MonthDays.tsx +++ b/src/commons/MonthDays.tsx @@ -29,16 +29,16 @@ export const CurrentMonthDays = ({ handleClick, }: CurrentDaysProps) => { return ( - +
- {months[currentMonth]} {currentYear} + {months[currentDate.getMonth()]} {currentDate.getFullYear()}