Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native Stack Navigator header sticks to bottom of screen when using headerBackground option #1911

Closed
NikolaB131 opened this issue Oct 3, 2023 · 6 comments
Assignees
Labels
Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snack or repo is provided

Comments

@NikolaB131
Copy link

Description

Version of @react-navigation/native-stack is 6.9.14
When adding headerBackground option to Stack.Navigator or Stack.Screen header sticks to bottom.
Bug is on IOS and Android, Web version does not have bug.
There is no bug when switching to older version (6.9.13).
Appears with or without expo

Steps to reproduce

  1. Add headerBackground option to Stack.Navigator or Stack.Screen with any JSX Element (even <></>)
  2. Header sticks to bottom of screen

Snack or a link to a repository

https://snack.expo.dev/@nikolab131/header-sticks-to-bottom-of-screen

Screens version

3.25.0

React Native version

0.72.5

Platforms

Android, iOS

JavaScript runtime

Hermes

Workflow

React Native (without Expo)

Architecture

Paper (Old Architecture)

Build type

Debug mode

Device

Real device

Device model

Samsung Galaxy A50 (Android 12)

Acknowledgements

Yes

@github-actions github-actions bot added Repro provided A reproduction with a snack or repo is provided Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS labels Oct 3, 2023
@tboba
Copy link
Member

tboba commented Oct 12, 2023

Hi @NikolaB131, thanks for reporting this issue! Are you certain that this issue is reproducible on the non-expo environment? I've just tested your repro on the expo environment and non-expo environment and I can only reproduce it on the expo env 🤔

image

@NikolaB131
Copy link
Author

NikolaB131 commented Oct 12, 2023

Hi! Just tried reproduce issue on new bare React Native project. And issue reproduced. And again when i switched version of @react-navigation/native-stack to 6.9.13, issue disappeared. Unfortunately i dont have mac, so i only can reproduce it on android.

bug

@tboba
Copy link
Member

tboba commented Oct 12, 2023

@NikolaB131 thanks for the update! First thing that comes to my mind is that it could be the problem related directly to the @react-navigation/native-stack. Let me take a look on that - I'll keep you updated.

@tboba tboba self-assigned this Oct 12, 2023
@arnoldo-rodriguez
Copy link

Issue resolved for me on "@react-navigation/native-stack": "6.9.17",

@NikolaB131
Copy link
Author

Issue resolved for me on "@react-navigation/native-stack": "6.9.17",

Yep, I just checked, issue gone on "6.9.17"

@tboba
Copy link
Member

tboba commented Jan 22, 2024

@ArnoldoJr @NikolaB131 Glad to hear that, thanks for confirming!
Cheers!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snack or repo is provided
Projects
None yet
Development

No branches or pull requests

3 participants