fix lightbox on search page (#1330)

* fix lightbox on search page

* add styles to mobile web too
zio/stable
Eric Bailey 2023-08-29 19:41:50 -05:00 committed by GitHub
parent 22b7964b5e
commit 3a90b479fd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 18 additions and 2 deletions

View File

@ -1,4 +1,5 @@
import React from 'react'
import {View, StyleSheet} from 'react-native'
import {SearchUIModel} from 'state/models/ui/search'
import {FoafsModel} from 'state/models/discovery/foafs'
import {SuggestedActorsModel} from 'state/models/discovery/suggested-actors'
@ -47,13 +48,28 @@ export const SearchScreen = withAuthRequired(
const {isDesktop} = useWebMediaQueries()
if (searchUIModel) {
return <SearchResults model={searchUIModel} />
return (
<View style={styles.scrollContainer}>
<SearchResults model={searchUIModel} />
</View>
)
}
if (!isDesktop) {
return <Mobile.SearchScreen navigation={navigation} route={route} />
return (
<View style={styles.scrollContainer}>
<Mobile.SearchScreen navigation={navigation} route={route} />
</View>
)
}
return <Suggestions foafs={foafs} suggestedActors={suggestedActors} />
}),
)
const styles = StyleSheet.create({
scrollContainer: {
height: '100%',
overflowY: 'auto',
},
})