[RN] Improve app-settings back button style

This commit is contained in:
zbettenbuk
2018-01-26 11:17:44 +01:00
committed by Saúl Ibarra Corretgé
parent 6f8f64ba48
commit aa9efd6f69
2 changed files with 10 additions and 24 deletions

View File

@@ -4,15 +4,9 @@ import React, { Component } from 'react';
import { TouchableOpacity } from 'react-native';
import { Icon } from '../../base/font-icons';
import { Platform } from '../../base/react';
import styles from './styles';
/**
* The icon glyph to be used on a specific platform.
*/
const BACK_ICON = Platform.OS === 'android' ? 'arrow_back' : 'navigate_before';
/**
* The type of the React {@code Component} props of {@link BackButton}
*/
@@ -30,7 +24,7 @@ type Props = {
};
/**
* A component rendering a back button that looks native on both platforms.
* A component rendering a back button.
*/
export default class BackButton extends Component<Props> {
/**
@@ -45,7 +39,7 @@ export default class BackButton extends Component<Props> {
accessibilityLabel = { 'Back' }
onPress = { this.props.onPress }>
<Icon
name = { BACK_ICON }
name = { 'arrow_back' }
style = { [
styles.backIcon,
this.props.style