feat(calendar_view): set first day of the week based on option

This commit is contained in:
Elian Doran 2025-02-15 20:18:27 +02:00
parent 0bcabacd3a
commit 9d9b45cafb
No known key found for this signature in database

View File

@ -4,8 +4,8 @@ import ViewMode, { type ViewModeArgs } from "./view_mode.js";
import type FNote from "../../entities/fnote.js"; import type FNote from "../../entities/fnote.js";
import server from "../../services/server.js"; import server from "../../services/server.js";
import ws from "../../services/ws.js"; import ws from "../../services/ws.js";
import type { EventDragStopArg, EventResizeDoneArg } from "@fullcalendar/interaction";
import { t } from "../../services/i18n.js"; import { t } from "../../services/i18n.js";
import options from "../../services/options.js";
const TPL = ` const TPL = `
<div class="calendar-view"> <div class="calendar-view">
@ -83,7 +83,8 @@ export default class CalendarView extends ViewMode {
week: t("calendar_view.week"), week: t("calendar_view.week"),
day: t("calendar_view.day"), day: t("calendar_view.day"),
list: t("calendar_view.list") list: t("calendar_view.list")
} },
firstDay: options.getInt("firstDayOfWeek") ?? 0
}); });
calendar.render(); calendar.render();