feat: country selection, add birthdate and add error messages for textfields

This commit is contained in:
2025-07-22 17:36:35 +03:30
committed by Koosha Lahouti
parent 9e471670d3
commit 09e4dfa917
4 changed files with 220 additions and 209 deletions

View File

@@ -72,6 +72,7 @@ export function EmailSection({
variant="outlined"
value={email}
onChange={(e) => setEmail(e.target.value)}
error={!correctEmail}
sx={{
width: !isVerifyingCode && !emailVerified ? '446px' : '634px',
transition: 'width 0.3s',
@@ -111,17 +112,25 @@ export function EmailSection({
},
}}
/>
{email && (
<Typography
sx={{ color: correctEmail ? 'green' : 'red' }}
variant="caption"
>
{correctEmail ? '' : t('completion.emailCorrectForm')}
</Typography>
)}
</Box>
{!isVerifyingCode && !emailVerified && (
<Button
variant="text"
onClick={handleSendCode}
sx={{ width: '156px' }}
disabled={
buttonState === 'sent' ||
buttonState === 'counting' ||
!correctEmail
}
// disabled={
// buttonState === 'sent' ||
// buttonState === 'counting' ||
// !correctEmail
// }
>
{getButtonLabel()}
</Button>