diff --git a/assets/src/components/notificationCard.tsx b/assets/src/components/notificationCard.tsx index ce4022f8a..a01a2a683 100644 --- a/assets/src/components/notificationCard.tsx +++ b/assets/src/components/notificationCard.tsx @@ -6,6 +6,7 @@ import { BlockWaiverReason, NotificationType, isBlockWaiverNotification, + DetourNotificationStatus, } from "../realtime" import { Route } from "../schedule" import { formattedTime } from "../util/dateTime" @@ -99,7 +100,17 @@ export const title = (notification: Notification) => { } case NotificationType.Detour: { - return "Detour - Active" + switch (notification.content.status) { + case DetourNotificationStatus.Activated: { + return "Detour - Active" + } + case DetourNotificationStatus.Deactivated: { + return "Detour - Closed" + } + } + // Typescript says this is unreachable, + // but eslint doesn't seem to get the memo + break } case NotificationType.BridgeMovement: {