@arsedizioni/ars-utils 21.1.73 → 21.1.75
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.
|
@@ -1299,7 +1299,18 @@ class ClipperDocumentComponent extends ClipperDocumentManager {
|
|
|
1299
1299
|
this.dialogService.error(r.message);
|
|
1300
1300
|
else {
|
|
1301
1301
|
if (r.value?.items && r.value?.items.length > 0) {
|
|
1302
|
-
|
|
1302
|
+
r.value.items[0].anchors.forEach(n => {
|
|
1303
|
+
let score = n.score;
|
|
1304
|
+
if (score > 7)
|
|
1305
|
+
score -= 7;
|
|
1306
|
+
else if (score > 5)
|
|
1307
|
+
score -= 5;
|
|
1308
|
+
else if (score > 3)
|
|
1309
|
+
score -= 3;
|
|
1310
|
+
n.score = score;
|
|
1311
|
+
n.veryRelevant = score > 0.7;
|
|
1312
|
+
});
|
|
1313
|
+
this.relevants.items = r.value.items[0].anchors;
|
|
1303
1314
|
this.hasRelevants.set(this.relevants.items?.length > 0);
|
|
1304
1315
|
}
|
|
1305
1316
|
this.handleRelevantsPaneVisibility();
|