0% found this document useful (0 votes)
13 views2 pages

Hacker Website - TSX

Uploaded by

bdronyfk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views2 pages

Hacker Website - TSX

Uploaded by

bdronyfk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

import { useState } from 'react'

import { Terminal } from 'lucide-react'

export default function Component() {


const [command, setCommand] = useState('')
const [output, setOutput] = useState<string[]>([])

const handleCommand = (e: React.FormEvent) => {


e.preventDefault()
setOutput([...output, `> ${command}`, 'Access denied. Nice try.'])
setCommand('')
}

return (
<div className="min-h-screen bg-black text-green-500 font-mono p-4">
<header className="flex items-center justify-between mb-8">
<h1 className="text-2xl font-bold">H4ck3r's L41r</h1>
<nav>
<ul className="flex space-x-4">
<li><a href="#" className="hover:text-green-400">Home</a></li>
<li><a href="#" className="hover:text-green-400">About</a></li>
<li><a href="#" className="hover:text-green-400">Projects</a></li>
<li><a href="#" className="hover:text-green-400">Contact</a></li>
</ul>
</nav>
</header>
<main className="space-y-8">
<section>
<h2 className="text-xl mb-4">Welcome to the underground</h2>
<p>This is where code meets chaos. Enter at your own risk.</p>
</section>
<section className="border border-green-500 p-4">
<h2 className="text-xl mb-4 flex items-center">
<Terminal className="mr-2" />
Terminal
</h2>
<div className="bg-gray-900 p-2 h-40 overflow-y-auto mb-2">
{output.map((line, index) => (
<div key={index}>{line}</div>
))}
</div>
<form onSubmit={handleCommand} className="flex">
<input
type="text"
value={command}
onChange={(e) => setCommand(e.target.value)}
className="flex-grow bg-gray-800 text-green-500 p-2 focus:outline-
none"
placeholder="Enter command..."
/>
<button type="submit" className="bg-green-500 text-black px-4 py-2 ml-
2">
Execute
</button>
</form>
</section>
</main>
<footer className="mt-8 text-center text-sm">
<p>&copy; 2024 H4ck3r's L41r. All rights reserved (or are they?)</p>
</footer>
</div>
)
}

You might also like