-
-
Notifications
You must be signed in to change notification settings - Fork 530
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
fix: add internal isNewBackTitleImplementation const #1791
fix: add internal isNewBackTitleImplementation const #1791
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
src/utils.ts
Outdated
|
||
// Because of a bug introduced in https://github.com/software-mansion/react-native-screens/pull/1646 | ||
// react-native-screens v3.21 changed how header's backTitle handles whitespace strings in https://github.com/software-mansion/react-native-screens/pull/1726 | ||
// To allow for backwards compatibility in @react-navigation/native-stack we need have a way to check if this version or newer is used |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// To allow for backwards compatibility in @react-navigation/native-stack we need have a way to check if this version or newer is used | |
// To allow for backwards compatibility in @react-navigation/native-stack we need a way to check if this version or newer is used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
Description
Because of a bug introduced in #1646
react-native-screens
v3.21 changed how header's backTitle handles whitespace strings in #1726To allow for backwards compatibility in @react-navigation/native-stack we need have a way to check if this version or newer is used
See react-navigation/react-navigation#11423 for more context.
Changes
Added new
isNewBackTitleImplementation
internal constant that can be used in@react-navigation/native-stack
.Screenshots / GIFs
This change & react-navigation/react-navigation#11423 applied:
Screen.Recording.2023-06-16.at.15.12.46.mov
Without this change and react-navigation/react-navigation#11423:
Screen.Recording.2023-06-16.at.15.14.19.mov
Test code and steps to reproduce
Test1791.tsx
You need to apply changes introduced in react-navigation/react-navigation#11423 to
@react-navigation/native-stack
to test these canges.Checklist