navigationStyle injects a custom headerLeft back chevron whenever closeButton === CloseButtonPosition.None, which silently overrides screens that opt out of back navigation via headerBackVisible: false.
headerBackVisible only governs the native back button — it cannot suppress a custom headerLeft — so any screen passing headerBackVisible: false through navigationStyle still gets a chevron.
Affected screens
navigation/WalletExportStack.tsx:24 — WalletExport
options={navigationStyle({
headerBackVisible: false,
title: loc.wallets.export_title,
})(theme)}
Before #137 this screen was first-route-in-stack, so the old !headerLeft && !isFirstRouteInStack gate skipped it and headerBackVisible: false did its job — no back button, deliberately. #137's gate (closeButton === CloseButtonPosition.None) now fires for it, so a chevron appears. On a seed-phrase export screen that's worth an explicit decision rather than a side effect.
navigation/AddWalletStack.tsx:53-60 — PleaseBackup
options={navigationStyle({
gestureEnabled: false,
headerBackVisible: false,
title: loc.pleasebackup.null,
})(theme)}
gestureEnabled: false + headerBackVisible: false reads as a clear intent to keep the user on the screen until they've backed up. This one is pre-existing — it isn't first-route-in-stack, so the old gate already injected a chevron and already defeated the opt-out. #137 only changed its color. So the seed-backup step has been skippable via the header chevron for a while.
Not affected: DetailViewScreensStack.tsx:66 and OnboardingStack.tsx:19 both pair headerBackVisible: false with headerShown: false, so there's no header to put a button in.
Suggested fix
Honor the opt-out in the gate:
if (closeButton === CloseButtonPosition.None && opts.headerBackVisible !== false) {
headerLeft = (props: any) => (props.canGoBack ? <HeaderBackButton … /> : null);
}
opts is already in scope (it's read for presentation a few lines above) and headerBackVisible is a valid NativeStackNavigationOptions field, so this typechecks as-is. It restores WalletExport to its intended headerless state and closes the PleaseBackup gap in the same line.
Decisions needed
- Should
WalletExport have a back chevron? If yes, drop headerBackVisible: false from its options so the intent matches the behavior — right now the code says one thing and the UI does another either way.
- Should
PleaseBackup actually be non-dismissable? If so, the fix above is required; if users are meant to be able to skip it, remove gestureEnabled: false / headerBackVisible: false so the intent is legible.
Context
Found while reviewing #137 (merged after #131). Not a blocker for #137 — the behavior change there is limited to WalletExport — but it should be settled rather than inherited silently.
navigationStyleinjects a customheaderLeftback chevron whenevercloseButton === CloseButtonPosition.None, which silently overrides screens that opt out of back navigation viaheaderBackVisible: false.headerBackVisibleonly governs the native back button — it cannot suppress a customheaderLeft— so any screen passingheaderBackVisible: falsethroughnavigationStylestill gets a chevron.Affected screens
navigation/WalletExportStack.tsx:24—WalletExportBefore #137 this screen was first-route-in-stack, so the old
!headerLeft && !isFirstRouteInStackgate skipped it andheaderBackVisible: falsedid its job — no back button, deliberately. #137's gate (closeButton === CloseButtonPosition.None) now fires for it, so a chevron appears. On a seed-phrase export screen that's worth an explicit decision rather than a side effect.navigation/AddWalletStack.tsx:53-60—PleaseBackupgestureEnabled: false+headerBackVisible: falsereads as a clear intent to keep the user on the screen until they've backed up. This one is pre-existing — it isn't first-route-in-stack, so the old gate already injected a chevron and already defeated the opt-out. #137 only changed its color. So the seed-backup step has been skippable via the header chevron for a while.Not affected:
DetailViewScreensStack.tsx:66andOnboardingStack.tsx:19both pairheaderBackVisible: falsewithheaderShown: false, so there's no header to put a button in.Suggested fix
Honor the opt-out in the gate:
optsis already in scope (it's read forpresentationa few lines above) andheaderBackVisibleis a validNativeStackNavigationOptionsfield, so this typechecks as-is. It restoresWalletExportto its intended headerless state and closes thePleaseBackupgap in the same line.Decisions needed
WalletExporthave a back chevron? If yes, dropheaderBackVisible: falsefrom its options so the intent matches the behavior — right now the code says one thing and the UI does another either way.PleaseBackupactually be non-dismissable? If so, the fix above is required; if users are meant to be able to skip it, removegestureEnabled: false/headerBackVisible: falseso the intent is legible.Context
Found while reviewing #137 (merged after #131). Not a blocker for #137 — the behavior change there is limited to
WalletExport— but it should be settled rather than inherited silently.