import React, { useState } from 'react';
import { Mail, Shield, Zap, Heart, Copy, Check, ArrowRight, Github, Coffee, Lock, Menu } from 'lucide-react';
export default function App() {
const [alias, setAlias] = useState('');
const [realEmail, setRealEmail] = useState('');
const [isGenerated, setIsGenerated] = useState(false);
const [copied, setCopied] = useState(false);
const handleGenerate = (e) => {
e.preventDefault();
if (alias && realEmail) {
setIsGenerated(true);
// In a real app, this would send data to the backend
}
};
const copyToClipboard = () => {
const email = `${alias}@tohug.me`;
const textArea = document.createElement("textarea");
textArea.value = email;
document.body.appendChild(textArea);
textArea.select();
try {
document.execCommand('copy');
setCopied(true);
setTimeout(() => setCopied(false), 2000);
} catch (err) {
console.error('Failed to copy', err);
}
document.body.removeChild(textArea);
};
const reset = () => {
setIsGenerated(false);
setAlias('');
setRealEmail('');
};
return (
{/* Navbar */}
{/* Main Content */}
{/* Hero */}
Beta v1.0
Email privacy that feels like a hug.
Stop giving your real email to random websites. Create a warm, safe alias and keep your inbox happy.
{/* The Generator Card */}
{/* Decorative Blob */}
{!isGenerated ? (
) : (
You're protected!
Emails sent to this alias will forward to your real inbox.
{alias}@tohug.me
)}
{/* Features / Why */}
Total Anonymity
When you reply to forwarded emails, we strip your real address so you stay hidden.
Kill Switch
Getting spammed? Delete the alias instantly and the emails stop forever.
Open Source
No shady business. The code is public so you can see exactly how we handle data.
{/* Manny's Corner */}
{/* Placeholder for Manny's Avatar */}
Hey, I'm Manny. 👋
I built tohug.me on a weekend because I was tired of getting newsletters I never signed up for. This service is free, runs on solar energy (mostly), and I promise not to be evil.