@sinequa/atomic-angular 1.5.0 → 1.5.1
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.
|
@@ -8711,6 +8711,19 @@ function injectAggregationBase(refs) {
|
|
|
8711
8711
|
}
|
|
8712
8712
|
});
|
|
8713
8713
|
}
|
|
8714
|
+
else if (Array.isArray(currentFilters.values) && currentFilters.values.length) {
|
|
8715
|
+
// multiple values stored as a string array, e.g. { values: ["alice_martin", "caroline_dubois"] }
|
|
8716
|
+
// (no `filters` sub-array and no single `value`) — mark each matching item as selected
|
|
8717
|
+
currentFilters.values.forEach((value) => {
|
|
8718
|
+
const found = currentItems.find((item) => item.value?.toString().toLocaleLowerCase() === value?.toString().toLocaleLowerCase());
|
|
8719
|
+
if (!found) {
|
|
8720
|
+
currentItems.unshift({ value, display: value, $selected: true });
|
|
8721
|
+
}
|
|
8722
|
+
else {
|
|
8723
|
+
found.$selected = true;
|
|
8724
|
+
}
|
|
8725
|
+
});
|
|
8726
|
+
}
|
|
8714
8727
|
else if (currentFilters.value) {
|
|
8715
8728
|
const found = currentItems.find((item) => item.value?.toString().toLocaleLowerCase() === currentFilters.value?.toLocaleLowerCase());
|
|
8716
8729
|
if (!found) {
|