diff --git a/src/components/App.tsx b/src/components/App.tsx index 9e920f0..8fdd670 100644 --- a/src/components/App.tsx +++ b/src/components/App.tsx @@ -2,25 +2,40 @@ import React, { useState } from "react" import RetakesConfig from "../types/RetakesConfig" import AllDecks from "./AllDecks" import MenuBar from "./MenuBar" +import Modal from "./Modal" const App: React.FC = () => { const [retakesConfig,setRetakesConfig] = useState(new RetakesConfig()) + const [showExport,setShowExport] = useState(false) + const [exportText,setExportText] = useState("") return (
{ - const exportString = retakesConfig.toCvar() - console.log(exportString) + setExportText(retakesConfig.toCvar()) + setShowExport(true) }} onExportJson={()=>{ - const jsonString = JSON.stringify(retakesConfig) - console.log(jsonString) - }} + setExportText(JSON.stringify(retakesConfig)) + setShowExport(true) + }} /> setRetakesConfig(newConfig)} /> + + setShowExport(false)}> +
+