Summary
The first release of 2020 of React Native Elements 🎉 This release primarily works on cleaning up and improving some existing components but needed a major release because of breaking changes. As always we'd love your feedback on some of the new changes.
We also welcome a new core contributor:
- Jeremy Hamilton @flyingcircle
New contributors help so that the project stays alive and updated as members move on to other things in life.
Thanks to everyone who contributed to this release, and stay safe amidst the pandemic 😷
🚨 Breaking Changes
Avatar
overlayContainerStyle
is now able to override the borderRadius set on for avatar in rounded mode. If in your app you had set borderRadius or the overflow property on this style, it will now take effect. d72d541 @sudeepto-duttaeditButton
becomesaccessory
.
onEditPress
becomesonAccessoryPress
showEditButton
becomesshowAccessory
accessory
can now include asource
to show a custom image. #2323 @flyingcircle
Button
- On Android, now has a coloured ripple that matches the text color while on solid, and the primary color while on clear, outline. #2137 @iRoachie. To revert this behaviour, set
background={TouchableNativeFeedback.Ripple(undefined, false)}
- When in the loading state,
onPress
events will no longer be triggered. db730c3 @imcvampire
ButtonGroup
- Remove
containerBorderRadius
prop 5f28f0b @Naturalclar- Can use
containerStyle
prop instead
- Can use
Icon
- Now uses the different Touchable for Android. TouchableNativeFeedback will be the default on Android. This will affect the Icon as well as components that use it (SearchBar). To get back the previous behaviour, use
TouchableComponent={TouchableHighlight}
. b7d28c7 @iRoachieunderlayColor
is now set to transparent (previous white). To revert setunderlayColor="white"
activeOpacity
is now set to 0.3. To revert setactiveOpacity={0.85}
Image
- Image can no longer overflow the container c1690c2 @iRoachie. If you need this behaviour set
containerStyle={{ overflow: 'visible' }}
Input
inputComponent
is nowInputComponent
16fbb08 @flyingcircle- Fix default styling so that icon lines up along the left side #2116 @ganes1410
Overlay
Removes containerStyle
, windowBackgroundColor
, overlayBackgroundColor
, borderRadius
, width
, and height
props. Initial width and height of overlay are now auto
before having set values. 7655a85 @iRoachie
containerStyle
becomesbackdropStyle
- For
windowBackgroundColor
, set backgroundColor onbackdropStyle
- For
overlayBackgroundColor
, set backgroundColor onoverlayStyle
- For
borderRadius
, set borderRadius onoverlayStyle
- For
width
andheight
, set width and height onoverlayStyle
Features
- Support for FontAwesome5 🎉 6cc85af @iRoachie
- General improvements for accessibility, CheckBox 0c03c85, Button 3e567de eff6bb3 @iRoachie
Tooltip
Overlay
Now has aModalComponent
prop to allow using a web-compatible modal component for react-native-web. c277ef3 @oxyiiSocialIcon
AddsiconType
prop to allow for custom icon vector icon set. d9bfbc9 @flyingcircleButtonGroup
addvertical
prop #2326 @flyingcircle
Fixes
Button
Ripple now respects borderRadius 23652ac @iRoachieButtonGroup
marginHorizontal
now works oncontainerStyle
adb2973 @oxyiiCheckBox
Allow passing custom testID bac6063 @AsvaroxTooltip
Fixes issues with inaccurate tooltips with the status bar by adding a new propskipAndroidStatusBar
8584917 @oxyiiInput
Fixes issue with error message changing the display height of the component @saxenanihal95Image
Fixes issue with Image not applying style props #2313 @bscaspar
Docs
Input
AddonChangeText
example 5131578 @xAirxInput
Add password example 3caa0ee @morenoh149Checkbox
Add custom Component option totitle
prop 4ec03ac @flyingcircleListItem
Add note that it accepts all props fromTouchableHighlight
b186e53 @tingzhouuToolTip
Fix the anchor tags so that they link correctly 6956db2 @adnanirfan- Typos, Grammar 7cfbda6 @adamdune f41beb5 @baraa95 d14d603 @msal4 951cc83 @dsouzaedison
Other
- Increase test coverage for Tooltip 9fafaf4 @haruelrovix