feat: show synthetic email warning in AuthMethodsSection

This commit is contained in:
Kirill
2026-05-24 12:29:46 +05:00
parent 1e98720751
commit e52588686a
@@ -10,6 +10,8 @@ import { useMutation } from '@tanstack/react-query'
import { useUnit } from 'effector-react'
import { useForm } from 'react-hook-form'
import { useSearchParams } from 'react-router-dom'
import { getErrorMessage } from '@/shared/lib/get-error-message'
import { isSyntheticEmail } from '@/shared/lib/is-synthetic-email'
import {
$user,
changePasswordFx,
@@ -19,7 +21,6 @@ import {
unlinkOAuthFx,
type AuthMethod,
} from '@/shared/model/auth'
import { getErrorMessage } from '@/shared/lib/get-error-message'
const METHOD_LABELS: Record<string, string> = { password: 'Пароль', vk: 'ВКонтакте', yandex: 'Яндекс' }
@@ -117,6 +118,13 @@ export function AuthMethodsSection() {
{user.email}
</Typography>
{isSyntheticEmail(user.email) && (
<Alert severity="info" sx={{ mb: 2 }}>
Ваша почта сгенерирована автоматически. Без указания реальной почты вы не сможете получать уведомления о
заказах.
</Alert>
)}
{!verificationUrl && (
<Stack direction="row" spacing={1} sx={{ mb: 2 }}>
<TextField