Close zip dialog immediately after import.

This commit is contained in:
Chad Curtis committed 2025-09-26 18:20:10 +00:00
1 parent 2d163e8fed
commit 15567ee4cf
2 files changed
+7 -6

No files matched your search

+4 -6
View File
@@ -302,12 +302,10 @@ export function ProjectImportDialog({
setImportProgress(100);
}
// Close dialog after a short delay
setTimeout(() => {
setIsOpen(false);
handleFileRemove();
setImportProgress(0);
}, 1000);
// Close dialog and reset state immediately
setIsOpen(false);
handleFileRemove();
setImportProgress(0);
} catch (err) {
setError(err instanceof Error ? err.message : 'Failed to import projects');
setImportProgress(0);
+3
View File
@@ -141,6 +141,9 @@ export function ProjectSidebar({
throw new Error('Bulk import not supported in sidebar');
}
// Close dialog before navigation to prevent reopening
setIsZipDialogOpen(false);
// Navigate to the imported project
if (project) {
navigate(`/project/${project.id}`);