[web] handle common props in virtual detector#3982
Merged
akwasniewski merged 10 commits intoFeb 24, 2026
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes propagation of common web-only DOM props (enableContextMenu, touchAction, userSelect) through the v3 “virtual detector” path so they can be applied to virtual children/handlers on web.
Changes:
- Extends virtual detector props/types to carry
userSelect,touchAction, andenableContextMenu. - Passes these props from
VirtualDetector→ intercepting context → web host detector. - Updates the web host detector to apply per-virtual-child DOM config to the attached virtual handler tags.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/react-native-gesture-handler/src/v3/types/DetectorTypes.ts | Adds DOM-prop fields to VirtualChild so intercepting/host layers can receive them. |
| packages/react-native-gesture-handler/src/v3/detectors/common.ts | Makes VirtualDetectorProps include common detector props (web-only DOM props). |
| packages/react-native-gesture-handler/src/v3/detectors/VirtualDetector/VirtualDetector.tsx | Plumbs DOM props into the registered VirtualChild and updates effect deps. |
| packages/react-native-gesture-handler/src/v3/detectors/VirtualDetector/InterceptingGestureDetector.tsx | Includes DOM props when mapping virtual children on web before passing to host detector. |
| packages/react-native-gesture-handler/src/v3/detectors/HostGestureDetector.web.tsx | Applies per-virtual-child DOM config via updateGestureHandlerConfig for virtual handler tags. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
m-bert
approved these changes
Feb 19, 2026
…tureDetector.web.tsx Co-authored-by: Michał Bert <63123542+m-bert@users.noreply.github.com>
j-piasecki
requested changes
Feb 23, 2026
added 2 commits
February 23, 2026 10:27
j-piasecki
approved these changes
Feb 24, 2026
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.
Description
Common web-only props
enableContextMenu,touchAction,userSelectwere not properly handled inside virtual detector. This PR fixes it.Test plan
Tested on the following example
Details