feat(viewer): show delete icon directly on transcription annotation (#339) #348

Merged
marcel merged 5 commits from feat/issue-339-delete-icon-on-annotation into main 2026-04-26 21:56:38 +02:00
Showing only changes of commit f22596a29d - Show all commits

View File

@@ -120,7 +120,10 @@ async function handleAnnotationDeleteRequest(annotationId: string) {
await deleteBlock(block.id);
} else {
// Annotation has no linked block — delete the annotation directly
await fetch(`/api/documents/${doc.id}/annotations/${annotationId}`, { method: 'DELETE' });
const res = await fetch(`/api/documents/${doc.id}/annotations/${annotationId}`, {
method: 'DELETE'
});
if (!res.ok) throw new Error('Delete annotation failed');
annotationReloadKey++;
}
}