From 2f83a111a28d9ff46ad1f57cd3f9ff69196cbb5e Mon Sep 17 00:00:00 2001 From: Aish Raj Dahal Date: Sun, 14 Apr 2019 12:32:23 -0700 Subject: [PATCH] Take user to the main page when the autocomplete item is selected --- parijat-frontend/src/components/searchbox/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parijat-frontend/src/components/searchbox/index.js b/parijat-frontend/src/components/searchbox/index.js index ed3630de..305c5a6b 100644 --- a/parijat-frontend/src/components/searchbox/index.js +++ b/parijat-frontend/src/components/searchbox/index.js @@ -122,7 +122,7 @@ export default class SearchBox extends Component { }; onAutocompleteSelect = searchValue => { - this.setState({ searchValue, transliterationSuggestions: [] }); + this.props.onSubmit(this.state.searchValue); }; handleSubmit = evnt => {