From 55f62e7197f1f47688571a8c7e83dfaca3b207b5 Mon Sep 17 00:00:00 2001 From: Nicoleta Panaghiu Date: Mon, 25 Mar 2024 11:35:21 +0200 Subject: [PATCH] RED-8812: bold only the selected value, not the entire context. --- .../remove-redaction-dialog.component.html | 14 ++++++-------- .../services/annotation-actions.service.ts | 6 +++--- apps/red-ui/src/assets/i18n/redact/en.json | 2 +- 3 files changed, 10 insertions(+), 12 deletions(-) diff --git a/apps/red-ui/src/app/modules/file-preview/dialogs/remove-redaction-dialog/remove-redaction-dialog.component.html b/apps/red-ui/src/app/modules/file-preview/dialogs/remove-redaction-dialog/remove-redaction-dialog.component.html index 1e5660e75..93fe7d3c9 100644 --- a/apps/red-ui/src/app/modules/file-preview/dialogs/remove-redaction-dialog/remove-redaction-dialog.component.html +++ b/apps/red-ui/src/app/modules/file-preview/dialogs/remove-redaction-dialog/remove-redaction-dialog.component.html @@ -23,17 +23,16 @@ @@ -43,7 +42,7 @@ diff --git a/apps/red-ui/src/app/modules/file-preview/services/annotation-actions.service.ts b/apps/red-ui/src/app/modules/file-preview/services/annotation-actions.service.ts index 23a115d14..4596c62fd 100644 --- a/apps/red-ui/src/app/modules/file-preview/services/annotation-actions.service.ts +++ b/apps/red-ui/src/app/modules/file-preview/services/annotation-actions.service.ts @@ -354,15 +354,15 @@ export class AnnotationActionsService { let text: string; if (annotation.hasTextAfter) { text = getFirstRelevantTextPart(annotation.textAfter, 'FORWARD'); - return text ? (annotation.value + text).trim() : annotation.value; + return text ? (`${annotation.value}` + text).trim() : `${annotation.value}`; } if (annotation.hasTextBefore) { text = getFirstRelevantTextPart(annotation.textBefore, 'BACKWARD'); - return text ? (text + annotation.value).trim() : annotation.value; + return text ? (text + `${annotation.value}`).trim() : `${annotation.value}`; } - return annotation.value; + return `${annotation.value}`; } async #extractTextAndPositions(annotationId: string) { diff --git a/apps/red-ui/src/assets/i18n/redact/en.json b/apps/red-ui/src/assets/i18n/redact/en.json index 4aa3633a8..a7ed9515d 100644 --- a/apps/red-ui/src/assets/i18n/redact/en.json +++ b/apps/red-ui/src/assets/i18n/redact/en.json @@ -2047,7 +2047,7 @@ "comment": "Comment", "comment-placeholder": "Add remarks or mentions...", "list-item": "{text}", - "list-item-false-positive": "{text} as {type} in the context: {context}", + "list-item-false-positive": "{text} as {type} in the context: ", "list-item-false-recommendation": "{text} as {type}", "options": { "do-not-recommend": {