react-native-macos/Libraries/Components/View
Vojtech Novak bd3868643d add ripple config object to Pressable (#28156)
Summary:
Motivation is to support ripple radius just like in TouchableNativeFeedback, plus borderless attribute. See https://github.com/facebook/react-native/pull/28009#issuecomment-589489520

In the current form this means user needs to pass an `android_ripple` prop which is an object of this shape:
```
export type RippleConfig = {|
  color?: ?ColorValue,
  borderless?: ?boolean,
  radius?: ?number,
|};
```
Do we want to add methods that would create such config objects - https://facebook.github.io/react-native/docs/touchablenativefeedback#methods ?

## Changelog

[Android] [Added] - support borderless and custom ripple radius on Pressable
Pull Request resolved: https://github.com/facebook/react-native/pull/28156

Test Plan:
Tested locally in RNTester. I noticed that when some content is rendered after the touchables, the ripple effect is "cut off" by the boundaries of the next view. This is not specific to Pressable, it happens to TouchableNativeFeedback too but I just didn't notice it before in https://github.com/facebook/react-native/pull/28009. As it is an issue of its own, I didn't investigate that.

![pressable](https://user-images.githubusercontent.com/1566403/75098762-785f2200-55ba-11ea-8842-e648317610e3.gif)

I changed the Touchable example slightly too (I just moved the "custom ripple radius" up to show the "cutting off" issue), so just for completeness:

![touchable](https://user-images.githubusercontent.com/1566403/75098763-81e88a00-55ba-11ea-9528-e0343d1e054b.gif)

Reviewed By: yungsters

Differential Revision: D20071021

Pulled By: TheSavior

fbshipit-source-id: cb553030934205a52dd50a2a8c8a20da6100e23f
2020-04-03 18:37:10 -07:00
..
ReactNativeStyleAttributes.js Exact-by-default codemod for react-native-github 2019-11-21 09:42:57 -08:00
ReactNativeViewAttributes.js Add accessibilityValueDescription support. (#26169) 2019-09-18 03:16:42 -07:00
ReactNativeViewViewConfig.js Re-sync with internal repository 2019-12-19 13:42:21 -08:00
ReactNativeViewViewConfigAndroid.js Convert easy files to flow strict-local 2019-12-05 16:06:46 -08:00
View.js Updating the URLs to point at new domain name reactnative.dev 2020-02-24 13:09:11 -08:00
ViewAccessibility.js Exact-by-default codemod for react-native-github 2019-11-21 09:42:57 -08:00
ViewNativeComponent.js Enable JS view configs for ViewNativeComponent in bridgeless mode 2020-02-03 11:38:31 -08:00
ViewPropTypes.js add ripple config object to Pressable (#28156) 2020-04-03 18:37:10 -07:00