@stock-in-the-channel/sinch-vue-components 0.0.371 → 0.0.373
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/index.es.js +18 -14
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -20046,22 +20046,26 @@ const Z1 = window, hi = mn(), Xv = { limit: 20 }, cu = { data: [] }, Zv = {}, em
|
|
|
20046
20046
|
headers: hi.headers,
|
|
20047
20047
|
credentials: "include"
|
|
20048
20048
|
}
|
|
20049
|
-
).then((
|
|
20050
|
-
console.log("Error fetching /products/search-filters",
|
|
20049
|
+
).then((u) => (window.sinch.checkIfNeedsLogin(u), u.json())).catch((u) => {
|
|
20050
|
+
console.log("Error fetching /products/search-filters", u), u.status === 401 && window.sinch.goToLoginPage();
|
|
20051
20051
|
});
|
|
20052
20052
|
this.filterResponse = cu;
|
|
20053
20053
|
const i = ["InStock", "ProductTypes", "PriceBand"];
|
|
20054
|
-
|
|
20055
|
-
|
|
20056
|
-
|
|
20057
|
-
|
|
20058
|
-
|
|
20059
|
-
|
|
20060
|
-
|
|
20061
|
-
|
|
20062
|
-
|
|
20063
|
-
|
|
20064
|
-
|
|
20054
|
+
if (a) {
|
|
20055
|
+
var o = a;
|
|
20056
|
+
this.filterResponse.data = o.filter(
|
|
20057
|
+
(u) => !i.includes(u.name) && u.values.length > 0
|
|
20058
|
+
);
|
|
20059
|
+
}
|
|
20060
|
+
this.filterLoading = !1;
|
|
20061
|
+
const l = Object.entries(this.searchRequest).filter((u) => u[1] !== void 0), s = tk.filter((u) => l.find((d) => d[0] === u.urlParam)).map((u) => u.filterName), c = [];
|
|
20062
|
+
for (const u of this.filterResponse.data) {
|
|
20063
|
+
const d = u.values.find((f) => f.isSelected);
|
|
20064
|
+
s.includes(u.name) && d && c.push(d.name);
|
|
20065
|
+
}
|
|
20066
|
+
if (this.searchRequest.text ? this.resultsFor = [this.searchRequest.text, ...c].join(", ") : this.resultsFor = c.join(", "), this.filterResponseCallBack && this.filterResponseCallBack(), this.searchResponseCallBacks)
|
|
20067
|
+
for (const u of this.searchResponseCallBacks)
|
|
20068
|
+
u(this.searchResults);
|
|
20065
20069
|
},
|
|
20066
20070
|
async configureRequestAndSearch(n, r, a) {
|
|
20067
20071
|
let i;
|
|
@@ -44232,7 +44236,7 @@ query vendorOrderParametersByBasketId($basketId: Int!){
|
|
|
44232
44236
|
const t = A("overview"), n = A(void 0), r = e;
|
|
44233
44237
|
return it(() => {
|
|
44234
44238
|
document.body.classList.add("brand-page"), Uh.$subscribe(() => {
|
|
44235
|
-
n.value = Uh.brands.find((a) => a.name === r.route.params.brandName);
|
|
44239
|
+
n.value = Uh.brands.find((a) => a.name?.toLowerCase() === r.route.params.brandName?.toString().toLowerCase());
|
|
44236
44240
|
});
|
|
44237
44241
|
}), Za(() => {
|
|
44238
44242
|
document.body.classList.remove("brand-page");
|