wt-front-shared 1.0.69 → 1.0.70
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/esm2020/lib/core/+state/static-data/static-data.facade.mjs +1 -1
- package/esm2020/lib/core/+state/static-data/static-data.selectors.mjs +20 -3
- package/fesm2015/wt-front-shared.mjs +19 -2
- package/fesm2015/wt-front-shared.mjs.map +1 -1
- package/fesm2020/wt-front-shared.mjs +19 -2
- package/fesm2020/wt-front-shared.mjs.map +1 -1
- package/lib/core/+state/static-data/static-data.facade.d.ts +1 -1
- package/lib/core/+state/static-data/static-data.selectors.d.ts +1 -1
- package/package.json +1 -1
|
@@ -6165,8 +6165,25 @@ const getStaticData = (contentType, subSection, where) => createSelector(getStat
|
|
|
6165
6165
|
let result = true;
|
|
6166
6166
|
Object.keys(where)
|
|
6167
6167
|
.forEach(whereItem => {
|
|
6168
|
-
|
|
6169
|
-
|
|
6168
|
+
// item[whereItem] is not Array
|
|
6169
|
+
if (!Array.isArray(item[whereItem])) {
|
|
6170
|
+
const fieldValue = item[whereItem];
|
|
6171
|
+
if (!Array.isArray(where[whereItem])) {
|
|
6172
|
+
result = fieldValue === where[whereItem];
|
|
6173
|
+
}
|
|
6174
|
+
else {
|
|
6175
|
+
const whereValues = where[whereItem];
|
|
6176
|
+
result = !!whereValues.includes(fieldValue);
|
|
6177
|
+
}
|
|
6178
|
+
}
|
|
6179
|
+
else {
|
|
6180
|
+
// item[whereItem] is Array
|
|
6181
|
+
if (!Array.isArray(where[whereItem])) {
|
|
6182
|
+
result = item[whereItem].includes(where[whereItem]);
|
|
6183
|
+
}
|
|
6184
|
+
else {
|
|
6185
|
+
result = where[whereItem].every(subItem => item[whereItem].includes(subItem));
|
|
6186
|
+
}
|
|
6170
6187
|
}
|
|
6171
6188
|
});
|
|
6172
6189
|
return result;
|