(feat:settings/docs) confirm on delete

This commit is contained in:
ManishMadan2882
2025-01-28 04:50:28 +05:30
parent 379dd011ff
commit 83e4023c19
8 changed files with 62 additions and 19 deletions

View File

@@ -23,14 +23,14 @@ function Upload({
isOnboarding,
renderTab = null,
close,
onSuccessfulUpload,
onSuccessfulUpload = () => undefined,
}: {
receivedFile: File[];
setModalState: (state: ActiveState) => void;
isOnboarding: boolean;
renderTab: string | null;
close: () => void;
onSuccessfulUpload: () => void;
onSuccessfulUpload?: () => void;
}) {
const [docName, setDocName] = useState(receivedFile[0]?.name);
const [urlName, setUrlName] = useState('');
@@ -220,7 +220,7 @@ function Upload({
setfiles([]);
setProgress(undefined);
setModalState('INACTIVE');
onSuccessfulUpload();
onSuccessfulUpload?.();
}
} else if (data.status == 'PROGRESS') {
setProgress(