[Android] TouchableNativeFeedback's ripples aren't affected by borderRadius when useForeground is true
brentvatne opened this issue ยท 8 comments
Related issue: #6480 -- this was resolved with useForeground={false}
, but borderRadius of parent is not respected when useForeground={true}
.
Have you read the Bugs section of the Contributing to React Native Guide?
Yup!
Environment
react-native -v
: 0.45.1node -v
: 7.9.0npm -v
: 4.6.1yarn --version
(if you use Yarn): 0.24.5
Then, specify:
- Target Platform (e.g. iOS, Android): Android
- Development Operating System (e.g. macOS Sierra, Windows 10): macOS
- Build tools (Xcode or Android Studio version, iOS or Android SDK version, if relevant): Unrelated
Steps to Reproduce
See the demo / description below.
Expected Behavior
When using TouchableNativeFeedback
with useForeground
, I expect the ripple to be clipped when there are rounded corners on the parent container. This is how it works if useForeground={false}
.
Actual Behavior
The ripple is not clipped when useForeground
is enabled and the parent has a borderRadius.
Reproducible Demo
Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we're automatically closing issues after a period of inactivity. Please do not take it personally!
If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:
- Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
- If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
- Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.
If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.
+1 The issue is still actual. Can be reproduced with
"react-native": "^0.47.1"
Meantime the useForeground={false}
works as expected.
And according to the documentation useForeground
is :
This is useful if one of your child views has a background of its own, or you're e.g. displaying images, and you don't want the ripple to be covered by them.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. If you think this issue should definitely remain open, please let us know why. Thank you for your contributions.
Although this is clearly not a priority, it's still relevant. Don't think it should be Stale.
There is a work around in React Native v 0.51 and v 0.50/ Expo v 24.0 and v 23.0, you can set overflow: 'hidden'
on the parent view of the <TouchableNativeFeedback >
. You can see the example here: https://snack.expo.io/H17_STXXz
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. If you think this issue should definitely remain open, please let us know why. Thank you for your contributions.
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as "For Discussion" or "Good first issue" and I will leave it open. Thank you for your contributions.
Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.