From 62b7acd96d00d23ec524c1daa329641d7e1e64f7 Mon Sep 17 00:00:00 2001 From: mkhutornyi Date: Tue, 12 Dec 2023 03:00:23 +0100 Subject: [PATCH] fix previous month display on calendar after coming back to form --- src/components/DatePicker/CalendarPicker/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/DatePicker/CalendarPicker/index.js b/src/components/DatePicker/CalendarPicker/index.js index a404c4746397..7a558bd92990 100644 --- a/src/components/DatePicker/CalendarPicker/index.js +++ b/src/components/DatePicker/CalendarPicker/index.js @@ -50,7 +50,7 @@ class CalendarPicker extends React.PureComponent { if (props.minDate >= props.maxDate) { throw new Error('Minimum date cannot be greater than the maximum date.'); } - let currentDateView = new Date(props.value); + let currentDateView = parseISO(props.value); if (props.maxDate < currentDateView) { currentDateView = props.maxDate; } else if (props.minDate > currentDateView) {