feat: FEAT-212 Profile navigation migration: state machine β React Navigation#128
Merged
Merged
Conversation
Replace ProfileScreen's hand-rolled currentScreen state machine β and the depth-2 showCloudBackup / selectedDocument sub-machines inside PrivacyDataScreen / LegalDocumentsListScreen β with a nested React Navigation stack (ProfileStackNavigator). Each former subscreen is now a real route with native back-chevron headers (resolves audit finding M3) and iOS swipe-back. Crisis overlay re-host (FEAT-203 Β§5.1 CB-1..CB-7, AS-6 β crisis-agent sign-off: GO): CollapsibleCrisisButton moves from inside ProfileScreen to the navigator wrapper as a sibling above the stack, so it covers every Profile route including depth-2. Frozen props preserved (mode="standard", testID="crisis-profile", position="right"); onNavigate uses the root navigation since CrisisResources is a root-stack modal. - New ProfileStackNavigator + AboutBeingScreen (gated placeholder route, preserves FEAT-209 H2 "About Being." gating) - Subscreens drop SubMenuHeader/onReturn -> native header + goBack - Privacy->CloudBackup and Legal->LegalDocument become pushed routes; LegalDocument takes a serializable documentType param - Profile tab repoints to ProfileStackNavigator (headerShown:false) - Extend crisis-button-reachability.yaml: assert crisis-profile -> crisis-resources-screen from menu + 5 depth-1 routes + depth-2 LegalDocument (CloudBackup depth-2 is cloud_sync-dark, pinned by jest) - New jest test pins frozen crisis props + root-nav onNavigate wiring - Update affected tests for the route model π€ Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
β¦profile-nav-migration # Conflicts: # app/src/features/profile/screens/AccountSettingsScreen.tsx
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.
Closes FEAT-212 (FEAT-203 Slice 4).
Replaces ProfileScreen's hand-rolled
currentScreenstate machine β and the depth-2showCloudBackup/selectedDocumentsub-machines β with a nested React Navigation stack (ProfileStackNavigator). Native back-chevron headers replace SubMenuHeader's β (resolves audit finding M3); iOS swipe-back works.Crisis overlay re-host (FEAT-203 Β§5.1 CB-1..CB-7, AS-6):
CollapsibleCrisisButtonmoved from inside ProfileScreen to the navigator wrapper (sibling above the stack) so it covers every Profile route including depth-2. Frozen props preserved (mode="standard",testID="crisis-profile",position="right");onNavigateuses root navigation (CrisisResources is a root modal).Crisis sign-off:
crisisagent GO (planning pass + implementation review).On-device validation: extended
crisis-button-reachability.yamlrun on iPhone 16 Plus against this build βcrisis-profile β crisis-resources-screenasserted from menu + 5 depth-1 routes + depth-2 LegalDocument, all COMPLETED (exit 0).Jest: new
profile-stack-navigator.test.tsxpins frozen crisis props + root-nav wiring; full precommit green (typecheck, accessibility 64, crisis-detection 82, unit 377).π€ Generated with Claude Code