import Image from "next/image"; import Logo from "@/assets/logo.svg"; import { Skeleton } from "@/components/ui/skeleton"; import { Loader2, X } from "lucide-react"; import { Dialog, DialogContent, DialogDescription, DialogHeader, DialogTitle, } from "@/components/ui/dialog"; import { useEffect, useState } from "react"; export default function Loading({ didFail = false, withNav = false, text = "", description = "", }: { didFail?: boolean; withNav?: boolean; text?: string; description?: string; }) { const [open, setOpen] = useState(false); useEffect(() => { if (text) { setOpen(true); } }, [text]); return (
{didFail ? ( <> Failed to start server. ) : ( <> {text} )} {didFail ? ( Try again in a minute, or contact @ishaandey_ on Twitter/X if it still doesn't work. ) : description ? ( {description} ) : null} {withNav ? (
Logo
) : null}
Explorer
Loading...
); }