devpulse-radar / register.html
WinLanEm's picture
после нажатия кнопки register, если регистрация прошла успешно должно вылезать модальное окно, где будет поле code, там нужно будет вставить код, который пришел на почту, сделай такое окно
6c90c1e verified
Raw History Blame Contribute Delete
5.83 kB
<!DOCTYPE html>
<html lang="en" class="dark">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Register | DevPulse Radar</title>
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<style>
.card-glass {
backdrop-filter: blur(10px);
background: rgba(255, 255, 255, 0.1);
border: 1px solid rgba(255, 255, 255, 0.1);
}
</style>
</head>
<body class="bg-gray-900 text-gray-100 min-h-screen flex items-center justify-center p-4">
<div class="card-glass rounded-xl p-8 max-w-md w-full">
<div class="text-center mb-8">
<i data-feather="activity" class="w-10 h-10 text-primary mx-auto"></i>
<h1 class="text-3xl font-bold mt-4">Create Account</h1>
<p class="text-gray-400 mt-2">Get started with your developer analytics</p>
</div>
<form id="registerForm" class="space-y-4">
<div>
<label for="name" class="block text-sm font-medium mb-1">Full Name</label>
<input type="text" id="name" name="name" required
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-3 focus:ring-2 focus:ring-primary focus:border-transparent"
placeholder="John Developer">
</div>
<div>
<label for="email" class="block text-sm font-medium mb-1">Email</label>
<input type="email" id="email" name="email" required
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-3 focus:ring-2 focus:ring-primary focus:border-transparent"
placeholder="john@example.com">
</div>
<div>
<label for="password" class="block text-sm font-medium mb-1">Password</label>
<input type="password" id="password" name="password" required
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-3 focus:ring-2 focus:ring-primary focus:border-transparent"
placeholder="••••••••">
</div>
<div>
<label for="confirmPassword" class="block text-sm font-medium mb-1">Confirm Password</label>
<input type="password" id="confirmPassword" name="confirmPassword" required
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-3 focus:ring-2 focus:ring-primary focus:border-transparent"
placeholder="••••••••">
</div>
<button type="submit" class="w-full bg-primary hover:bg-primary/90 py-3 rounded-lg font-medium transition mt-6">
Register
</button>
<p class="text-sm text-gray-400 text-center mt-6">
Already have an account? <a href="login.html" class="text-primary hover:underline">Login here</a>
</p>
</form>
</div>
<!-- Verification Modal -->
<div id="verificationModal" class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 hidden">
<div class="bg-gray-800 rounded-xl p-8 max-w-md w-full mx-4">
<div class="text-center mb-6">
<i data-feather="mail" class="w-12 h-12 text-primary mx-auto"></i>
<h2 class="text-2xl font-bold mt-4">Verify Your Email</h2>
<p class="text-gray-400 mt-2">We've sent a verification code to your email</p>
</div>
<form id="verifyForm">
<div class="space-y-4">
<div>
<label for="code" class="block text-sm font-medium mb-1">Verification Code</label>
<input type="text" id="code" name="code" required
class="w-full bg-gray-700 border border-gray-600 rounded-lg px-4 py-3 focus:ring-2 focus:ring-primary focus:border-transparent"
placeholder="Enter 6-digit code">
</div>
<div class="flex justify-between items-center mt-6">
<button type="button" id="resendCode" class="text-primary hover:underline text-sm">
Resend Code
</button>
<button type="submit" class="bg-primary hover:bg-primary/90 px-6 py-2 rounded-lg font-medium transition">
Verify
</button>
</div>
</div>
</form>
</div>
</div>
<script>
feather.replace();
// Simulate successful registration
document.getElementById('registerForm')?.addEventListener('submit', function(e) {
e.preventDefault();
document.getElementById('verificationModal').classList.remove('hidden');
});
// Verification form handling
document.getElementById('verifyForm')?.addEventListener('submit', function(e) {
e.preventDefault();
const code = document.getElementById('code').value;
if(code.length === 6) {
// Redirect to dashboard on success
window.location.href = 'dashboard.html';
}
});
// Resend code
document.getElementById('resendCode')?.addEventListener('click', function() {
alert('New verification code sent to your email!');
});
</script>
</body>
</html>