You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Navigation preset: header height ignores platform changes, providers and the safe-area inset #889
The navigation preset's header-height values differ from React Navigation 7 in three ways that #865 left as they were:
HeaderHeightContext's default is computed once when the elements factory runs, so setPlatform("android") after import leaves the context at 44 while useHeaderHeight() returns 56. useHeaderHeight also ignores a HeaderHeightContext.Provider, which React Navigation 7 reads.
The default header height uses a top inset of 0. React Navigation's NativeStackView adds insets.top, and the mock engine's safe-area fallback reports 47, so a test sees 44 where the app shows 91.
useAnimatedHeaderHeight returns a bare Animated.Value. React Navigation 7 returns an Animated.add(...) result read from AnimatedHeaderHeightContext, and throws outside a screen.
Acceptance criteria
HeaderHeightContext's default follows the active platform at read time, and useHeaderHeight reads a provided HeaderHeightContext value; a test covers each.
The default header height includes the safe-area top inset the preset reports, or the docs state why it does not; a test pins the chosen value.
useAnimatedHeaderHeight reads AnimatedHeaderHeightContext when provided; a test covers it.
Activity