diff --git a/frontend/src/composables/useMeetingAlerts.js b/frontend/src/composables/useMeetingAlerts.js index ea9647e..ae79a17 100644 --- a/frontend/src/composables/useMeetingAlerts.js +++ b/frontend/src/composables/useMeetingAlerts.js @@ -104,17 +104,21 @@ export function useMeetingAlerts(onMeetingStart = null) { } } - // At start time: full-screen TV alert, clear dashboard toasts - if (secs <= 0 && secs >= -15 && !triggered.has(keyStart)) { + // At start time: full-screen TV alert, clear dashboard toasts. + // Use a 5-minute catch-up window so opening the dashboard late still triggers. + if (secs <= 0 && secs >= -300 && !triggered.has(keyStart)) { triggered.add(keyStart) dashboardAlerts.value = dashboardAlerts.value.filter(a => a.blockId !== block.id) - playChime(false) - if (onMeetingStart) onMeetingStart(block.id) - tvAlert.value = { - blockId: block.id, - label: blockLabel(block), - autoDismissAt: new Date(Date.now() + 30000), + // Only play chime and show TV overlay when meeting just started (within 30s) + if (secs >= -30) { + playChime(false) + tvAlert.value = { + blockId: block.id, + label: blockLabel(block), + autoDismissAt: new Date(Date.now() + 30000), + } } + if (onMeetingStart) onMeetingStart(block.id) } }) }, 1000) diff --git a/frontend/src/views/DashboardView.vue b/frontend/src/views/DashboardView.vue index 6045622..7e5d28f 100644 --- a/frontend/src/views/DashboardView.vue +++ b/frontend/src/views/DashboardView.vue @@ -283,6 +283,7 @@ const scheduleStore = useScheduleStore() const activeChild = computed(() => childrenStore.activeChild) const meetingAlerts = useMeetingAlerts((blockId) => { if (!scheduleStore.session) return + if (scheduleStore.session.current_block_id === blockId) return scheduleStore.switchBlock(scheduleStore.session.id, blockId) })