uri bar search actions, and settings style tweaks

This commit is contained in:
Akinwale Ariwodola 2018-08-31 08:35:18 +01:00
parent 23d4658fd8
commit bd307d8108
3 changed files with 14 additions and 4 deletions

View file

@ -45,12 +45,20 @@ class UriBar extends React.PureComponent {
}
handleItemPress = (item) => {
const { navigation, updateSearchQuery } = this.props;
const { navigation, onSearchSubmitted, updateSearchQuery } = this.props;
const { type, value } = item;
Keyboard.dismiss();
if (SEARCH_TYPES.SEARCH === type) {
this.setState({ currentValue: value });
updateSearchQuery(value);
if (onSearchSubmitted) {
onSearchSubmitted(value);
return;
}
navigation.navigate({ routeName: 'Search', key: 'searchPage', params: { searchQuery: value }});
} else {
const uri = normalizeURI(value);

View file

@ -46,7 +46,7 @@ class SettingsPage extends React.PureComponent {
<View style={settingsStyle.row}>
<View style={settingsStyle.switchText}>
<Text style={settingsStyle.label}>Keep the daemon background service running when the app is suspended.</Text>
<Text style={settingsStyle.label}>Keep the daemon background service running after closing the app</Text>
<Text style={settingsStyle.description}>Enable this option for quicker app launch and to keep the synchronisation with the blockchain up to date.</Text>
</View>
<View style={settingsStyle.switchContainer}>

View file

@ -25,12 +25,14 @@ const settingsStyle = StyleSheet.create({
},
label: {
fontSize: 14,
fontFamily: 'Metropolis-Regular'
fontFamily: 'Metropolis-Regular',
lineHeight: 18
},
description: {
color: '#aaaaaa',
fontSize: 12,
fontFamily: 'Metropolis-Regular',
color: '#aaaaaa'
lineHeight: 18
}
});