diff --git a/example/src/ButtonExample.js b/example/src/ButtonExample.js index 2e7e3aa019..efc8ede4f3 100644 --- a/example/src/ButtonExample.js +++ b/example/src/ButtonExample.js @@ -30,21 +30,29 @@ class ButtonExample extends React.Component { return ( - - - + + + - - + - - + - - - - diff --git a/src/components/DrawerItem.js b/src/components/DrawerItem.js index 8db591ab11..ab28181cd1 100644 --- a/src/components/DrawerItem.js +++ b/src/components/DrawerItem.js @@ -55,7 +55,6 @@ const DrawerItem = ({ icon, label, active, - onPress, theme, ...props }: Props) => { @@ -76,7 +75,7 @@ const DrawerItem = ({ const fontFamily = theme.fonts.medium; const labelMargin = icon ? 32 : 0; return ( - + {icon && } { style, background, borderless, + disabled: disabledProp, rippleColor, underlayColor, children, ...rest } = this.props; + const disabled = disabledProp || !this.props.onPress; + if ( Platform.OS === 'android' && Platform.Version >= ANDROID_VERSION_LOLLIPOP @@ -82,6 +89,7 @@ export default class TouchableRipple extends React.Component { return ( { /* $FlowFixMe */