...
|
...
|
@@ -49,7 +49,14 @@ const styles = StyleSheet.create({ |
|
|
fontWeight: '500',
|
|
|
color: '#0A0A0A',
|
|
|
position: 'absolute',
|
|
|
top: Platform.OS === 'ios' ? 20 : 5,
|
|
|
...Platform.select({
|
|
|
ios: {
|
|
|
top: 20,
|
|
|
},
|
|
|
android: {
|
|
|
top: 5,
|
|
|
},
|
|
|
}),
|
|
|
left: 0,
|
|
|
right: 0,
|
|
|
backgroundColor: 'transparent',
|
...
|
...
|
@@ -58,7 +65,14 @@ const styles = StyleSheet.create({ |
|
|
backgroundColor: 'transparent',
|
|
|
paddingTop: 0,
|
|
|
top: 0,
|
|
|
height: Platform.OS === 'ios' ? 64 : 50,
|
|
|
...Platform.select({
|
|
|
ios: {
|
|
|
height: 64,
|
|
|
},
|
|
|
android: {
|
|
|
height: 54,
|
|
|
},
|
|
|
}),
|
|
|
right: 0,
|
|
|
left: 0,
|
|
|
// borderBottomWidth: 0.5,
|
...
|
...
|
@@ -69,7 +83,14 @@ const styles = StyleSheet.create({ |
|
|
width: 130,
|
|
|
height: 37,
|
|
|
position: 'absolute',
|
|
|
bottom: 4,
|
|
|
...Platform.select({
|
|
|
ios: {
|
|
|
top: 22,
|
|
|
},
|
|
|
android: {
|
|
|
top: 10,
|
|
|
},
|
|
|
}),
|
|
|
left: 2,
|
|
|
padding: 8,
|
|
|
flexDirection: 'row',
|
...
|
...
|
@@ -78,7 +99,14 @@ const styles = StyleSheet.create({ |
|
|
width: 100,
|
|
|
height: 37,
|
|
|
position: 'absolute',
|
|
|
bottom: 4,
|
|
|
...Platform.select({
|
|
|
ios: {
|
|
|
top: 22,
|
|
|
},
|
|
|
android: {
|
|
|
top: 10,
|
|
|
},
|
|
|
}),
|
|
|
right: 2,
|
|
|
padding: 8,
|
|
|
},
|
...
|
...
|
@@ -86,7 +114,14 @@ const styles = StyleSheet.create({ |
|
|
width: 100,
|
|
|
height: 37,
|
|
|
position: 'absolute',
|
|
|
bottom: 4,
|
|
|
...Platform.select({
|
|
|
ios: {
|
|
|
top: 20,
|
|
|
},
|
|
|
android: {
|
|
|
top: 8,
|
|
|
},
|
|
|
}),
|
|
|
left: 2,
|
|
|
padding: 8,
|
|
|
},
|
...
|
...
|
@@ -125,7 +160,7 @@ const styles = StyleSheet.create({ |
|
|
|
|
|
const propTypes = {
|
|
|
navigationState: PropTypes.object,
|
|
|
backButtonImage: PropTypes.number,
|
|
|
backButtonImage: Image.propTypes.source,
|
|
|
wrapBy: PropTypes.any,
|
|
|
component: PropTypes.any,
|
|
|
backButtonTextStyle: Text.propTypes.style,
|
...
|
...
|
@@ -316,6 +351,7 @@ class NavBar extends React.Component { |
|
|
const style = [styles.leftButton, self.props.leftButtonStyle, state.leftButtonStyle];
|
|
|
const textStyle = [styles.barLeftButtonText, self.props.leftButtonTextStyle,
|
|
|
state.leftButtonTextStyle];
|
|
|
const leftButtonStyle = [styles.defaultImageStyle, state.leftButtonIconStyle];
|
|
|
|
|
|
if (state.leftButton) {
|
|
|
let Button = state.leftButton;
|
...
|
...
|
@@ -343,7 +379,7 @@ class NavBar extends React.Component { |
|
|
menuIcon = (
|
|
|
<Image
|
|
|
source={buttonImage}
|
|
|
style={state.leftButtonIconStyle || styles.defaultImageStyle}
|
|
|
style={leftButtonStyle}
|
|
|
/>
|
|
|
);
|
|
|
}
|
...
|
...
|
@@ -351,7 +387,6 @@ class NavBar extends React.Component { |
|
|
|
|
|
if (onPress && (state.leftTitle || buttonImage)) {
|
|
|
onPress = onPress.bind(null, state);
|
|
|
|
|
|
return (
|
|
|
<TouchableOpacity
|
|
|
key={'leftNavBarBtn'}
|
...
|
...
|
@@ -366,7 +401,11 @@ class NavBar extends React.Component { |
|
|
}
|
|
|
{buttonImage &&
|
|
|
<View style={{ flex: 1, justifyContent: 'center', alignItems: 'flex-start' }}>
|
|
|
{menuIcon}
|
|
|
{menuIcon || <Image
|
|
|
source={buttonImage}
|
|
|
style={state.leftButtonIconStyle || styles.defaultImageStyle}
|
|
|
/>
|
|
|
}
|
|
|
</View>
|
|
|
}
|
|
|
</TouchableOpacity>
|
...
|
...
|
@@ -435,9 +474,6 @@ class NavBar extends React.Component { |
|
|
const renderTitle = selected.renderTitle ||
|
|
|
selected.component.renderTitle ||
|
|
|
this.props.renderTitle;
|
|
|
|
|
|
let sceneKey = state.sceneKey;
|
|
|
|
|
|
return (
|
|
|
<Animated.View
|
|
|
style={[
|
...
|
...
|
|