Skip to content

Commit

Permalink
style: change function declare order
Browse files Browse the repository at this point in the history
  • Loading branch information
KumJungMin committed Dec 14, 2024
1 parent 4d667e3 commit 1888d9d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions components/lib/calendar/Calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -507,10 +507,6 @@ export const Calendar = React.memo(
return _currentYear;
};

const getViewYear = () => {
return props.yearNavigator ? getViewDate().getFullYear() : currentYear;
};

const onMonthDropdownChange = (event, value) => {
const currentViewDate = getViewDate();
let newViewDate = cloneDate(currentViewDate);
Expand Down Expand Up @@ -1815,6 +1811,10 @@ export const Calendar = React.memo(
}
};

const getViewYear = () => {
return props.yearNavigator ? getViewDate().getFullYear() : currentYear;
};

const onYearSelect = (event, year) => {
if (props.view === 'year') {
onDateSelect(event, { year: year, month: 0, day: 1, selectable: true });
Expand Down

0 comments on commit 1888d9d

Please sign in to comment.