Remove project download functionality from ProjectManager
This commit is contained in:
@@ -14,23 +14,12 @@ import ExportProject from './Export/ExportProject';
|
||||
|
||||
function ProjectManager() {
|
||||
const [projectId, setProjectId] = useAtom(projectIdAtom);
|
||||
const { data, refetch } = useProject(projectId);
|
||||
const { refetch } = useProject(projectId);
|
||||
const { resetSceneNames } = useSceneName(projectId);
|
||||
const { hasCustomNames } = useCustomSceneNames(projectId);
|
||||
const appState = useAppState();
|
||||
const projects = useProjectsList();
|
||||
|
||||
const downloadProjectFile = async () => {
|
||||
if (!data?.projectFile) {
|
||||
return;
|
||||
}
|
||||
|
||||
await fetch('http://127.0.0.1:5174/project-05.tar', {
|
||||
method: 'POST',
|
||||
body: data.projectFile,
|
||||
});
|
||||
};
|
||||
|
||||
return (
|
||||
<div className="flex gap-2 items-center">
|
||||
<Select
|
||||
@@ -59,15 +48,6 @@ function ProjectManager() {
|
||||
>
|
||||
<IconReload className="w-4 h-4" />
|
||||
</Button>
|
||||
<Button
|
||||
onClick={downloadProjectFile}
|
||||
disabled={!data?.projectFile}
|
||||
size="sm"
|
||||
variant="secondary"
|
||||
title="Download raw project file"
|
||||
>
|
||||
Download raw
|
||||
</Button>
|
||||
{hasCustomNames && (
|
||||
<Button
|
||||
onClick={resetSceneNames}
|
||||
|
||||
Reference in New Issue
Block a user