diff --git a/src/components/CalendarGrid.vue b/src/components/CalendarGrid.vue index 573f68bc01..c151c27dd4 100644 --- a/src/components/CalendarGrid.vue +++ b/src/components/CalendarGrid.vue @@ -170,7 +170,7 @@ export default { droppable: true, eventReceive: this.handleEventReceive, eventShortHeight: 38, - loading: this.scrollMonthViewToToday, + loading: this.scrollViewToToday, } }, @@ -321,17 +321,17 @@ export default { methods: { /** - * Scroll the month view to today when loading the calendar, + * Scroll the month or list view to today when loading the calendar, * so people can directly see today's date and events. * * @param {boolean} isLoading Whether the calendar is still loading */ - scrollMonthViewToToday(isLoading) { + scrollViewToToday(isLoading) { if (isLoading) { return } const calendarApi = this.$refs.fullCalendar.getApi() - if (calendarApi.view.type !== 'dayGridMonth') { + if (calendarApi.view.type !== 'dayGridMonth' && calendarApi.view.type !== 'listMonth') { return } this.$nextTick(() => { diff --git a/src/styles/fullcalendar.scss b/src/styles/fullcalendar.scss index a6e71f89c6..ec97c97c7b 100644 --- a/src/styles/fullcalendar.scss +++ b/src/styles/fullcalendar.scss @@ -60,7 +60,8 @@ // Today highlighting .fc-day-today { - &.fc-col-header-cell { + &.fc-col-header-cell, + &.fc-list-day { a, span { padding: 2px 6px; font-weight: bold;