refactor(auth): remove OTP flows from login/register/reset

This commit is contained in:
tinkle-community
2026-03-05 18:55:36 +08:00
parent fa664ccae3
commit 73f1fe105d
11 changed files with 210 additions and 1207 deletions

View File

@@ -649,7 +649,6 @@ export const translations = {
passwordRuleMatch: 'Passwords match',
passwordNotMeetRequirements:
'Password does not meet the security requirements',
otpPlaceholder: '000000',
loginTitle: 'Sign in to your account',
registerTitle: 'Create a new account',
loginButton: 'Sign In',
@@ -661,7 +660,6 @@ export const translations = {
loginNow: 'Sign in now',
forgotPassword: 'Forgot password?',
rememberMe: 'Remember me',
otpCode: 'OTP Code',
resetPassword: 'Reset Password',
resetPasswordTitle: 'Reset your password',
newPassword: 'New Password',
@@ -671,33 +669,11 @@ export const translations = {
'Password reset successful! Please login with your new password',
resetPasswordFailed: 'Password reset failed',
backToLogin: 'Back to Login',
scanQRCode: 'Scan QR Code',
enterOTPCode: 'Enter 6-digit OTP code',
verifyOTP: 'Verify OTP',
setupTwoFactor: 'Set up two-factor authentication',
setupTwoFactorDesc:
'Follow the steps below to secure your account with Google Authenticator',
scanQRCodeInstructions:
'Scan this QR code with Google Authenticator or Authy',
otpSecret: 'Or enter this secret manually:',
qrCodeHint: 'QR code (if scanning fails, use the secret below):',
authStep1Title: 'Step 1: Install Google Authenticator',
authStep1Desc:
'Download and install Google Authenticator from your app store',
authStep2Title: 'Step 2: Add account',
authStep2Desc: 'Tap "+", then choose "Scan QR code" or "Enter a setup key"',
authStep3Title: 'Step 3: Verify setup',
authStep3Desc: 'After setup, continue to enter the 6-digit code',
setupCompleteContinue: 'I have completed setup, continue',
copy: 'Copy',
completeRegistration: 'Complete Registration',
completeRegistrationSubtitle: 'to complete registration',
loginSuccess: 'Login successful',
registrationSuccess: 'Registration successful',
loginFailed: 'Login failed. Please check your email and password.',
registrationFailed: 'Registration failed. Please try again.',
verificationFailed:
'OTP verification failed. Please check the code and try again.',
sessionExpired: 'Session expired, please login again',
invalidCredentials: 'Invalid email or password',
weak: 'Weak',
@@ -1866,7 +1842,6 @@ export const translations = {
passwordRuleSpecial: '至少 1 个特殊字符(@#$%!&*?',
passwordRuleMatch: '两次密码一致',
passwordNotMeetRequirements: '密码不符合安全要求',
otpPlaceholder: '000000',
loginTitle: '登录到您的账户',
registerTitle: '创建新账户',
loginButton: '登录',
@@ -1886,30 +1861,11 @@ export const translations = {
resetPasswordSuccess: '密码重置成功!请使用新密码登录',
resetPasswordFailed: '密码重置失败',
backToLogin: '返回登录',
otpCode: 'OTP验证码',
scanQRCode: '扫描二维码',
enterOTPCode: '输入6位OTP验证码',
verifyOTP: '验证OTP',
setupTwoFactor: '设置双因素认证',
setupTwoFactorDesc: '请按以下步骤设置Google验证器以保护您的账户安全',
scanQRCodeInstructions: '使用Google Authenticator或Authy扫描此二维码',
otpSecret: '或手动输入此密钥:',
qrCodeHint: '二维码(如果无法扫描,请使用下方密钥):',
authStep1Title: '步骤1下载Google Authenticator',
authStep1Desc: '在手机应用商店下载并安装Google Authenticator应用',
authStep2Title: '步骤2添加账户',
authStep2Desc: '在应用中点击“+”,选择“扫描二维码”或“手动输入密钥”',
authStep3Title: '步骤3验证设置',
authStep3Desc: '设置完成后点击下方按钮输入6位验证码',
setupCompleteContinue: '我已完成设置,继续',
copy: '复制',
completeRegistration: '完成注册',
completeRegistrationSubtitle: '以完成注册',
loginSuccess: '登录成功',
registrationSuccess: '注册成功',
loginFailed: '登录失败,请检查您的邮箱和密码。',
registrationFailed: '注册失败,请重试。',
verificationFailed: 'OTP 验证失败,请检查验证码后重试。',
sessionExpired: '登录已过期,请重新登录',
invalidCredentials: '邮箱或密码错误',
weak: '弱',
@@ -3020,7 +2976,6 @@ export const translations = {
passwordRuleSpecial: 'Minimal 1 karakter khusus (@#$%!&*?)',
passwordRuleMatch: 'Kata sandi cocok',
passwordNotMeetRequirements: 'Kata sandi tidak memenuhi persyaratan keamanan',
otpPlaceholder: '000000',
loginTitle: 'Masuk ke akun Anda',
registerTitle: 'Buat akun baru',
loginButton: 'Masuk',
@@ -3032,7 +2987,6 @@ export const translations = {
loginNow: 'Masuk sekarang',
forgotPassword: 'Lupa kata sandi?',
rememberMe: 'Ingat saya',
otpCode: 'Kode OTP',
resetPassword: 'Reset Kata Sandi',
resetPasswordTitle: 'Reset kata sandi Anda',
newPassword: 'Kata Sandi Baru',
@@ -3041,29 +2995,11 @@ export const translations = {
resetPasswordSuccess: 'Kata sandi berhasil direset! Silakan masuk dengan kata sandi baru',
resetPasswordFailed: 'Gagal mereset kata sandi',
backToLogin: 'Kembali ke Login',
scanQRCode: 'Pindai Kode QR',
enterOTPCode: 'Masukkan kode OTP 6 digit',
verifyOTP: 'Verifikasi OTP',
setupTwoFactor: 'Atur autentikasi dua faktor',
setupTwoFactorDesc: 'Ikuti langkah-langkah di bawah untuk mengamankan akun Anda dengan Google Authenticator',
scanQRCodeInstructions: 'Pindai kode QR ini dengan Google Authenticator atau Authy',
otpSecret: 'Atau masukkan kunci ini secara manual:',
qrCodeHint: 'Kode QR (jika pemindaian gagal, gunakan kunci di bawah):',
authStep1Title: 'Langkah 1: Instal Google Authenticator',
authStep1Desc: 'Unduh dan instal Google Authenticator dari toko aplikasi',
authStep2Title: 'Langkah 2: Tambahkan akun',
authStep2Desc: 'Ketuk "+", lalu pilih "Pindai kode QR" atau "Masukkan kunci pengaturan"',
authStep3Title: 'Langkah 3: Verifikasi pengaturan',
authStep3Desc: 'Setelah pengaturan, lanjutkan untuk memasukkan kode 6 digit',
setupCompleteContinue: 'Saya telah menyelesaikan pengaturan, lanjutkan',
copy: 'Salin',
completeRegistration: 'Selesaikan Pendaftaran',
completeRegistrationSubtitle: 'untuk menyelesaikan pendaftaran',
loginSuccess: 'Berhasil masuk',
registrationSuccess: 'Berhasil mendaftar',
loginFailed: 'Gagal masuk. Periksa email dan kata sandi Anda.',
registrationFailed: 'Gagal mendaftar. Silakan coba lagi.',
verificationFailed: 'Verifikasi OTP gagal. Periksa kode dan coba lagi.',
sessionExpired: 'Sesi berakhir, silakan masuk kembali',
invalidCredentials: 'Email atau kata sandi salah',
weak: 'Lemah',