We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e188815 commit 2f7c8dcCopy full SHA for 2f7c8dc
web/src/components/StatisticsView/MonthNavigator.tsx
@@ -1,3 +1,4 @@
1
+import dayjs from "dayjs";
2
import { ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon } from "lucide-react";
3
import { useState } from "react";
4
import { YearCalendar } from "@/components/ActivityCalendar";
@@ -8,7 +9,7 @@ import type { MonthNavigatorProps } from "@/types/statistics";
8
9
10
export const MonthNavigator = ({ visibleMonth, onMonthChange, activityStats }: MonthNavigatorProps) => {
11
const [isOpen, setIsOpen] = useState(false);
- const currentMonth = new Date(visibleMonth);
12
+ const currentMonth = dayjs(visibleMonth).toDate();
13
const currentYear = getYearFromDate(visibleMonth);
14
const currentMonthNum = getMonthFromDate(visibleMonth);
15
0 commit comments