From d1d1e218be52f3a509221f0ce4b5b42e682067cf Mon Sep 17 00:00:00 2001 From: Shravya Ramesh Date: Mon, 1 Mar 2021 16:40:28 -0800 Subject: Created new search screen --- src/screens/search/SearchScreen.tsx | 125 +++++++++++++++++++++--------------- 1 file changed, 75 insertions(+), 50 deletions(-) (limited to 'src/screens') diff --git a/src/screens/search/SearchScreen.tsx b/src/screens/search/SearchScreen.tsx index 70733d7e..e4ac4c9e 100644 --- a/src/screens/search/SearchScreen.tsx +++ b/src/screens/search/SearchScreen.tsx @@ -7,15 +7,16 @@ import { ScrollView, StatusBar, StyleSheet, + Text, + View, } from 'react-native'; import Animated, {Easing, timing} from 'react-native-reanimated'; +import {SafeAreaView} from 'react-native-safe-area-context'; import {useDispatch, useSelector} from 'react-redux'; import { Explore, RecentSearches, - SearchBackground, SearchBar, - SearchHeader, SearchResultList, SearchResultsBackground, TabsGradient, @@ -25,7 +26,7 @@ import {loadSearchResults} from '../../services'; import {loadRecentlySearched, resetScreenType} from '../../store/actions'; import {RootState} from '../../store/rootReducer'; import {ProfilePreviewType, ScreenType} from '../../types'; -import {SCREEN_HEIGHT, SCREEN_WIDTH, StatusBarHeight} from '../../utils'; +import {normalize, SCREEN_HEIGHT, SCREEN_WIDTH} from '../../utils'; /** * Search Screen for user recommendations and a search @@ -148,60 +149,65 @@ const SearchScreen: React.FC = () => { }; return ( - - - - }> - - - - - - {results === undefined && recents.length !== 0 ? ( - - ) : ( - - )} - - - - + + + + + }> + + + Try searching for people, groups, or clubs + + + + {results === undefined && recents.length !== 0 ? ( + + ) : ( + + )} + + + + + ); }; const styles = StyleSheet.create({ + mainContainer: {backgroundColor: '#fff', height: SCREEN_HEIGHT * 0.9}, contentContainer: { - paddingTop: StatusBarHeight, - paddingBottom: SCREEN_HEIGHT / 15, + paddingTop: '2%', + paddingBottom: SCREEN_HEIGHT / 3, + paddingHorizontal: '3%', }, searchBar: { - paddingHorizontal: '3%', + paddingLeft: '3%', }, header: { marginVertical: 20, @@ -215,6 +221,15 @@ const styles = StyleSheet.create({ fontWeight: 'bold', flexGrow: 1, }, + helperText: { + fontWeight: '400', + fontSize: 14, + lineHeight: normalize(16.71), + color: '#828282', + marginBottom: '2%', + margin: '2.5%', + textAlign: 'center', + }, clear: { fontSize: 17, fontWeight: 'bold', @@ -242,5 +257,15 @@ const styles = StyleSheet.create({ textAlign: 'center', marginHorizontal: '10%', }, + cancelButton: { + position: 'absolute', + height: '100%', + justifyContent: 'center', + paddingHorizontal: 5, + }, + cancelText: { + color: '#818181', + fontWeight: '600', + }, }); export default SearchScreen; -- cgit v1.2.3-70-g09d2