import { ScrollArea } from "@/components/ui/scroll-area"; import { Terminal } from "lucide-react"; import { useEffect, useRef } from "react"; import { motion, AnimatePresence } from "motion/react"; interface StatusLogProps { logs: string[]; } export function StatusLog({ logs }: StatusLogProps) { const scrollRef = useRef(null); // Auto-scroll to bottom when logs change useEffect(() => { if (scrollRef.current) { scrollRef.current.scrollIntoView({ behavior: "smooth" }); } }, [logs]); return (
System Log
{logs.map((log, i) => ( {">"} {log} ))}
); }