From e2de5d84f012714ff113cf8fc236905b2c1a3554 Mon Sep 17 00:00:00 2001 From: Jaied Al Sabid <87969327+jaieds@users.noreply.github.com> Date: Mon, 30 Dec 2024 13:02:18 +0600 Subject: [PATCH] fix: DatePicker crashing after selecting year --- src/components/datepicker/datepicker-component.tsx | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/components/datepicker/datepicker-component.tsx b/src/components/datepicker/datepicker-component.tsx index 4c45f865..340260f4 100644 --- a/src/components/datepicker/datepicker-component.tsx +++ b/src/components/datepicker/datepicker-component.tsx @@ -175,7 +175,7 @@ const DatePickerComponent = ( { } }; - const handleYearClick = ( { yearValue }: { yearValue: number } ) => { + const handleYearClick = ( yearValue: number ) => { setSelectedYear( yearValue ); setShowYearSelect( false ); setShowMonthSelect( true ); @@ -245,13 +245,7 @@ const DatePickerComponent = ( {