Fix region sizing on web

This commit is contained in:
Paul Frazee 2023-02-24 10:10:21 -06:00
parent 3e19728618
commit fa115c1cba
14 changed files with 25 additions and 16 deletions

View file

@ -482,9 +482,9 @@ const ForgotPasswordForm = ({
const [email, setEmail] = useState<string>('')
const {screen} = useAnalytics()
// useEffect(() => {
screen('Signin:ForgotPassword')
// }, [screen])
useEffect(() => {
screen('Signin:ForgotPassword')
}, [screen])
const onPressSelectService = () => {
store.shell.openModal({

View file

@ -81,7 +81,7 @@ export const Feed = observer(function Feed({
)
return (
<View style={s.h100pct}>
<View style={s.hContentRegion}>
<CenteredView>
{view.isLoading && !data && <NotificationFeedLoadingPlaceholder />}
{view.hasError && (

View file

@ -95,7 +95,7 @@ export const PostThread = observer(function PostThread({
onRefresh={onRefresh}
onLayout={onLayout}
onScrollToIndexFailed={onScrollToIndexFailed}
style={s.h100pct}
style={s.hContentRegion}
contentContainerStyle={s.contentContainer}
/>
)

View file

@ -279,6 +279,7 @@ const styles = StyleSheet.create({
borderWidth: 1,
borderRadius: 4,
marginBottom: 10,
paddingBottom: 10,
},
outerNoTop: {
borderTopWidth: 0,

View file

@ -23,6 +23,7 @@ import {
ViewProps,
} from 'react-native'
import {addStyle, colors} from 'lib/styles'
import {DESKTOP_HEADER_HEIGHT} from 'lib/constants'
export function CenteredView({
style,
@ -78,7 +79,7 @@ const styles = StyleSheet.create({
},
containerScroll: {
width: '100%',
height: '100%',
height: `calc(100vh - ${DESKTOP_HEADER_HEIGHT}px)`,
maxWidth: 600,
marginLeft: 'auto',
marginRight: 'auto',