From 8a1c4c8acb06a3dbdb07e299b87450259c64a82e Mon Sep 17 00:00:00 2001 From: Brandon Davis Date: Tue, 29 Mar 2022 13:23:34 -0400 Subject: [PATCH] Button to boost confidence --- .../components/ConfidenceSubsection.vue | 41 +++++++++++++------ .../components/TrackDetailsPanel.vue | 2 + 2 files changed, 31 insertions(+), 12 deletions(-) diff --git a/client/dive-common/components/ConfidenceSubsection.vue b/client/dive-common/components/ConfidenceSubsection.vue index 910a37584..3ca57bf45 100644 --- a/client/dive-common/components/ConfidenceSubsection.vue +++ b/client/dive-common/components/ConfidenceSubsection.vue @@ -19,6 +19,10 @@ export default defineComponent({ type: Array as PropType<[string, number][]>, required: true, }, + disabled: { + type: Boolean, + default: false, + }, }, setup() { const typeStylingRef = useTypeStyling(); @@ -82,12 +86,35 @@ export default defineComponent({ }" /> - + {{ pair[0] }} - + + {{ pair[1].toFixed(4) }} + + + + Accept {{ pair[0] }} as correct type + + @@ -97,19 +124,9 @@ export default defineComponent({ diff --git a/client/dive-common/components/TrackDetailsPanel.vue b/client/dive-common/components/TrackDetailsPanel.vue index ca9c1af97..f09b9d9ef 100644 --- a/client/dive-common/components/TrackDetailsPanel.vue +++ b/client/dive-common/components/TrackDetailsPanel.vue @@ -332,6 +332,8 @@ export default defineComponent({ :confidence-pairs=" flatten(selectedTrackList.map((t) => t.confidencePairs)).sort((a, b) => b[1] - a[1]) " + :disabled="selectedTrackList.length > 1" + @set-type="selectedTrackList[0].setType($event)" />