"use client"; import { useEffect, useState } from "react"; import { HeroTilt } from "./hero-tilt"; const BOOT_LINES = [ "> initializing eldov.win...", "> loading context bus...", "> scanning fleet...", "> ready.", ]; const ROTATING = [ "Self-Hoster", "Bot-Bauer", "Multi-Agent-Fleet-Owner", "Open-Source-Themer", "Casino-Bot-Dev", "Prediction-Market-Trader", ]; export function HeroBanner({ dict, heroImage }: { dict: { kicker: string; title: string; lede: string; cta: { title: string; body: string } }; heroImage: string }) { const [lineIdx, setLineIdx] = useState(0); const [typed, setTyped] = useState(""); const [done, setDone] = useState(false); const [rotIdx, setRotIdx] = useState(0); // Boot-Animation: zeilenweise tippen, 280ms pro Zeile. useEffect(() => { if (lineIdx >= BOOT_LINES.length) { setDone(true); return; } const line = BOOT_LINES[lineIdx]; let i = 0; const id = setInterval(() => { i += 1; setTyped(line.slice(0, i)); if (i >= line.length) { clearInterval(id); setTimeout(() => { setLineIdx((v) => v + 1); setTyped(""); }, 380); } }, 24); return () => clearInterval(id); }, [lineIdx]); // Rotating titles (für die Unterzeile), 2.5s pro Wort. useEffect(() => { if (!done) return; const id = setInterval(() => setRotIdx((v) => (v + 1) % ROTATING.length), 2500); return () => clearInterval(id); }, [done]); return (
{/* Grid-Linien (sehr subtil) */}

{dict.kicker}

{dict.title}

{dict.lede}

{/* Subtle Bottom-Fade zu bg */}
); } function BootSequence({ typed, lineIdx, done, rotIdx }: { typed: string; lineIdx: number; done: boolean; rotIdx: number }) { return (
terminal ~ eldov v0.42.0
{BOOT_LINES.slice(0, lineIdx).map((l, i) => (
{l}
))} {!done ? (
{BOOT_LINES[lineIdx]?.slice(0, typed.length)}  
) : ( <>
{BOOT_LINES[BOOT_LINES.length - 1]}
role:{" "} {ROTATING[rotIdx]}  
since: 2003 (online-handle)
now: building things that survive contact with users
)}
); }