Skip to content
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

Update ScrollView document to add pointerEvents prop #2936

Closed
wants to merge 1 commit into from

Conversation

ryancat
Copy link

@ryancat ryancat commented Jan 21, 2022

No description provided.

@netlify
Copy link

netlify bot commented Jan 21, 2022

✔️ Deploy Preview for react-native ready!

🔨 Explore the source changes: c691105

🔍 Inspect the deploy log: https://app.netlify.com/sites/react-native/deploys/61ea17037ba8200007faedfd

😎 Browse the preview: https://deploy-preview-2936--react-native.netlify.app

@Simek
Copy link
Collaborator

Simek commented Jan 21, 2022

Hi @ryancat, thank you for the update suggestion! 👍 Unfortunately pointerEvents prop is inherited from the View component:

In cases like this we avoid the prop duplication on the child component, because otherwise list of the props will be quite overwhelming and maintaining the multiple instances of the same prop in various pages would be difficult and it would be easy to miss one when updating the docs. Hope you understand that! 🙂

@Simek Simek closed this Jan 21, 2022
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Jan 21, 2022
Summary:
Per discussion in the previous diff D33672110, it's ok to add the `pointerEvents` prop to scrollview. This will help prevent scrolling on the ScrollView if pointerEvents is set to `box-none`, or `none`.

Corresponding doc changes are in facebook/react-native-website#2936

Changelog:
[Android][Added] - Add new API in ScrollView and HorizontalScrollView to process pointerEvents prop.

Reviewed By: javache

Differential Revision: D33699223

fbshipit-source-id: 1cae5113e9e7d988fc4c4765c41d817a321804c4
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.

3 participants