import baseUrl from "@/services/api/api.config"; import { Button, Typography, useTheme } from "@mui/material"; import Grid from "@mui/material/Unstable_Grid2"; import { useEffect } from "react"; export default function ModelSelection({ fetchDocuments, fetchChunks }) { const theme = useTheme(); const onHandleClearVariables = async () => { const url = `${baseUrl}/clear/clear_variables`; await fetch(url, { method: "DELETE", headers: { "Content-Type": "application/json" }, }) .then(() => fetchDocuments()) .then(() => fetchChunks()); }; useEffect(() => { fetchDocuments(), fetchChunks(); }, []); return ( <> Do you want to clear Variables? ); }