Merge branch 'flicknow-make-choose-account-scrollable' into main

zio/stable
Paul Frazee 2023-11-02 09:43:37 -07:00
commit c8b9407e0e
1 changed files with 10 additions and 2 deletions

View File

@ -3,6 +3,7 @@ import {
ActivityIndicator, ActivityIndicator,
Keyboard, Keyboard,
KeyboardAvoidingView, KeyboardAvoidingView,
ScrollView,
StyleSheet, StyleSheet,
TextInput, TextInput,
TouchableOpacity, TouchableOpacity,
@ -28,6 +29,7 @@ import {isNetworkError} from 'lib/strings/errors'
import {usePalette} from 'lib/hooks/usePalette' import {usePalette} from 'lib/hooks/usePalette'
import {useTheme} from 'lib/ThemeContext' import {useTheme} from 'lib/ThemeContext'
import {cleanError} from 'lib/strings/errors' import {cleanError} from 'lib/strings/errors'
import {isWeb} from 'platform/detection'
enum Forms { enum Forms {
Login, Login,
@ -202,7 +204,7 @@ const ChooseAccountForm = ({
} }
return ( return (
<View testID="chooseAccountForm"> <ScrollView testID="chooseAccountForm" style={styles.maxHeight}>
<Text <Text
type="2xl-medium" type="2xl-medium"
style={[pal.text, styles.groupLabel, s.mt5, s.mb10]}> style={[pal.text, styles.groupLabel, s.mt5, s.mb10]}>
@ -267,7 +269,7 @@ const ChooseAccountForm = ({
<View style={s.flex1} /> <View style={s.flex1} />
{isProcessing && <ActivityIndicator />} {isProcessing && <ActivityIndicator />}
</View> </View>
</View> </ScrollView>
) )
} }
@ -990,4 +992,10 @@ const styles = StyleSheet.create({
marginRight: 5, marginRight: 5,
}, },
dimmed: {opacity: 0.5}, dimmed: {opacity: 0.5},
maxHeight: {
// @ts-ignore web only -prf
maxHeight: isWeb ? '100vh' : undefined,
height: !isWeb ? '100%' : undefined,
},
}) })