diff --git a/src/Header.js b/src/Header.js index a6ab955..760c91b 100644 --- a/src/Header.js +++ b/src/Header.js @@ -7,7 +7,8 @@ import { StyleSheet, View, } from 'react-native'; -import { withNavigation, HeaderBackButton } from 'react-navigation'; +import { withNavigation } from 'react-navigation'; +import { HeaderBackButton } from 'react-navigation-stack'; import { getInset, getStatusBarHeight } from 'react-native-safe-area-view'; import { isIphoneX } from 'react-native-iphone-x-helper'; diff --git a/src/SearchBar.ios.js b/src/SearchBar.ios.js index 13472a4..6d1607b 100644 --- a/src/SearchBar.ios.js +++ b/src/SearchBar.ios.js @@ -178,7 +178,7 @@ export default class SearchBar extends React.PureComponent { if (this.props.onCancelPress) { this.props.onCancelPress(this.props.navigation.goBack); } else { - this.props.navigation.goBack(); + this.props.navigation.goBack(null); } }; } diff --git a/src/SearchLayout.js b/src/SearchLayout.js index a0be087..9d882da 100644 --- a/src/SearchLayout.js +++ b/src/SearchLayout.js @@ -50,6 +50,7 @@ export default class SearchLayout extends React.Component { tintColor={ this.props.searchInputTintColor || this.props.headerTintColor } + cancelButtonText={this.props.cancelButtonText} />