-- CODE language-jsx --
import React from 'react';
import {
Button,
Container,
ScreenContainer,
TextField,
withTheme,
} from '@draftbit/ui';
import {
KeyboardAvoidingView,
StatusBar,
StyleSheet,
Text,
} from 'react-native';
const REPLACE_SCREEN_NAME = props => {
const [textFieldValue, setTextFieldValue] = React.useState(undefined);
const { theme } = props;
React.useEffect(() => {
StatusBar.setBarStyle('dark-content');
}, []);
return (
<ScreenContainer scrollable={true} hasSafeArea={true}>
<KeyboardAvoidingView
style={styles.keyboardAvoidingViewLE}
enabled={true}
behavior=""padding""
keyboardVerticalOffset={60}
>
<Container
style={styles.containerOj}
elevation={0}
useThemeGutterPadding={true}
>
<Text
style={StyleSheet.flatten([
styles.textUm,
theme.typography.headline4,
{ color: theme.colors.strong },
])}
>
What's your number?
</Text>
<Text
style={StyleSheet.flatten([
styles.textVh,
theme.typography.body1,
{ color: theme.colors.strong },
])}
>
Enter your telephone and we'll send you a unique code to sign in. No
passwords required.
</Text>
<TextField
style={styles.textFieldE4}
type=""underline""
label=""Telephone""
keyboardType=""phone-pad""
leftIconMode=""inset""
value={textFieldValue}
onChangeText={textFieldValue => setTextFieldValue(textFieldValue)}
/>
</Container>
<Container
style={styles.containerBg}
elevation={0}
useThemeGutterPadding={true}
>
<Button type=""solid"">Sign In</Button>
<Text
style={StyleSheet.flatten([
styles.textGo,
theme.typography.caption,
{ color: theme.colors.light },
])}
>
Messaging charges may apply. By signing in you agree to our Terms of
Service, Privacy Policy and Cookie Policy.
</Text>
</Container>
</KeyboardAvoidingView>
</ScreenContainer>
);
};
const styles = StyleSheet.create({
containerOj: {
marginTop: 32,
},
keyboardAvoidingViewLE: {
flexGrow: 1,
justifyContent: 'space-between',
},
textUm: {
textAlign: 'center',
},
containerBg: {
alignItems: 'center',
},
textVh: {
marginTop: 20,
textAlign: 'center',
},
textGo: {
width: '100%',
marginTop: 16,
textAlign: 'center',
},
textFieldE4: {
height: 82,
marginTop: 20,
},
});
export default withTheme(REPLACE_SCREEN_NAME);