Skip to content

Commit 8e90195

Browse files
authored
fix: BROS-633: Fix Labeling Stream with missing buttons (#8953)
Co-authored-by: hlomzik <hlomzik@users.noreply.github.com>
1 parent 671812a commit 8e90195

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

web/libs/editor/src/components/AnnotationsCarousel/AnnotationButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ export const AnnotationButton = observer(
101101

102102
if (!selected) {
103103
if (type === "prediction") {
104-
annotationStore.selectPrediction(id);
104+
annotationStore.selectPrediction(id, { exitViewAll: true });
105105
} else {
106106
annotationStore.selectAnnotation(id, { exitViewAll: true });
107107
}

web/libs/editor/src/stores/Annotation/store.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ const AnnotationStoreModel = types
5252
},
5353

5454
get viewingAll() {
55+
// Even if we have View All flag stored as true, but we are in environment without it
56+
// or if we are not ready yet — don't go into View All mode, it will be broken.
57+
if (!self.initialized) return false;
58+
if (!self.store.hasInterface("annotations:view-all")) return false;
5559
return self.viewingAllAnnotations;
5660
},
5761
}))

0 commit comments

Comments
 (0)