This commit is contained in:
2022-05-08 20:23:54 +02:00
parent 49cd724470
commit 5aa6db73be
3 changed files with 11 additions and 5 deletions

View File

@@ -31,8 +31,7 @@ import Home from "./Home";
import Settings from "./Settings";
import { io } from "socket.io-client";
import { RootState, store } from './stores/store';
import { Provider, useDispatch, useSelector } from "react-redux";
import { setTheme } from "./features/settings/settingsSlice";
import { Provider, useSelector } from "react-redux";
const drawerWidth: number = 240;

View File

@@ -64,9 +64,11 @@ export default function Home({ socket }: Props) {
setShowBackdrop(false)
}
if (!status.downloading) {
setShowBackdrop(false)
dispatch(downloading())
}
if (data.status === 'Done!' || data.status === 'Aborted') {
setShowBackdrop(false)
updateInStateMap(data.pid, 'Done!', messageMap, setMessageMap);
updateInStateMap(data.pid, 0, progressMap, setProgressMap);
socket.emit('disk-space')