-
-
Notifications
You must be signed in to change notification settings - Fork 595
fix: Disable interactions on minimal required subroot #3311
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
Open
kmichalikk
wants to merge
6
commits into
main
Choose a base branch
from
@kmichalikk/bottom-tabs-interactive-disabled-3307
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
fix: Disable interactions on minimal required subroot #3311
kmichalikk
wants to merge
6
commits into
main
from
@kmichalikk/bottom-tabs-interactive-disabled-3307
+147
−8
Conversation
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
442e03e to
a2526cd
Compare
c7cb4e7 to
8403629
Compare
8403629 to
128773d
Compare
t0maboro
reviewed
Oct 24, 2025
kligarski
approved these changes
Oct 27, 2025
3 tasks
128773d to
e0b5784
Compare
t0maboro
approved these changes
Oct 29, 2025
|
Is there any ETA for this to be merged 👀 |
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.
Description
Fixes #3307
This PR changes the logic for setting
userInteractionsEnabled = falsefor the time of screen transitions. Currently, when transition happens, the whole UIWindow gets disabled. This included the time when the whole stack is detached from the window, for instance, when changing the tab in BottomTabs. This unnecessarily removes the ability to click through tabs for the time of the transition. Moreover, in some cases on hot reload, the call to disable the interactions is not matched with re-enabling them. This PR fixes both issues by introducing a helper class with one instance shared across screens, that finds an appropriate view to disable, and stores a reference to it, to make sure the correct one is re-enabled.The final attempt disables interaction for RNSScreenStack's first subview, which wraps navigation header and screen content, and adds a temporary gesture recognizer for RNSScreenStackView which captures swipe gestures and does nothing so the gestures are not propagated further (for instance, to outer stack when one is nested in another, which would result in the whole stack being dismissed if user happens to swipe again mid transition).
Changes
Set
userInteractionsEnabled = falseon RNSScreenStack subview. Temporarily add UIPanGestureRecognizer to sink all gesture event.Test code and steps to reproduce
Use BottomTabsTest to verify that BottomTabs can be clicked through, and Test3093 to verify that the logic for stack doesn't change.