diff --git a/src/components/BottomBar/Controls.js b/src/components/BottomBar/Controls.js index 648c55bee..323683f0b 100644 --- a/src/components/BottomBar/Controls.js +++ b/src/components/BottomBar/Controls.js @@ -48,10 +48,15 @@ export const Controls = controlsInjector(observer(({ store, history, annotation if (isInProgress) return; setIsInProgress(true); + + const selected = store.annotationStore?.selected; + if(addedCommentThisSession){ + selected?.submissionInProgress(); callback(); } else if((currentComment ?? '').trim()) { e.preventDefault(); + selected?.submissionInProgress(); await commentFormSubmit(); callback(); } else { @@ -74,7 +79,9 @@ export const Controls = controlsInjector(observer(({ store, history, annotation if(store.hasInterface('comments:reject') ?? true) { buttonHandler(e, () => store.rejectAnnotation({}), 'Please enter a comment before rejecting'); } else { - console.log('rejecting'); + const selected = store.annotationStore?.selected; + + selected?.submissionInProgress(); await store.commentStore.commentFormSubmit(); store.rejectAnnotation({}); } @@ -91,6 +98,9 @@ export const Controls = controlsInjector(observer(({ store, history, annotation buttons.push(