diff --git a/src/pages/Login.tsx b/src/pages/Login.tsx index 06139f2..172ca0f 100644 --- a/src/pages/Login.tsx +++ b/src/pages/Login.tsx @@ -27,9 +27,6 @@ export default function Login() { // Extract referral code from URL const referralCode = searchParams.get('ref') || ''; - const [activeTab, setActiveTab] = useState<'telegram' | 'email'>(() => - referralCode ? 'email' : 'telegram', - ); const [authMode, setAuthMode] = useState<'login' | 'register'>(() => referralCode ? 'register' : 'login', ); @@ -96,12 +93,6 @@ export default function Login() { } }, [referralCode, emailAuthConfig, botUsername]); - // If email auth is disabled but we initially set to email tab, switch back to telegram - useEffect(() => { - if (!isEmailAuthEnabled && activeTab === 'email') { - setActiveTab('telegram'); - } - }, [isEmailAuthEnabled, activeTab]); const appName = branding ? branding.name : import.meta.env.VITE_APP_NAME || 'VPN'; const appLogo = branding?.logo_letter || import.meta.env.VITE_APP_LOGO || 'V'; const logoUrl = branding ? brandingApi.getLogoUrl(branding) : null; @@ -336,194 +327,175 @@ export default function Login() { ) : ( /* Card */
{t('auth.registerHint')}
+ {/* Telegram auth section */} +{t('auth.registerHint')}
- {isLoading && isTelegramWebApp ? ( -{t('auth.authenticating')}
-{t('auth.authenticating')}
+