iOS: Fix bottom tabs visibility on iOS 18 - #8363
Open
guyca wants to merge 1 commit into
Open
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
tabBarHidden requires an SDK-version guard to prevent compilation failures with Xcode 15 or earlier.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Updates iOS bottom-tab visibility handling for iOS 18 while preserving legacy behavior.
Changes:
- Uses version-aware tab-bar visibility APIs.
- Adds native regression tests.
- Adds a playground reproduction.
File summaries
| File | Description |
|---|---|
playground/src/testIDs.ts |
Adds the reproduction test ID. |
playground/src/screens/LayoutsScreen.tsx |
Adds a hidden bottom-tab modal reproduction. |
playground/ios/NavigationTests/UITabBarController+RNNOptionsTest.mm |
Tests version-aware visibility helpers. |
playground/ios/NavigationTests/RNNBottomTabsAppearancePresenterTest.mm |
Tests initial hidden-state handling. |
playground/ios/NavigationTests/BottomTabsControllerTest.mm |
Tests controller visibility behavior and stack precedence. |
ios/UITabBarController+RNNOptions.mm |
Adds iOS 18 visibility handling, but lacks an SDK preprocessor guard for older Xcode toolchains. |
ios/UITabBarController+RNNOptions.h |
Declares the visibility-state helper. |
ios/RNNComponentViewController.mm |
Uses active tab-bar visibility for layout. |
ios/RNNBottomTabsController.mm |
Synchronizes custom-row visibility. |
ios/BottomTabsBasePresenter.mm |
Applies initial iOS 18 visibility. |
Review details
- Files reviewed: 10/10 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+195
to
+201
| - (BOOL)rnn_isTabBarHidden { | ||
| if (@available(iOS 18.0, *)) { | ||
| return self.tabBarHidden; | ||
| } | ||
|
|
||
| return self.tabBar.hidden; | ||
| } |
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.
Use the iOS 18 tab bar visibility API so hidden bottom tabs initialize and update correctly. Preserve legacy behavior on earlier iOS versions.