Fix: Presentation uploader toast not appearing sometimes when converting notes from breakouts
This commit is contained in:
parent
3f22a22067
commit
ea157a1ab5
@ -58,7 +58,7 @@ const intlMessages = defineMessages({
|
||||
},
|
||||
SCAN_FAILED: {
|
||||
id: 'app.presentationUploder.upload.scanFailed',
|
||||
description: 'error that the file could not be uploaded because scanning failed'
|
||||
description: 'error that the file could not be uploaded because scanning failed',
|
||||
},
|
||||
CONVERSION_TIMEOUT: {
|
||||
id: 'app.presentationUploder.conversion.conversionTimeout',
|
||||
@ -487,11 +487,12 @@ export const PresentationUploaderToast = ({
|
||||
});
|
||||
}, [presentations]);
|
||||
|
||||
let activeToast = Session.getItem('presentationUploaderToastId');
|
||||
const activeToast = Session.getItem('presentationUploaderToastId');
|
||||
|
||||
const showToast = convertingPresentations.length > 0;
|
||||
|
||||
if (showToast && !activeToast) {
|
||||
activeToast = toast.info(() => renderToastList(convertingPresentations, intl), {
|
||||
if (showToast && !toast.isActive(activeToast)) {
|
||||
const convertingPresToast = toast.info(() => renderToastList(convertingPresentations, intl), {
|
||||
hideProgressBar: true,
|
||||
autoClose: false,
|
||||
newestOnTop: true,
|
||||
@ -501,7 +502,7 @@ export const PresentationUploaderToast = ({
|
||||
Session.setItem('presentationUploaderToastId', null);
|
||||
},
|
||||
});
|
||||
Session.setItem('presentationUploaderToastId', activeToast);
|
||||
Session.setItem('presentationUploaderToastId', convertingPresToast);
|
||||
} else if (!showToast && activeToast) {
|
||||
handleDismissToast(activeToast);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user