feat(date-memories): add date_logged and date_reflection_* notification channels to PartnerNotificationManager
This commit is contained in:
parent
a96be6ea07
commit
aa5ebcbcac
|
|
@ -248,6 +248,25 @@ enum class PartnerNotificationType(
|
||||||
channelId = NotificationChannelSetup.CHANNEL_PARTNER_ACTIONS,
|
channelId = NotificationChannelSetup.CHANNEL_PARTNER_ACTIONS,
|
||||||
rateType = NotificationRateLimiter.Type.PARTNER_TRIGGER
|
rateType = NotificationRateLimiter.Type.PARTNER_TRIGGER
|
||||||
),
|
),
|
||||||
|
// Date Memories & Replay: partner reflected (your turn) / both reflected (reveal) / a date was logged.
|
||||||
|
DATE_REFLECTION_PARTNER(
|
||||||
|
title = "Your partner reflected on your date 💭",
|
||||||
|
body = "Add yours to reveal together.",
|
||||||
|
channelId = NotificationChannelSetup.CHANNEL_PARTNER_ACTIONS,
|
||||||
|
rateType = NotificationRateLimiter.Type.PARTNER_TRIGGER
|
||||||
|
),
|
||||||
|
DATE_REFLECTION_READY(
|
||||||
|
title = "Your date reflections are ready ✨",
|
||||||
|
body = "Open to reveal them together.",
|
||||||
|
channelId = NotificationChannelSetup.CHANNEL_PARTNER_ACTIONS,
|
||||||
|
rateType = NotificationRateLimiter.Type.PARTNER_TRIGGER
|
||||||
|
),
|
||||||
|
DATE_LOGGED(
|
||||||
|
title = "You went on a date 💜",
|
||||||
|
body = "Reflect on it together while it's fresh.",
|
||||||
|
channelId = NotificationChannelSetup.CHANNEL_PARTNER_ACTIONS,
|
||||||
|
rateType = NotificationRateLimiter.Type.PARTNER_TRIGGER
|
||||||
|
),
|
||||||
DAILY_QUESTION_REMINDER(
|
DAILY_QUESTION_REMINDER(
|
||||||
title = "Tonight's question is waiting.",
|
title = "Tonight's question is waiting.",
|
||||||
body = "Answer together before it expires.",
|
body = "Answer together before it expires.",
|
||||||
|
|
@ -324,6 +343,8 @@ enum class PartnerNotificationType(
|
||||||
CAPSULE_UNLOCKED -> AppRoute.MEMORY_LANE
|
CAPSULE_UNLOCKED -> AppRoute.MEMORY_LANE
|
||||||
GENTLE_REMINDER -> AppRoute.DAILY_QUESTION
|
GENTLE_REMINDER -> AppRoute.DAILY_QUESTION
|
||||||
THINKING_OF_YOU -> AppRoute.HOME
|
THINKING_OF_YOU -> AppRoute.HOME
|
||||||
|
DATE_REFLECTION_PARTNER, DATE_REFLECTION_READY, DATE_LOGGED ->
|
||||||
|
payload.dateId?.let { AppRoute.dateReflection(it) } ?: AppRoute.DATE_MEMORIES
|
||||||
DAILY_QUESTION_REMINDER -> AppRoute.DAILY_QUESTION
|
DAILY_QUESTION_REMINDER -> AppRoute.DAILY_QUESTION
|
||||||
// Open the actual conversation so the partner can reply in place.
|
// Open the actual conversation so the partner can reply in place.
|
||||||
CHAT_MESSAGE -> if (payload.conversationId != null && coupleId.isNotBlank()) {
|
CHAT_MESSAGE -> if (payload.conversationId != null && coupleId.isNotBlank()) {
|
||||||
|
|
@ -356,6 +377,9 @@ enum class PartnerNotificationType(
|
||||||
"memory_capsule_unlocked" -> CAPSULE_UNLOCKED
|
"memory_capsule_unlocked" -> CAPSULE_UNLOCKED
|
||||||
"gentle_reminder" -> GENTLE_REMINDER
|
"gentle_reminder" -> GENTLE_REMINDER
|
||||||
"thinking_of_you" -> THINKING_OF_YOU
|
"thinking_of_you" -> THINKING_OF_YOU
|
||||||
|
"date_reflection_partner" -> DATE_REFLECTION_PARTNER
|
||||||
|
"date_reflection_ready" -> DATE_REFLECTION_READY
|
||||||
|
"date_logged" -> DATE_LOGGED
|
||||||
// Server emits both 'daily_question' (assignment) and 'daily_question_reminder' — both open Today.
|
// Server emits both 'daily_question' (assignment) and 'daily_question_reminder' — both open Today.
|
||||||
"daily_question", "daily_question_reminder" -> DAILY_QUESTION_REMINDER
|
"daily_question", "daily_question_reminder" -> DAILY_QUESTION_REMINDER
|
||||||
"chat_message" -> CHAT_MESSAGE
|
"chat_message" -> CHAT_MESSAGE
|
||||||
|
|
@ -386,6 +410,8 @@ data class PartnerNotificationPayload(
|
||||||
val gameType: String? = null,
|
val gameType: String? = null,
|
||||||
val capsuleId: String? = null,
|
val capsuleId: String? = null,
|
||||||
val challengeId: String? = null,
|
val challengeId: String? = null,
|
||||||
|
/** Completed-date id, used to deep link a date-reflection push into the reflection screen. */
|
||||||
|
val dateId: String? = null,
|
||||||
/** Sender's avatar URL, used as the notification large icon when present. */
|
/** Sender's avatar URL, used as the notification large icon when present. */
|
||||||
val avatarUrl: String? = null
|
val avatarUrl: String? = null
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue