From 23e9444cf4c403c3b8dca7d86c4c46f4ada5ba7c Mon Sep 17 00:00:00 2001 From: Egor Date: Fri, 30 Jan 2026 15:53:23 +0300 Subject: [PATCH] Update Profile.tsx --- src/pages/Profile.tsx | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/src/pages/Profile.tsx b/src/pages/Profile.tsx index 5917286..cd0d164 100644 --- a/src/pages/Profile.tsx +++ b/src/pages/Profile.tsx @@ -11,6 +11,7 @@ import { } from '../api/notifications'; import { referralApi } from '../api/referral'; import { brandingApi, type EmailAuthEnabled } from '../api/branding'; +import ChangeEmailModal from '../components/ChangeEmailModal'; // Icons const CopyIcon = () => ( @@ -42,6 +43,16 @@ const ArrowRightIcon = () => ( ); +const PencilIcon = () => ( + + + +); + export default function Profile() { const { t } = useTranslation(); const { user, setUser } = useAuthStore(); @@ -53,6 +64,7 @@ export default function Profile() { const [error, setError] = useState(null); const [success, setSuccess] = useState(null); const [copied, setCopied] = useState(false); + const [showChangeEmailModal, setShowChangeEmailModal] = useState(false); // Referral data const { data: referralInfo } = useQuery({ @@ -311,7 +323,16 @@ export default function Profile() { )} {user.email_verified && ( -

{t('profile.canLoginWithEmail')}

+
+

{t('profile.canLoginWithEmail')}

+ +
)} ) : ( @@ -618,6 +639,14 @@ export default function Profile() {

{t('profile.notifications.unavailable')}

)} + + {/* Change Email Modal */} + {showChangeEmailModal && user?.email && ( + setShowChangeEmailModal(false)} + currentEmail={user.email} + /> + )} ); }