Repository navigation
[Liquid Glass Follow Up] Show the native tab bar at the start of an iOS swipe-back - #104727
Draft
sumo-slonik wants to merge 6 commits into
Draft
sumo-slonik wants to merge 6 commits into
sumo-slonik wants to merge 6 commits into
Conversation
1 of 2 tasks
Replaces holding the bar until a push ends, which design rejected.
1 of 7 tasks
Contributor
|
|
Contributor
|
🚧 shawnborton has triggered a test Expensify/App build. You can view the workflow run here. |
Contributor
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
…ushed screen, so Spend reports match Inbox chats
This branch has not been deployed
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.
Explanation of Change
On iOS the native tab bar hides together with the push from a tab root, but after a swipe-back it came back only once the pushed screen had fully slid away. React Navigation removes the screen from the state only when the swipe-back gesture ends, and the bar visibility follows the state.
Now, when the swipe-back starts, the tab root screen reports that it is coming back into view (
transitionStartwithclosing: falsefrom react-native-screens), and the bar starts showing right away, together with the gesture. This matches how it already behaves on push and on the header back button. The bar is still the native UIKit tab bar: we only flip the sametabBarHiddenflag earlier, and UIKit animates it as before.Effectsof the split, workspace and search navigators, the stacks that live inside tabs. Other platforms get a no-op.Trade-off: when the swipe-back is cancelled, react-native-screens tells us only after the screen has slid back into place, so the bar stays visible for a moment over the screen and then hides. Avoiding that would need the bar to track the gesture natively (a react-native-screens patch driving it from the transition coordinator), which felt like too much for this case. Cancelled swipes are rare, so we went with the simpler JS-only fix.
On iOS 26, UIKit's own hide animation cleared the tab icons a moment before it faded the liquid glass, while its show animation brings both in together, so hiding looked abrupt. The existing react-native-screens patch 002, which already makes the bar hide with an animation, now fades the whole bar out itself on iOS 26 and hides it without animation once it is invisible, so the icons and the glass go away together. If the bar has to show again before the fade ends, the fade reverses. Showing the bar still uses UIKit's animation, and iOS 18-25 behave as before. The fade-out is not upstream, so
details.mdnotes that this patch shrinks to it instead of being removed on the react-native-screens 4.29.0 bump.Fixed Issues
$ #104203
PROPOSAL: N/A
Tests
Offline tests
The tab bar visibility does not depend on the network, so the result should match the online run.
QA Steps
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari