Skip to content

Commit

Permalink
Fix #6737 Calendar month navigator (#6739)
Browse files Browse the repository at this point in the history
* fix: use new Date instead of cloned date

* fix: reset the day of the cloned date
  • Loading branch information
KirilCycle authored Jun 7, 2024
1 parent 93163ad commit e978ce1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions components/lib/calendar/Calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,7 @@ export const Calendar = React.memo(
const currentViewDate = getViewDate();
let newViewDate = cloneDate(currentViewDate);

newViewDate.setDate(1);
newViewDate.setMonth(parseInt(value, 10));

updateViewDate(event, newViewDate);
Expand Down

0 comments on commit e978ce1

Please sign in to comment.