You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
1.8 KiB

5 months ago
  1. import React, { useState } from 'react';
  2. import {View} from 'react-native'
  3. import ETextInput from '@components/ETextInput';
  4. import EFullButton, { ESmallButton } from '@components/EButton';
  5. import EText, { ELabelText, ETitleText } from '@components/EText';
  6. import ENavButtons from '@components/ENavButtons';
  7. // implement logic here later.
  8. export default function PasswordResetEmailInput(props:any) {
  9. const [email, setEmail] = useState<string>('');
  10. const emailre = /(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9]))\.){3}(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9])|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])/;
  11. return (
  12. <>
  13. <View
  14. style={{
  15. flex: 1,
  16. flexDirection: 'column',
  17. }}>
  18. <ENavButtons back={true} />
  19. <View style={{flexDirection: 'column', marginTop: 0}}>
  20. <View style={{marginBottom: 24}}>
  21. <ETitleText style={{marginBottom:8}}> </ETitleText>
  22. <EText> </EText>
  23. </View>
  24. <View style={{rowGap: 8}}>
  25. <ELabelText></ELabelText>
  26. <ETextInput placeholder='이메일 입력하기' value={email} setValue={setEmail} />
  27. <ESmallButton text={'재설정 이메일 보내기'} active={emailre.test(email)} />
  28. </View>
  29. </View>
  30. <EFullButton style={{marginTop:380}} text='다음' active={emailre.test(email)}/>
  31. </View>
  32. </>
  33. );
  34. }