mirror of
https://github.com/usememos/memos.git
synced 2025-10-10 06:16:35 +08:00
chore: fix linter
This commit is contained in:
parent
f695e93f20
commit
76a9a343a5
1 changed files with 1 additions and 1 deletions
|
@ -39,7 +39,7 @@ const ActivityCalendar = (props: Props) => {
|
|||
const year = dayjs(monthStr).toDate().getFullYear();
|
||||
const month = dayjs(monthStr).toDate().getMonth() + 1;
|
||||
const dayInMonth = new Date(year, month, 0).getDate();
|
||||
const firstDay = ((new Date(year, month - 1, 1).getDay() - weekStartDayOffset) % 7 + 7) % 7;
|
||||
const firstDay = (((new Date(year, month - 1, 1).getDay() - weekStartDayOffset) % 7) + 7) % 7;
|
||||
const lastDay = new Date(year, month - 1, dayInMonth).getDay() - weekStartDayOffset;
|
||||
const WEEK_DAYS = [t("days.sun"), t("days.mon"), t("days.tue"), t("days.wed"), t("days.thu"), t("days.fri"), t("days.sat")];
|
||||
const weekDays = WEEK_DAYS.slice(weekStartDayOffset).concat(WEEK_DAYS.slice(0, weekStartDayOffset));
|
||||
|
|
Loading…
Add table
Reference in a new issue