@konfuzio/document-validation-ui 0.1.26-dev.0 → 0.1.26-dev.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/js/app.js +1 -1
- package/dist/js/app.js.map +1 -1
- package/package.json +1 -1
- package/src/locales/de.json +1 -1
- package/src/locales/en.json +1 -1
- package/src/store/document.js +10 -2
package/package.json
CHANGED
package/src/locales/de.json
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"save": "Speichern",
|
|
21
21
|
"autosaving": "Automatisches Speichern...",
|
|
22
22
|
"saved": "Gespeichert",
|
|
23
|
-
"hide": "
|
|
23
|
+
"hide": "Ausblenden",
|
|
24
24
|
"not_saved": "Konnte nicht gespeichert werden. Versuchen Sie es noch einmal",
|
|
25
25
|
"handover": "Übergeben",
|
|
26
26
|
"handover_document": "Übergabedokument",
|
package/src/locales/en.json
CHANGED
|
@@ -158,5 +158,5 @@
|
|
|
158
158
|
"human_feedback_needed": "Human Feedback needed",
|
|
159
159
|
"label_missing_annotations": "Missing Annotations",
|
|
160
160
|
"accepted_annotations": "Accepted Annotations",
|
|
161
|
-
"edit_ann_content_warning": "If you change the text, the AI cannot use this
|
|
161
|
+
"edit_ann_content_warning": "If you change the text, the AI cannot use this Annotation. You will also invalidate the training data. Try to change the selection to capture the text before adding it manually, or press OK to continue anyway."
|
|
162
162
|
}
|
package/src/store/document.js
CHANGED
|
@@ -304,6 +304,7 @@ const getters = {
|
|
|
304
304
|
let annotations = [];
|
|
305
305
|
let labels = [];
|
|
306
306
|
let processedAnnotationSets = [];
|
|
307
|
+
let processedLabels = [];
|
|
307
308
|
annotationSets.forEach((annotationSet) => {
|
|
308
309
|
labels = [];
|
|
309
310
|
annotationSet.labels.forEach((label) => {
|
|
@@ -333,15 +334,22 @@ const getters = {
|
|
|
333
334
|
}
|
|
334
335
|
if (addLabel) {
|
|
335
336
|
labels.push({ ...label, annotations: labelAnnotations });
|
|
337
|
+
let addProcessedLabel = true;
|
|
338
|
+
processedLabels.forEach((processedLabel) => {
|
|
339
|
+
if (processedLabel.id === label.id) {
|
|
340
|
+
addProcessedLabel = false;
|
|
341
|
+
return;
|
|
342
|
+
}
|
|
343
|
+
});
|
|
344
|
+
processedLabels.push(label);
|
|
336
345
|
}
|
|
337
346
|
annotations.push(...labelAnnotations);
|
|
338
347
|
});
|
|
339
348
|
processedAnnotationSets.push({ ...annotationSet, labels });
|
|
340
349
|
});
|
|
341
|
-
|
|
342
350
|
return {
|
|
343
351
|
annotationSets: processedAnnotationSets,
|
|
344
|
-
labels,
|
|
352
|
+
labels: processedLabels,
|
|
345
353
|
annotations,
|
|
346
354
|
};
|
|
347
355
|
},
|