feat(calendar): update week start day and scroll time

- Change firstDay from 0 (Sunday) to 1 (Monday) to start week on Monday
- Update scrollTime from current time to 12:00 PM for better user experience
- Remove dynamic scroll calculation in favor of fixed noon position
This commit is contained in:
lenhanphung
2025-09-24 11:27:47 +07:00
parent 98b1f59a8b
commit 3815a13ef9
+2 -4
View File
@@ -320,7 +320,7 @@ export default function CalendarApp() {
}} }}
plugins={[dayGridPlugin, timeGridPlugin, interactionPlugin]} plugins={[dayGridPlugin, timeGridPlugin, interactionPlugin]}
initialView="timeGridWeek" initialView="timeGridWeek"
firstDay={0} firstDay={1}
editable={true} editable={true}
selectable={true} selectable={true}
timeZone="local" timeZone="local"
@@ -363,9 +363,7 @@ export default function CalendarApp() {
weekNumberFormat={{ week: "long" }} weekNumberFormat={{ week: "long" }}
slotDuration={"01:00:00"} slotDuration={"01:00:00"}
slotLabelInterval={"01:00:00"} slotLabelInterval={"01:00:00"}
scrollTime={new Date(Date.now() - 2 * 60 * 60 * 1000) scrollTime="12:00:00"
.toTimeString()
.slice(0, 5)}
unselectAuto={false} unselectAuto={false}
allDayText="" allDayText=""
slotLabelFormat={{ slotLabelFormat={{