RED-5108: use default redaction color for redacted image hints.

This commit is contained in:
Nicoleta Panaghiu 2024-06-18 16:53:59 +03:00
parent d797f57751
commit 244ec6626f

View File

@ -77,6 +77,10 @@ export class AnnotationWrapper implements IListable {
return this.engines.includes(LogEntryEngines.DICTIONARY);
}
get isRedactedImageHint() {
return this.IMAGE_HINT && this.superType === SuperTypes.Redaction;
}
get searchKey(): string {
return this.id;
}
@ -291,7 +295,10 @@ export class AnnotationWrapper implements IListable {
} else {
const colorKey = annotationEntityColorConfig[annotationWrapper.superType];
const defaultColor = annotationDefaultColorConfig[annotationWrapper.superType];
annotationWrapper.color = dictionary ? (dictionary[colorKey] as string) : (defaultColors[defaultColor] as string);
annotationWrapper.color =
dictionary && !annotationWrapper.isRedactedImageHint
? (dictionary[colorKey] as string)
: (defaultColors[defaultColor] as string);
}
annotationWrapper.entry = logEntry;