"use client"; import { useState } from "react"; import { LoadingOverlay } from "./loadingOverlay"; import { FlakeBadge } from "../flakeBadge/flakeBadge"; import { Typography, Button } from "@mui/material"; // import { FlakeResponse } from "@/api/model"; import { ConfirmVM } from "./confirmVM"; import { Log } from "./log"; import GppMaybeIcon from "@mui/icons-material/GppMaybe"; import { useInspectFlake } from "@/api/default/default"; interface ConfirmProps { flakeUrl: string; flakeAttr: string; handleBack: () => void; } export const Confirm = (props: ConfirmProps) => { const { flakeUrl, handleBack, flakeAttr } = props; const [userConfirmed, setUserConfirmed] = useState(false); const { data, isLoading } = useInspectFlake({ url: flakeUrl, }); return userConfirmed ? ( ) : (
{isLoading && ( } /> )} {data && ( <> To join the clan you must trust the Author )}
); };