diff --git a/src/components/molecules/BrowserRecordingSave.tsx b/src/components/molecules/BrowserRecordingSave.tsx new file mode 100644 index 00000000..e7957697 --- /dev/null +++ b/src/components/molecules/BrowserRecordingSave.tsx @@ -0,0 +1,49 @@ +import React from 'react' +import { Paper, Grid, IconButton, Button } from '@mui/material'; +import { SaveRecording } from "./SaveRecording"; +import { Circle, Add, Logout, Clear } from "@mui/icons-material"; +import { useGlobalInfoStore } from '../../context/globalInfo'; +import { stopRecording } from "../../api/recording"; +import { Link, useLocation, useNavigate } from 'react-router-dom'; + + +const BrowserRecordingSave = () => { + const { recordingName, browserId, setBrowserId, notify } = useGlobalInfoStore(); + const navigate = useNavigate(); + + const goToMainMenu = async () => { + if (browserId) { + await stopRecording(browserId); + notify('warning', 'Current Recording was terminated'); + setBrowserId(null); + } + navigate('/'); + }; + + return ( + + +
+ + +
+
+
+ ) +} + +export default BrowserRecordingSave \ No newline at end of file