Repository navigation
feat(app): 알림 탭을 Nav3 앱 셸에서 목적지 탭으로 잇는다 (#1795) - #2309
Merged
Merged
Conversation
…m/Afternote/Afternote-FE into feat/1795-notification-entry-nav3
Sadturtleman
approved these changes
Oct 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
핵심 파일
NotificationEntryEffect.kt: 인증 확인, 목적지 탭 변환, 이동 후 큐 소비AppNavigation.kt: Nav3 앱 셸의 알림 소비와 재진입 시 탭 NavHost 수명 정합NotificationNavigationAndroidTest.kt: 로그아웃 관문, 로그인 후 이동, 중복 전달, 백그라운드 진입NotificationColdStartAndroidTest.kt: 종료 상태의 최초 인텐트 수신과 로그인 상태의 목적지 도달변경 내용
알림을 눌러 들어온 목적지를 Nav3 앱 셸이 읽어 바텀바의 해당 탭으로 이동합니다. 로그아웃 중에는 큐를 유지하고, 로그인과 바텀바 스택 진입이 확인된 뒤 이동합니다. 이동 후 발생 식별자를 소비해 같은 알림을 다시 처리하지 않습니다. 목적지 변환은 같은 파일에서만 사용하는 private 함수입니다.
탭 NavHost가 내려간 뒤에도 이전 컨트롤러를 재사용하면 ViewModelStore가 달라져 재진입 시 크래시가 발생했습니다. 기존 Nav2 탭 컨트롤러를 Nav3 엔트리와 같은 수명으로 다시 만들어 이 경로를 처리합니다. 이동은 기존 바텀바 클릭의 백스택 계약을 사용합니다.
FCM 서버 payload의 키와 발송 방식은 BE#261이 확정할 범위입니다. 이번 변경은 앱 내부 목적지 계약을 소비하며 서버 키를 추가하지 않습니다. #1111의 cold 목적지 단언은 추가하지만 서버 계약과 실기기 FCM 도달 검증은 남아 있습니다.
검증
:app:compileDebugKotlin,:app:compileDebugAndroidTestKotlin,:app:ktlintCheck통과97a0bf9a2의 CI API 34 산출물에서 알림 계측 4건 통과 확인CI Test Plan
{ "androidTest": { "mode": "selected", "reason": "Activity의 cold·warm·background 알림 진입과 인증 관문, 목적지 탭 이동, 단회 소비를 API 34에서 검증한다.", "tests": [ { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationNavigationAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationNavigationAndroidTest#warmNotificationWhileLoggedOut_isReceivedWithoutBypassingOnboarding", "device": "api34" }, { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationNavigationAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationNavigationAndroidTest#warmNotificationWhileLoggedIn_isReceivedWithoutRecreatingActivity", "device": "api34" }, { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationNavigationAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationNavigationAndroidTest#backgroundNotification_resumesSameActivityAndNavigatesToDestination", "device": "api34" }, { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationNavigationAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationNavigationAndroidTest#sameRequestCode_differentSourceAndOccurrenceKeepLatestExtras", "device": "api34" }, { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationColdStartAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationColdStartAndroidTest#coldPendingIntentLaunch_enqueuesInitialNotificationEntry", "device": "api34" }, { "path": "app/src/androidTest/java/com/afternote/afternote_fe/NotificationColdStartAndroidTest.kt", "selector": "com.afternote.afternote_fe.NotificationColdStartAndroidTest#coldPendingIntentLaunchWhileLoggedIn_opensDestination", "device": "api34" } ] } }Closes #1795
Refs #1111