Skip to content

regression: modal touchables not working after RNGH migration#7101

Merged
Rohit3523 merged 2 commits intodevelopfrom
modal-button-fix
Apr 7, 2026
Merged

regression: modal touchables not working after RNGH migration#7101
Rohit3523 merged 2 commits intodevelopfrom
modal-button-fix

Conversation

@Rohit3523
Copy link
Copy Markdown
Member

@Rohit3523 Rohit3523 commented Apr 6, 2026

Proposed changes

Buttons are not clickable inside some modals, including the two-factor authentication modal. This regression was introduced in #6997

As mentioned in https://docs.swmansion.com/react-native-gesture-handler/docs/fundamentals/installation/#android, we need to wrap the modal content with GestureHandlerRootView to allow RectButton to receive press events inside the modal. This was missed in a few places.

Issue(s)

https://rocketchat.atlassian.net/browse/CORE-2062
Closes: #7102

How to test or reproduce

Screenshots

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • Improvement (non-breaking change which improves a current function)
  • New feature (non-breaking change which adds functionality)
  • Documentation update (if none of the other choices apply)

Checklist

  • I have read the CONTRIBUTING doc
  • I have signed the CLA
  • Lint and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works (if applicable)
  • I have added necessary documentation (if applicable)
  • Any dependent changes have been merged and published in downstream modules

Further comments

Summary by CodeRabbit

  • Improvements
    • Enhanced touch responsiveness and gesture handling in modal dialogs used for authentication and user interaction flows.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 6, 2026

Walkthrough

Five modal-containing components have been updated to wrap their modal content with GestureHandlerRootView from react-native-gesture-handler. This addresses a bug where buttons inside modals became unclickable after migrating from react-native-platform-touchable to RectButton.

Changes

Cohort / File(s) Summary
Basic Modal Gesture Handler Wrapping
app/containers/TwoFactor/index.tsx, app/views/JitsiMeetView/JitsiAuthModal.tsx, app/views/RoomView/Banner.tsx
Wrapped modal content View with GestureHandlerRootView to enable gesture handling for touch interactions while preserving existing styles and layout.
Modal with Layout Container
app/views/ChangePasscodeView.tsx, app/views/ScreenLockedView.tsx
Wrapped modal content with GestureHandlerRootView and introduced new styles.container style (flex: 1 with centered content) to manage layout of nested children including passcode components and close controls.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested labels

type: bug

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: fixing non-clickable modal touchables after RNGH migration by wrapping content with GestureHandlerRootView.
Linked Issues check ✅ Passed All code changes directly address CORE-2062 by wrapping modal content with GestureHandlerRootView in affected modals to restore RectButton press handling.
Out of Scope Changes check ✅ Passed All changes are in-scope: five modals (TwoFactor, ChangePasscodeView, JitsiAuthModal, Banner, ScreenLockedView) consistently receive GestureHandlerRootView wrapping with necessary style adjustments.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Rohit3523 Rohit3523 had a problem deploying to experimental_ios_build April 6, 2026 17:32 — with GitHub Actions Error
@Rohit3523 Rohit3523 had a problem deploying to official_android_build April 6, 2026 17:32 — with GitHub Actions Error
@Rohit3523 Rohit3523 had a problem deploying to experimental_android_build April 6, 2026 17:32 — with GitHub Actions Error
Copy link
Copy Markdown
Contributor

@OtavioStasiak OtavioStasiak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@OtavioStasiak OtavioStasiak temporarily deployed to approve_e2e_testing April 6, 2026 20:54 — with GitHub Actions Inactive
@OtavioStasiak OtavioStasiak requested a deployment to official_android_build April 6, 2026 20:57 — with GitHub Actions Waiting
@OtavioStasiak OtavioStasiak requested a deployment to experimental_ios_build April 6, 2026 20:57 — with GitHub Actions Waiting
@OtavioStasiak OtavioStasiak requested a deployment to experimental_android_build April 6, 2026 20:57 — with GitHub Actions Waiting
@Rohit3523
Copy link
Copy Markdown
Member Author

Right now Profile update test is failing because of rate limit issue, which we are going to fix this issue in separate PR.

@Rohit3523 Rohit3523 merged commit d03eb78 into develop Apr 7, 2026
31 of 39 checks passed
@Rohit3523 Rohit3523 deleted the modal-button-fix branch April 7, 2026 13:26
diegolmello pushed a commit that referenced this pull request Apr 7, 2026
Co-authored-by: Otávio Stasiak <91474186+OtavioStasiak@users.noreply.github.com>
@diegolmello diegolmello mentioned this pull request Apr 7, 2026
10 tasks
diegolmello pushed a commit that referenced this pull request Apr 8, 2026
Co-authored-by: Otávio Stasiak <91474186+OtavioStasiak@users.noreply.github.com>
diegolmello pushed a commit that referenced this pull request Apr 8, 2026
Co-authored-by: Otávio Stasiak <91474186+OtavioStasiak@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Problem with android application

2 participants