WIP
This commit is contained in:
113
frontend/verify-email.html
Normal file
113
frontend/verify-email.html
Normal file
@ -0,0 +1,113 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Email Verification - Bookmark Manager</title>
|
||||
<link rel="stylesheet" href="styles.css">
|
||||
<link rel="stylesheet" href="auth-styles.css">
|
||||
</head>
|
||||
|
||||
<body class="auth-body">
|
||||
<div class="auth-container">
|
||||
<div class="auth-card">
|
||||
<div class="auth-header">
|
||||
<h1>Email Verification</h1>
|
||||
</div>
|
||||
|
||||
<!-- Success State -->
|
||||
<div id="verificationSuccess" class="verification-state" style="display: none;">
|
||||
<div class="verification-icon success">
|
||||
<span class="icon">✅</span>
|
||||
</div>
|
||||
<div class="verification-content">
|
||||
<h2>Email Verified Successfully!</h2>
|
||||
<p>Your email address has been verified. You can now sign in to your account.</p>
|
||||
</div>
|
||||
<div class="auth-footer">
|
||||
<a href="login.html" class="btn btn-primary btn-full">Sign In to Your Account</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Error State -->
|
||||
<div id="verificationError" class="verification-state" style="display: none;">
|
||||
<div class="verification-icon error">
|
||||
<span class="icon">❌</span>
|
||||
</div>
|
||||
<div class="verification-content">
|
||||
<h2>Verification Failed</h2>
|
||||
<p id="errorDescription">The verification link is invalid or has expired.</p>
|
||||
</div>
|
||||
<div class="auth-footer">
|
||||
<button id="resendVerificationBtn" class="btn btn-primary btn-full">
|
||||
<span class="btn-text">Resend Verification Email</span>
|
||||
<span class="btn-loading" style="display: none;">
|
||||
<span class="loading-spinner"></span>
|
||||
Sending...
|
||||
</span>
|
||||
</button>
|
||||
<a href="login.html" class="btn btn-secondary btn-full">Back to Sign In</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Loading State -->
|
||||
<div id="verificationLoading" class="verification-state">
|
||||
<div class="verification-icon loading">
|
||||
<span class="loading-spinner large"></span>
|
||||
</div>
|
||||
<div class="verification-content">
|
||||
<h2>Verifying Your Email</h2>
|
||||
<p>Please wait while we verify your email address...</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Resend Success -->
|
||||
<div id="resendSuccess" class="verification-state" style="display: none;">
|
||||
<div class="verification-icon success">
|
||||
<span class="icon">📧</span>
|
||||
</div>
|
||||
<div class="verification-content">
|
||||
<h2>Verification Email Sent</h2>
|
||||
<p>We've sent a new verification email to your address. Please check your inbox and click the verification link.</p>
|
||||
</div>
|
||||
<div class="auth-footer">
|
||||
<a href="login.html" class="btn btn-secondary btn-full">Back to Sign In</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="auth-error" id="authError" style="display: none;" role="alert" aria-live="polite">
|
||||
<div class="error-content">
|
||||
<span class="error-icon">⚠️</span>
|
||||
<span class="error-message" id="errorMessage"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="auth-script.js"></script>
|
||||
<script>
|
||||
// Check for error message in URL parameters
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const errorMessage = urlParams.get('error');
|
||||
|
||||
if (errorMessage) {
|
||||
// Hide loading state and show error
|
||||
document.getElementById('verificationLoading').style.display = 'none';
|
||||
document.getElementById('verificationError').style.display = 'block';
|
||||
|
||||
// Update error description
|
||||
const errorDescription = document.getElementById('errorDescription');
|
||||
errorDescription.textContent = decodeURIComponent(errorMessage);
|
||||
|
||||
// Clear URL parameters to clean up the URL
|
||||
if (window.history.replaceState) {
|
||||
window.history.replaceState({}, document.title, window.location.pathname);
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user