@getlupa/client 1.8.5 → 1.8.7
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/lupaSearch.iife.js +113 -89
- package/dist/lupaSearch.js +113 -89
- package/dist/lupaSearch.mjs +113 -89
- package/dist/lupaSearch.umd.js +113 -89
- package/dist/style.css +1 -1
- package/package.json +2 -2
package/dist/lupaSearch.umd.js
CHANGED
|
@@ -6403,6 +6403,37 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
6403
6403
|
const normalizedInput = getNormalizedString(input);
|
|
6404
6404
|
return possibleValues.some((v) => getNormalizedString(v) === normalizedInput);
|
|
6405
6405
|
};
|
|
6406
|
+
const levenshteinDistance = (s = "", t = "") => {
|
|
6407
|
+
if (!(s == null ? void 0 : s.length)) {
|
|
6408
|
+
return t.length;
|
|
6409
|
+
}
|
|
6410
|
+
if (!(t == null ? void 0 : t.length)) {
|
|
6411
|
+
return s.length;
|
|
6412
|
+
}
|
|
6413
|
+
const arr = [];
|
|
6414
|
+
for (let i = 0; i <= t.length; i++) {
|
|
6415
|
+
arr[i] = [i];
|
|
6416
|
+
for (let j = 1; j <= s.length; j++) {
|
|
6417
|
+
arr[i][j] = i === 0 ? j : Math.min(
|
|
6418
|
+
arr[i - 1][j] + 1,
|
|
6419
|
+
arr[i][j - 1] + 1,
|
|
6420
|
+
arr[i - 1][j - 1] + (s[j - 1] === t[i - 1] ? 0 : 1)
|
|
6421
|
+
);
|
|
6422
|
+
}
|
|
6423
|
+
}
|
|
6424
|
+
return arr[t.length][s.length];
|
|
6425
|
+
};
|
|
6426
|
+
const findClosestStringValue = (input, possibleValues, key) => {
|
|
6427
|
+
var _a;
|
|
6428
|
+
const directMatch = possibleValues.find((v) => v[key] === input);
|
|
6429
|
+
if (directMatch) {
|
|
6430
|
+
return directMatch;
|
|
6431
|
+
}
|
|
6432
|
+
const distances = possibleValues.map((v) => levenshteinDistance(`${v[key]}`, input));
|
|
6433
|
+
const minDistance = Math.min(...distances);
|
|
6434
|
+
const closestValue = (_a = possibleValues.filter((_, i) => distances[i] === minDistance)) == null ? void 0 : _a[0];
|
|
6435
|
+
return closestValue;
|
|
6436
|
+
};
|
|
6406
6437
|
const initAnalyticsTracking = (analyticsOptions) => {
|
|
6407
6438
|
try {
|
|
6408
6439
|
if (analyticsOptions == null ? void 0 : analyticsOptions.enabled) {
|
|
@@ -7812,7 +7843,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
7812
7843
|
});
|
|
7813
7844
|
const _hoisted_1$1c = { id: "lupa-search-box-input-container" };
|
|
7814
7845
|
const _hoisted_2$P = { class: "lupa-input-clear" };
|
|
7815
|
-
const _hoisted_3$
|
|
7846
|
+
const _hoisted_3$A = { id: "lupa-search-box-input" };
|
|
7816
7847
|
const _hoisted_4$s = ["value"];
|
|
7817
7848
|
const _hoisted_5$g = ["aria-label", "placeholder"];
|
|
7818
7849
|
const _hoisted_6$9 = {
|
|
@@ -7907,7 +7938,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
7907
7938
|
onClick: clear2
|
|
7908
7939
|
}, null, 2)
|
|
7909
7940
|
]),
|
|
7910
|
-
createBaseVNode("div", _hoisted_3$
|
|
7941
|
+
createBaseVNode("div", _hoisted_3$A, [
|
|
7911
7942
|
createBaseVNode("input", {
|
|
7912
7943
|
class: "lupa-hint",
|
|
7913
7944
|
"aria-hidden": "true",
|
|
@@ -8088,7 +8119,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8088
8119
|
"data-cy": "lupa-suggestion-value",
|
|
8089
8120
|
class: "lupa-suggestion-value"
|
|
8090
8121
|
};
|
|
8091
|
-
const _hoisted_3$
|
|
8122
|
+
const _hoisted_3$z = {
|
|
8092
8123
|
key: 2,
|
|
8093
8124
|
class: "lupa-suggestion-facet",
|
|
8094
8125
|
"data-cy": "lupa-suggestion-facet"
|
|
@@ -8138,7 +8169,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8138
8169
|
"data-cy": "lupa-suggestion-value",
|
|
8139
8170
|
innerHTML: _ctx.suggestion.displayHighlight
|
|
8140
8171
|
}, null, 8, _hoisted_1$18)) : (openBlock(), createElementBlock("div", _hoisted_2$N, toDisplayString(_ctx.suggestion.display), 1)),
|
|
8141
|
-
_ctx.suggestion.facet ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
8172
|
+
_ctx.suggestion.facet ? (openBlock(), createElementBlock("div", _hoisted_3$z, [
|
|
8142
8173
|
createBaseVNode("span", _hoisted_4$r, toDisplayString(facetLabel.value), 1),
|
|
8143
8174
|
createBaseVNode("span", _hoisted_5$f, toDisplayString(_ctx.suggestion.facet.title), 1)
|
|
8144
8175
|
])) : createCommentVNode("", true)
|
|
@@ -8552,7 +8583,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8552
8583
|
});
|
|
8553
8584
|
const _hoisted_1$11 = ["innerHTML"];
|
|
8554
8585
|
const _hoisted_2$K = { key: 0 };
|
|
8555
|
-
const _hoisted_3$
|
|
8586
|
+
const _hoisted_3$y = { key: 1 };
|
|
8556
8587
|
const _hoisted_4$q = { class: "lupa-search-box-custom-label" };
|
|
8557
8588
|
const _hoisted_5$e = { class: "lupa-search-box-custom-text" };
|
|
8558
8589
|
const _sfc_main$16 = /* @__PURE__ */ defineComponent({
|
|
@@ -8585,7 +8616,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8585
8616
|
key: 1,
|
|
8586
8617
|
class: [className.value, "lupa-search-box-product-custom"]
|
|
8587
8618
|
}, toHandlers(_ctx.options.action ? { click: handleClick } : {}, true)), [
|
|
8588
|
-
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$K, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
8619
|
+
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$K, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$y, [
|
|
8589
8620
|
createBaseVNode("div", _hoisted_4$q, toDisplayString(label.value), 1),
|
|
8590
8621
|
createBaseVNode("div", _hoisted_5$e, toDisplayString(text.value), 1)
|
|
8591
8622
|
]))
|
|
@@ -8810,7 +8841,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8810
8841
|
});
|
|
8811
8842
|
const _hoisted_1$$ = { class: "lupa-search-box-add-to-cart-wrapper" };
|
|
8812
8843
|
const _hoisted_2$J = { class: "lupa-search-box-product-addtocart" };
|
|
8813
|
-
const _hoisted_3$
|
|
8844
|
+
const _hoisted_3$x = ["onClick", "disabled"];
|
|
8814
8845
|
const _sfc_main$14 = /* @__PURE__ */ defineComponent({
|
|
8815
8846
|
__name: "SearchBoxProductAddToCart",
|
|
8816
8847
|
props: {
|
|
@@ -8846,7 +8877,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8846
8877
|
"data-cy": "lupa-add-to-cart",
|
|
8847
8878
|
type: "button",
|
|
8848
8879
|
disabled: !inStockValue.value || loading.value
|
|
8849
|
-
}, toDisplayString(label.value), 11, _hoisted_3$
|
|
8880
|
+
}, toDisplayString(label.value), 11, _hoisted_3$x)
|
|
8850
8881
|
])
|
|
8851
8882
|
]);
|
|
8852
8883
|
};
|
|
@@ -8925,7 +8956,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8925
8956
|
}));
|
|
8926
8957
|
const _hoisted_1$_ = ["href"];
|
|
8927
8958
|
const _hoisted_2$I = { class: "lupa-search-box-product-image-section" };
|
|
8928
|
-
const _hoisted_3$
|
|
8959
|
+
const _hoisted_3$w = { class: "lupa-search-box-product-details-section" };
|
|
8929
8960
|
const _hoisted_4$p = {
|
|
8930
8961
|
key: 0,
|
|
8931
8962
|
class: "lupa-search-box-product-add-to-cart-section"
|
|
@@ -8998,7 +9029,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
8998
9029
|
}, null, 8, ["item", "element", "labels", "link"]);
|
|
8999
9030
|
}), 128))
|
|
9000
9031
|
]),
|
|
9001
|
-
createBaseVNode("div", _hoisted_3$
|
|
9032
|
+
createBaseVNode("div", _hoisted_3$w, [
|
|
9002
9033
|
(openBlock(true), createElementBlock(Fragment, null, renderList(detailElements.value, (element) => {
|
|
9003
9034
|
return openBlock(), createBlock(_sfc_main$13, {
|
|
9004
9035
|
class: "lupa-search-box-product-element",
|
|
@@ -9242,7 +9273,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9242
9273
|
id: "lupa-search-box-panel"
|
|
9243
9274
|
};
|
|
9244
9275
|
const _hoisted_2$H = ["data-cy"];
|
|
9245
|
-
const _hoisted_3$
|
|
9276
|
+
const _hoisted_3$v = {
|
|
9246
9277
|
key: 0,
|
|
9247
9278
|
class: "lupa-panel-title"
|
|
9248
9279
|
};
|
|
@@ -9394,7 +9425,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9394
9425
|
]),
|
|
9395
9426
|
"data-cy": "lupa-panel-" + panel.type + "-index"
|
|
9396
9427
|
}, [
|
|
9397
|
-
((_a2 = panel.labels) == null ? void 0 : _a2.topResultsTitle) && showTopResultsPanelTitle(panel.queryKey) ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
9428
|
+
((_a2 = panel.labels) == null ? void 0 : _a2.topResultsTitle) && showTopResultsPanelTitle(panel.queryKey) ? (openBlock(), createElementBlock("div", _hoisted_3$v, toDisplayString((_b = panel.labels) == null ? void 0 : _b.topResultsTitle), 1)) : createCommentVNode("", true),
|
|
9398
9429
|
panel.queryKey ? (openBlock(), createBlock(resolveDynamicComponent(getComponent(panel.type)), {
|
|
9399
9430
|
key: 1,
|
|
9400
9431
|
panel,
|
|
@@ -9801,7 +9832,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9801
9832
|
key: 0,
|
|
9802
9833
|
"data-cy": "suggested-search-text-label"
|
|
9803
9834
|
};
|
|
9804
|
-
const _hoisted_3$
|
|
9835
|
+
const _hoisted_3$u = {
|
|
9805
9836
|
key: 1,
|
|
9806
9837
|
"data-cy": "did-you-mean-label"
|
|
9807
9838
|
};
|
|
@@ -9848,7 +9879,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9848
9879
|
]);
|
|
9849
9880
|
}), 128))
|
|
9850
9881
|
])) : createCommentVNode("", true),
|
|
9851
|
-
didYouMeanValue.value ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
9882
|
+
didYouMeanValue.value ? (openBlock(), createElementBlock("div", _hoisted_3$u, [
|
|
9852
9883
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.labels.didYouMean.split(" "), (label, index) => {
|
|
9853
9884
|
return openBlock(), createElementBlock("span", { key: index }, [
|
|
9854
9885
|
label.includes("{1}") ? (openBlock(), createElementBlock("span", {
|
|
@@ -9902,7 +9933,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9902
9933
|
"data-cy": "lupa-result-page-title"
|
|
9903
9934
|
};
|
|
9904
9935
|
const _hoisted_2$D = { key: 0 };
|
|
9905
|
-
const _hoisted_3$
|
|
9936
|
+
const _hoisted_3$t = {
|
|
9906
9937
|
key: 1,
|
|
9907
9938
|
class: "lupa-results-total-count"
|
|
9908
9939
|
};
|
|
@@ -9945,7 +9976,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9945
9976
|
showSearchTitle.value ? (openBlock(), createElementBlock("h1", _hoisted_1$U, [
|
|
9946
9977
|
createTextVNode(toDisplayString(_ctx.options.labels.searchResults), 1),
|
|
9947
9978
|
queryText.value ? (openBlock(), createElementBlock("span", _hoisted_2$D, "'" + toDisplayString(queryText.value) + "'", 1)) : createCommentVNode("", true),
|
|
9948
|
-
showProductCount.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
9979
|
+
showProductCount.value ? (openBlock(), createElementBlock("span", _hoisted_3$t, "(" + toDisplayString(unref(totalItems)) + ")", 1)) : createCommentVNode("", true)
|
|
9949
9980
|
])) : createCommentVNode("", true),
|
|
9950
9981
|
_ctx.showSummary ? (openBlock(), createBlock(_sfc_main$Y, {
|
|
9951
9982
|
key: 1,
|
|
@@ -9965,7 +9996,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9965
9996
|
class: "lupa-current-filter-label",
|
|
9966
9997
|
"data-cy": "lupa-current-filter-label"
|
|
9967
9998
|
};
|
|
9968
|
-
const _hoisted_3$
|
|
9999
|
+
const _hoisted_3$s = {
|
|
9969
10000
|
class: "lupa-current-filter-value",
|
|
9970
10001
|
"data-cy": "lupa-current-filter-value"
|
|
9971
10002
|
};
|
|
@@ -9987,7 +10018,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9987
10018
|
onClick: handleClick
|
|
9988
10019
|
}, "⨉"),
|
|
9989
10020
|
createBaseVNode("div", _hoisted_2$C, toDisplayString(_ctx.filter.label) + ": ", 1),
|
|
9990
|
-
createBaseVNode("div", _hoisted_3$
|
|
10021
|
+
createBaseVNode("div", _hoisted_3$s, toDisplayString(_ctx.filter.value), 1)
|
|
9991
10022
|
]);
|
|
9992
10023
|
};
|
|
9993
10024
|
}
|
|
@@ -9997,7 +10028,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9997
10028
|
key: 0,
|
|
9998
10029
|
class: "lupa-filter-count"
|
|
9999
10030
|
};
|
|
10000
|
-
const _hoisted_3$
|
|
10031
|
+
const _hoisted_3$r = {
|
|
10001
10032
|
key: 0,
|
|
10002
10033
|
class: "filter-values"
|
|
10003
10034
|
};
|
|
@@ -10066,7 +10097,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10066
10097
|
class: normalizeClass(["lupa-filter-title-caret", isOpen.value && "open"])
|
|
10067
10098
|
}, null, 2)) : createCommentVNode("", true)
|
|
10068
10099
|
]),
|
|
10069
|
-
!_ctx.expandable || isOpen.value ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
10100
|
+
!_ctx.expandable || isOpen.value ? (openBlock(), createElementBlock("div", _hoisted_3$r, [
|
|
10070
10101
|
createBaseVNode("div", _hoisted_4$l, [
|
|
10071
10102
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(displayFilters), (filter) => {
|
|
10072
10103
|
return openBlock(), createBlock(_sfc_main$W, {
|
|
@@ -10134,7 +10165,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10134
10165
|
"data-cy": "lupa-category-filter"
|
|
10135
10166
|
};
|
|
10136
10167
|
const _hoisted_2$A = { class: "lupa-category-back" };
|
|
10137
|
-
const _hoisted_3$
|
|
10168
|
+
const _hoisted_3$q = ["href"];
|
|
10138
10169
|
const _hoisted_4$k = ["href"];
|
|
10139
10170
|
const _hoisted_5$d = { class: "lupa-child-category-list" };
|
|
10140
10171
|
const _sfc_main$T = /* @__PURE__ */ defineComponent({
|
|
@@ -10230,7 +10261,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10230
10261
|
"data-cy": "lupa-category-back",
|
|
10231
10262
|
href: backUrlLink.value,
|
|
10232
10263
|
onClick: handleNavigationBack
|
|
10233
|
-
}, toDisplayString(backTitle.value), 9, _hoisted_3$
|
|
10264
|
+
}, toDisplayString(backTitle.value), 9, _hoisted_3$q)) : createCommentVNode("", true)
|
|
10234
10265
|
]),
|
|
10235
10266
|
createBaseVNode("div", {
|
|
10236
10267
|
class: normalizeClass(["lupa-current-category", { "lupa-current-category-active": isActive }])
|
|
@@ -10260,7 +10291,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10260
10291
|
"data-cy": "lupa-search-result-facet-term-values"
|
|
10261
10292
|
};
|
|
10262
10293
|
const _hoisted_2$z = ["placeholder"];
|
|
10263
|
-
const _hoisted_3$
|
|
10294
|
+
const _hoisted_3$p = { class: "lupa-terms-list" };
|
|
10264
10295
|
const _hoisted_4$j = ["onClick"];
|
|
10265
10296
|
const _hoisted_5$c = { class: "lupa-term-checkbox-wrapper" };
|
|
10266
10297
|
const _hoisted_6$8 = { class: "lupa-term-checkbox-label" };
|
|
@@ -10350,7 +10381,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10350
10381
|
}, null, 8, _hoisted_2$z)), [
|
|
10351
10382
|
[vModelText, termFilter.value]
|
|
10352
10383
|
]) : createCommentVNode("", true),
|
|
10353
|
-
createBaseVNode("div", _hoisted_3$
|
|
10384
|
+
createBaseVNode("div", _hoisted_3$p, [
|
|
10354
10385
|
(openBlock(true), createElementBlock(Fragment, null, renderList(displayValues.value, (item) => {
|
|
10355
10386
|
return openBlock(), createElementBlock("div", {
|
|
10356
10387
|
class: normalizeClass(["lupa-facet-term", { checked: isChecked(item) }]),
|
|
@@ -11363,7 +11394,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11363
11394
|
key: 0,
|
|
11364
11395
|
class: "lupa-stats-facet-summary"
|
|
11365
11396
|
};
|
|
11366
|
-
const _hoisted_3$
|
|
11397
|
+
const _hoisted_3$o = {
|
|
11367
11398
|
key: 1,
|
|
11368
11399
|
class: "lupa-stats-facet-summary-input"
|
|
11369
11400
|
};
|
|
@@ -11549,7 +11580,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11549
11580
|
};
|
|
11550
11581
|
return (_ctx, _cache) => {
|
|
11551
11582
|
return openBlock(), createElementBlock("div", _hoisted_1$O, [
|
|
11552
|
-
!isInputVisible.value ? (openBlock(), createElementBlock("div", _hoisted_2$y, toDisplayString(statsSummary.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
11583
|
+
!isInputVisible.value ? (openBlock(), createElementBlock("div", _hoisted_2$y, toDisplayString(statsSummary.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$o, [
|
|
11553
11584
|
createBaseVNode("div", null, [
|
|
11554
11585
|
rangeLabelFrom.value ? (openBlock(), createElementBlock("div", _hoisted_4$i, toDisplayString(rangeLabelFrom.value), 1)) : createCommentVNode("", true),
|
|
11555
11586
|
createBaseVNode("div", _hoisted_5$b, [
|
|
@@ -11617,7 +11648,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11617
11648
|
});
|
|
11618
11649
|
const _hoisted_1$N = { class: "lupa-term-checkbox-wrapper" };
|
|
11619
11650
|
const _hoisted_2$x = { class: "lupa-term-checkbox-label" };
|
|
11620
|
-
const _hoisted_3$
|
|
11651
|
+
const _hoisted_3$n = { class: "lupa-term-label" };
|
|
11621
11652
|
const _hoisted_4$h = {
|
|
11622
11653
|
key: 0,
|
|
11623
11654
|
class: "lupa-term-count"
|
|
@@ -11678,7 +11709,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11678
11709
|
}, null, 2)
|
|
11679
11710
|
]),
|
|
11680
11711
|
createBaseVNode("div", _hoisted_2$x, [
|
|
11681
|
-
createBaseVNode("span", _hoisted_3$
|
|
11712
|
+
createBaseVNode("span", _hoisted_3$n, toDisplayString(_ctx.item.title) + toDisplayString(" "), 1),
|
|
11682
11713
|
_ctx.options.showDocumentCount ? (openBlock(), createElementBlock("span", _hoisted_4$h, "(" + toDisplayString(_ctx.item.count) + ")", 1)) : createCommentVNode("", true)
|
|
11683
11714
|
])
|
|
11684
11715
|
]),
|
|
@@ -11703,7 +11734,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11703
11734
|
"data-cy": "lupa-search-result-facet-term-values"
|
|
11704
11735
|
};
|
|
11705
11736
|
const _hoisted_2$w = { key: 0 };
|
|
11706
|
-
const _hoisted_3$
|
|
11737
|
+
const _hoisted_3$m = ["placeholder"];
|
|
11707
11738
|
const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
11708
11739
|
__name: "HierarchyFacet",
|
|
11709
11740
|
props: {
|
|
@@ -11761,7 +11792,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11761
11792
|
"data-cy": "lupa-term-filter",
|
|
11762
11793
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => termFilter.value = $event),
|
|
11763
11794
|
placeholder: _ctx.options.labels.facetFilter
|
|
11764
|
-
}, null, 8, _hoisted_3$
|
|
11795
|
+
}, null, 8, _hoisted_3$m), [
|
|
11765
11796
|
[vModelText, termFilter.value]
|
|
11766
11797
|
])
|
|
11767
11798
|
])) : createCommentVNode("", true),
|
|
@@ -12129,7 +12160,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12129
12160
|
class: "lupa-mobile-filter-sidebar"
|
|
12130
12161
|
};
|
|
12131
12162
|
const _hoisted_2$t = ["onClick"];
|
|
12132
|
-
const _hoisted_3$
|
|
12163
|
+
const _hoisted_3$l = { class: "lupa-mobile-sidebar-content" };
|
|
12133
12164
|
const _hoisted_4$g = { class: "lupa-sidebar-top" };
|
|
12134
12165
|
const _hoisted_5$9 = { class: "lupa-sidebar-title" };
|
|
12135
12166
|
const _hoisted_6$6 = {
|
|
@@ -12168,7 +12199,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12168
12199
|
class: "lupa-sidebar-close",
|
|
12169
12200
|
onClick: withModifiers(handleMobileToggle, ["stop"])
|
|
12170
12201
|
}, null, 8, _hoisted_2$t),
|
|
12171
|
-
createBaseVNode("div", _hoisted_3$
|
|
12202
|
+
createBaseVNode("div", _hoisted_3$l, [
|
|
12172
12203
|
createBaseVNode("div", _hoisted_4$g, [
|
|
12173
12204
|
createBaseVNode("div", _hoisted_5$9, [
|
|
12174
12205
|
createTextVNode(toDisplayString(sidebarTitle.value) + " ", 1),
|
|
@@ -12192,7 +12223,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12192
12223
|
});
|
|
12193
12224
|
const _hoisted_1$G = { id: "lupa-search-results-breadcrumbs" };
|
|
12194
12225
|
const _hoisted_2$s = ["href", "onClick"];
|
|
12195
|
-
const _hoisted_3$
|
|
12226
|
+
const _hoisted_3$k = {
|
|
12196
12227
|
key: 1,
|
|
12197
12228
|
class: "lupa-search-results-breadcrumb-text"
|
|
12198
12229
|
};
|
|
@@ -12236,7 +12267,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12236
12267
|
var _a;
|
|
12237
12268
|
return handleNavigation(e, (_a = breadcrumb == null ? void 0 : breadcrumb.link) != null ? _a : "");
|
|
12238
12269
|
}
|
|
12239
|
-
}, toDisplayString(getLabel(breadcrumb.label)), 9, _hoisted_2$s)) : (openBlock(), createElementBlock("span", _hoisted_3$
|
|
12270
|
+
}, toDisplayString(getLabel(breadcrumb.label)), 9, _hoisted_2$s)) : (openBlock(), createElementBlock("span", _hoisted_3$k, toDisplayString(getLabel(breadcrumb.label)), 1)),
|
|
12240
12271
|
index < breadcrumbsValue.value.length - 1 ? (openBlock(), createElementBlock("span", _hoisted_4$f, " / ")) : createCommentVNode("", true)
|
|
12241
12272
|
]);
|
|
12242
12273
|
}), 128))
|
|
@@ -12337,7 +12368,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12337
12368
|
key: 0,
|
|
12338
12369
|
class: "lupa-page-number-separator"
|
|
12339
12370
|
};
|
|
12340
|
-
const _hoisted_3$
|
|
12371
|
+
const _hoisted_3$j = ["onClick"];
|
|
12341
12372
|
const _hoisted_4$e = {
|
|
12342
12373
|
key: 0,
|
|
12343
12374
|
class: "lupa-page-number-separator"
|
|
@@ -12441,7 +12472,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12441
12472
|
page === _ctx.options.selectedPage ? "lupa-page-number-selected" : ""
|
|
12442
12473
|
]),
|
|
12443
12474
|
"data-cy": "lupa-page-number"
|
|
12444
|
-
}, toDisplayString(page), 11, _hoisted_3$
|
|
12475
|
+
}, toDisplayString(page), 11, _hoisted_3$j);
|
|
12445
12476
|
}), 128)),
|
|
12446
12477
|
showLastPage.value ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
12447
12478
|
showLastPageSeparator.value ? (openBlock(), createElementBlock("div", _hoisted_4$e, "...")) : createCommentVNode("", true),
|
|
@@ -12468,7 +12499,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12468
12499
|
"data-cy": "lupa-search-results-page-size"
|
|
12469
12500
|
};
|
|
12470
12501
|
const _hoisted_2$q = { id: "lupa-select" };
|
|
12471
|
-
const _hoisted_3$
|
|
12502
|
+
const _hoisted_3$i = { class: "lupa-select-label" };
|
|
12472
12503
|
const _hoisted_4$d = ["aria-label"];
|
|
12473
12504
|
const _sfc_main$E = /* @__PURE__ */ defineComponent({
|
|
12474
12505
|
__name: "SearchResultsPageSize",
|
|
@@ -12489,7 +12520,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12489
12520
|
return (_ctx, _cache) => {
|
|
12490
12521
|
return openBlock(), createElementBlock("div", _hoisted_1$B, [
|
|
12491
12522
|
createBaseVNode("div", _hoisted_2$q, [
|
|
12492
|
-
createBaseVNode("label", _hoisted_3$
|
|
12523
|
+
createBaseVNode("label", _hoisted_3$i, toDisplayString(_ctx.label), 1),
|
|
12493
12524
|
createBaseVNode("select", {
|
|
12494
12525
|
class: "lupa-select-dropdown",
|
|
12495
12526
|
"aria-label": _ctx.label,
|
|
@@ -12512,7 +12543,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12512
12543
|
class: "lupa-search-results-sort"
|
|
12513
12544
|
};
|
|
12514
12545
|
const _hoisted_2$p = { id: "lupa-select" };
|
|
12515
|
-
const _hoisted_3$
|
|
12546
|
+
const _hoisted_3$h = { class: "lupa-select-label" };
|
|
12516
12547
|
const _hoisted_4$c = ["aria-label"];
|
|
12517
12548
|
const _hoisted_5$8 = ["value"];
|
|
12518
12549
|
const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
@@ -12565,7 +12596,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12565
12596
|
return (_ctx, _cache) => {
|
|
12566
12597
|
return openBlock(), createElementBlock("div", _hoisted_1$A, [
|
|
12567
12598
|
createBaseVNode("div", _hoisted_2$p, [
|
|
12568
|
-
createBaseVNode("label", _hoisted_3$
|
|
12599
|
+
createBaseVNode("label", _hoisted_3$h, toDisplayString(_ctx.options.label), 1),
|
|
12569
12600
|
withDirectives(createBaseVNode("select", {
|
|
12570
12601
|
class: "lupa-select-dropdown",
|
|
12571
12602
|
"aria-label": _ctx.options.label,
|
|
@@ -12590,7 +12621,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12590
12621
|
});
|
|
12591
12622
|
const _hoisted_1$z = { class: "lupa-toolbar-left" };
|
|
12592
12623
|
const _hoisted_2$o = { key: 1 };
|
|
12593
|
-
const _hoisted_3$
|
|
12624
|
+
const _hoisted_3$g = { key: 3 };
|
|
12594
12625
|
const _hoisted_4$b = { key: 5 };
|
|
12595
12626
|
const _hoisted_5$7 = { class: "lupa-toolbar-right" };
|
|
12596
12627
|
const _hoisted_6$5 = { key: 1 };
|
|
@@ -12701,7 +12732,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12701
12732
|
label: searchSummaryLabel.value,
|
|
12702
12733
|
clearable: unref(hasAnyFilter) && showFilterClear.value,
|
|
12703
12734
|
onClear: handleClearAll
|
|
12704
|
-
}, null, 8, ["label", "clearable"])) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
12735
|
+
}, null, 8, ["label", "clearable"])) : (openBlock(), createElementBlock("div", _hoisted_3$g)),
|
|
12705
12736
|
displayPageSelect.value ? (openBlock(), createBlock(_sfc_main$F, {
|
|
12706
12737
|
key: 4,
|
|
12707
12738
|
options: paginationOptions.value.pageSelect,
|
|
@@ -12731,7 +12762,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12731
12762
|
});
|
|
12732
12763
|
const _hoisted_1$y = { class: "lupa-badge-title" };
|
|
12733
12764
|
const _hoisted_2$n = ["src"];
|
|
12734
|
-
const _hoisted_3$
|
|
12765
|
+
const _hoisted_3$f = { key: 1 };
|
|
12735
12766
|
const _hoisted_4$a = {
|
|
12736
12767
|
key: 0,
|
|
12737
12768
|
class: "lupa-badge-full-text"
|
|
@@ -12774,7 +12805,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12774
12805
|
key: 0,
|
|
12775
12806
|
src: image.value
|
|
12776
12807
|
}, null, 8, _hoisted_2$n)) : createCommentVNode("", true),
|
|
12777
|
-
hasTitleText.value && showTitle.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
12808
|
+
hasTitleText.value && showTitle.value ? (openBlock(), createElementBlock("span", _hoisted_3$f, toDisplayString(_ctx.badge.titleText), 1)) : createCommentVNode("", true)
|
|
12778
12809
|
]),
|
|
12779
12810
|
hasAdditionalText.value ? (openBlock(), createElementBlock("span", _hoisted_4$a, toDisplayString(_ctx.badge.additionalText), 1)) : createCommentVNode("", true)
|
|
12780
12811
|
], 6);
|
|
@@ -13001,7 +13032,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13001
13032
|
});
|
|
13002
13033
|
const _hoisted_1$s = ["innerHTML"];
|
|
13003
13034
|
const _hoisted_2$l = ["title"];
|
|
13004
|
-
const _hoisted_3$
|
|
13035
|
+
const _hoisted_3$e = {
|
|
13005
13036
|
key: 0,
|
|
13006
13037
|
class: "lupa-search-results-product-title-text"
|
|
13007
13038
|
};
|
|
@@ -13045,7 +13076,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13045
13076
|
style: normalizeStyle(`-webkit-line-clamp: ${maxLines.value}`),
|
|
13046
13077
|
title: title.value
|
|
13047
13078
|
}, [
|
|
13048
|
-
!_ctx.options.link ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
13079
|
+
!_ctx.options.link ? (openBlock(), createElementBlock("span", _hoisted_3$e, toDisplayString(title.value), 1)) : createCommentVNode("", true),
|
|
13049
13080
|
_ctx.options.link ? (openBlock(), createElementBlock("a", {
|
|
13050
13081
|
key: 1,
|
|
13051
13082
|
href: _ctx.link,
|
|
@@ -13091,7 +13122,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13091
13122
|
});
|
|
13092
13123
|
const _hoisted_1$q = { id: "lupa-search-results-rating" };
|
|
13093
13124
|
const _hoisted_2$k = { class: "lupa-ratings" };
|
|
13094
|
-
const _hoisted_3$
|
|
13125
|
+
const _hoisted_3$d = { class: "lupa-ratings-base" };
|
|
13095
13126
|
const _hoisted_4$8 = ["innerHTML"];
|
|
13096
13127
|
const _hoisted_5$6 = { class: "lupa-rating-wrapper" };
|
|
13097
13128
|
const _hoisted_6$4 = ["innerHTML"];
|
|
@@ -13130,7 +13161,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13130
13161
|
return (_ctx, _cache) => {
|
|
13131
13162
|
return openBlock(), createElementBlock("div", _hoisted_1$q, [
|
|
13132
13163
|
createBaseVNode("div", _hoisted_2$k, [
|
|
13133
|
-
createBaseVNode("div", _hoisted_3$
|
|
13164
|
+
createBaseVNode("div", _hoisted_3$d, [
|
|
13134
13165
|
(openBlock(true), createElementBlock(Fragment, null, renderList(baseStars.value, (star, index) => {
|
|
13135
13166
|
return openBlock(), createElementBlock("div", {
|
|
13136
13167
|
key: index,
|
|
@@ -13218,7 +13249,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13218
13249
|
});
|
|
13219
13250
|
const _hoisted_1$n = { class: "lupa-search-results-add-to-cart-wrapper" };
|
|
13220
13251
|
const _hoisted_2$j = { class: "lupa-search-results-product-addtocart" };
|
|
13221
|
-
const _hoisted_3$
|
|
13252
|
+
const _hoisted_3$c = ["onClick", "disabled"];
|
|
13222
13253
|
const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
13223
13254
|
__name: "SearchResultsProductAddToCart",
|
|
13224
13255
|
props: {
|
|
@@ -13253,7 +13284,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13253
13284
|
class: normalizeClass(loading.value ? "lupa-add-to-cart-loading" : "lupa-add-to-cart"),
|
|
13254
13285
|
"data-cy": "lupa-add-to-cart",
|
|
13255
13286
|
disabled: !inStockValue.value || loading.value
|
|
13256
|
-
}, toDisplayString(label.value), 11, _hoisted_3$
|
|
13287
|
+
}, toDisplayString(label.value), 11, _hoisted_3$c)
|
|
13257
13288
|
])
|
|
13258
13289
|
]);
|
|
13259
13290
|
};
|
|
@@ -13261,7 +13292,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13261
13292
|
});
|
|
13262
13293
|
const _hoisted_1$m = ["innerHTML"];
|
|
13263
13294
|
const _hoisted_2$i = { key: 0 };
|
|
13264
|
-
const _hoisted_3$
|
|
13295
|
+
const _hoisted_3$b = { key: 1 };
|
|
13265
13296
|
const _hoisted_4$7 = { class: "lupa-search-box-custom-label" };
|
|
13266
13297
|
const _hoisted_5$5 = { class: "lupa-search-box-custom-text" };
|
|
13267
13298
|
const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
@@ -13306,7 +13337,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13306
13337
|
key: 1,
|
|
13307
13338
|
class: className.value
|
|
13308
13339
|
}, toHandlers(_ctx.options.action ? { click: handleClick } : {}, true)), [
|
|
13309
|
-
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$i, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
13340
|
+
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$i, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$b, [
|
|
13310
13341
|
createBaseVNode("div", _hoisted_4$7, toDisplayString(label.value), 1),
|
|
13311
13342
|
createBaseVNode("div", _hoisted_5$5, toDisplayString(text.value), 1)
|
|
13312
13343
|
]))
|
|
@@ -13345,7 +13376,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13345
13376
|
});
|
|
13346
13377
|
const _hoisted_1$k = { id: "lupa-search-results-rating" };
|
|
13347
13378
|
const _hoisted_2$h = ["innerHTML"];
|
|
13348
|
-
const _hoisted_3$
|
|
13379
|
+
const _hoisted_3$a = { class: "lupa-ratings" };
|
|
13349
13380
|
const _hoisted_4$6 = ["href"];
|
|
13350
13381
|
const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
13351
13382
|
__name: "SearchResultsProductSingleStarRating",
|
|
@@ -13380,7 +13411,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13380
13411
|
innerHTML: star.value,
|
|
13381
13412
|
class: "lupa-rating lupa-rating-highlighted"
|
|
13382
13413
|
}, null, 8, _hoisted_2$h),
|
|
13383
|
-
createBaseVNode("div", _hoisted_3$
|
|
13414
|
+
createBaseVNode("div", _hoisted_3$a, toDisplayString(rating.value), 1),
|
|
13384
13415
|
createBaseVNode("a", {
|
|
13385
13416
|
href: ratingLink.value,
|
|
13386
13417
|
class: "lupa-total-ratings"
|
|
@@ -13478,7 +13509,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13478
13509
|
key: 0,
|
|
13479
13510
|
class: "lupa-out-of-stock"
|
|
13480
13511
|
};
|
|
13481
|
-
const _hoisted_3$
|
|
13512
|
+
const _hoisted_3$9 = { class: "lupa-search-result-product-details-section" };
|
|
13482
13513
|
const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
13483
13514
|
__name: "SearchResultsProductCard",
|
|
13484
13515
|
props: {
|
|
@@ -13654,7 +13685,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13654
13685
|
}, null, 8, ["options"]),
|
|
13655
13686
|
((_a = labels.value) == null ? void 0 : _a.outOfStock) && !isInStock.value ? (openBlock(), createElementBlock("div", _hoisted_2$g, toDisplayString(labels.value.outOfStock), 1)) : createCommentVNode("", true)
|
|
13656
13687
|
], 8, _hoisted_1$j),
|
|
13657
|
-
createBaseVNode("div", _hoisted_3$
|
|
13688
|
+
createBaseVNode("div", _hoisted_3$9, [
|
|
13658
13689
|
(openBlock(true), createElementBlock(Fragment, null, renderList(detailElements.value, (element) => {
|
|
13659
13690
|
return openBlock(), createBlock(_sfc_main$l, {
|
|
13660
13691
|
class: "lupa-search-results-product-element",
|
|
@@ -13697,7 +13728,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13697
13728
|
"data-cy": "lupa-search-results-similar-queries"
|
|
13698
13729
|
};
|
|
13699
13730
|
const _hoisted_2$f = { class: "lupa-similar-queries-label" };
|
|
13700
|
-
const _hoisted_3$
|
|
13731
|
+
const _hoisted_3$8 = {
|
|
13701
13732
|
class: "lupa-similar-query-label",
|
|
13702
13733
|
"data-cy": "lupa-similar-query-label"
|
|
13703
13734
|
};
|
|
@@ -13742,7 +13773,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13742
13773
|
createBaseVNode("div", _hoisted_2$f, toDisplayString(_ctx.labels.similarQueries), 1),
|
|
13743
13774
|
(openBlock(true), createElementBlock(Fragment, null, renderList(similarQueries.value, (similarQuery, index) => {
|
|
13744
13775
|
return openBlock(), createElementBlock("div", { key: index }, [
|
|
13745
|
-
createBaseVNode("div", _hoisted_3$
|
|
13776
|
+
createBaseVNode("div", _hoisted_3$8, [
|
|
13746
13777
|
createBaseVNode("span", null, toDisplayString(similarQueryLabel.value), 1),
|
|
13747
13778
|
createBaseVNode("span", {
|
|
13748
13779
|
id: "lupa-similar-query-text-component",
|
|
@@ -13931,7 +13962,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13931
13962
|
"data-cy": "lupa-search-results-similar-results"
|
|
13932
13963
|
};
|
|
13933
13964
|
const _hoisted_2$c = { class: "lupa-similar-results-label" };
|
|
13934
|
-
const _hoisted_3$
|
|
13965
|
+
const _hoisted_3$7 = {
|
|
13935
13966
|
class: "lupa-products",
|
|
13936
13967
|
"data-cy": "lupa-products"
|
|
13937
13968
|
};
|
|
@@ -13953,7 +13984,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13953
13984
|
return (_ctx, _cache) => {
|
|
13954
13985
|
return openBlock(), createElementBlock("div", _hoisted_1$e, [
|
|
13955
13986
|
createBaseVNode("div", _hoisted_2$c, toDisplayString(_ctx.labels.similarResultsLabel), 1),
|
|
13956
|
-
createBaseVNode("div", _hoisted_3$
|
|
13987
|
+
createBaseVNode("div", _hoisted_3$7, [
|
|
13957
13988
|
(openBlock(true), createElementBlock(Fragment, null, renderList(similarResults.value.items, (product, index) => {
|
|
13958
13989
|
return openBlock(), createBlock(_sfc_main$k, {
|
|
13959
13990
|
style: normalizeStyle(_ctx.columnSize),
|
|
@@ -13972,7 +14003,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13972
14003
|
class: "lupa-products",
|
|
13973
14004
|
"data-cy": "lupa-products"
|
|
13974
14005
|
};
|
|
13975
|
-
const _hoisted_3$
|
|
14006
|
+
const _hoisted_3$6 = {
|
|
13976
14007
|
key: 0,
|
|
13977
14008
|
class: "lupa-empty-results",
|
|
13978
14009
|
"data-cy": "lupa-no-results-in-page"
|
|
@@ -14135,7 +14166,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14135
14166
|
}, null, 8, ["style", "product", "options"]);
|
|
14136
14167
|
}), 128))
|
|
14137
14168
|
]),
|
|
14138
|
-
unref(isPageEmpty) && _ctx.options.labels.noItemsInPage ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
14169
|
+
unref(isPageEmpty) && _ctx.options.labels.noItemsInPage ? (openBlock(), createElementBlock("div", _hoisted_3$6, [
|
|
14139
14170
|
createTextVNode(toDisplayString(_ctx.options.labels.noItemsInPage) + " ", 1),
|
|
14140
14171
|
_ctx.options.labels.backToFirstPage ? (openBlock(), createElementBlock("span", {
|
|
14141
14172
|
key: 0,
|
|
@@ -14181,7 +14212,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14181
14212
|
key: 0,
|
|
14182
14213
|
class: "lupa-category-back"
|
|
14183
14214
|
};
|
|
14184
|
-
const _hoisted_3$
|
|
14215
|
+
const _hoisted_3$5 = ["href"];
|
|
14185
14216
|
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
14186
14217
|
__name: "CategoryTopFilters",
|
|
14187
14218
|
props: {
|
|
@@ -14220,7 +14251,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14220
14251
|
"data-cy": "lupa-category-back",
|
|
14221
14252
|
href: backUrlLink.value,
|
|
14222
14253
|
onClick: handleNavigationBack
|
|
14223
|
-
}, toDisplayString(backTitle.value), 9, _hoisted_3$
|
|
14254
|
+
}, toDisplayString(backTitle.value), 9, _hoisted_3$5)
|
|
14224
14255
|
])) : createCommentVNode("", true),
|
|
14225
14256
|
createVNode(_sfc_main$C, {
|
|
14226
14257
|
class: "lupa-toolbar-mobile",
|
|
@@ -14241,7 +14272,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14241
14272
|
id: "lupa-search-results",
|
|
14242
14273
|
class: "top-layout-wrapper"
|
|
14243
14274
|
};
|
|
14244
|
-
const _hoisted_3$
|
|
14275
|
+
const _hoisted_3$4 = { class: "search-content" };
|
|
14245
14276
|
const _hoisted_4$3 = { id: "lupa-search-results" };
|
|
14246
14277
|
const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
14247
14278
|
__name: "SearchResults",
|
|
@@ -14480,7 +14511,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14480
14511
|
ref_key: "searchResultsFilters",
|
|
14481
14512
|
ref: searchResultsFilters
|
|
14482
14513
|
}, null, 8, ["options"])) : createCommentVNode("", true),
|
|
14483
|
-
createBaseVNode("div", _hoisted_3$
|
|
14514
|
+
createBaseVNode("div", _hoisted_3$4, [
|
|
14484
14515
|
createVNode(_sfc_main$Z, { labels: didYouMeanLabels.value }, null, 8, ["labels"]),
|
|
14485
14516
|
createVNode(_sfc_main$X, {
|
|
14486
14517
|
options: _ctx.options,
|
|
@@ -20971,12 +21002,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
20971
21002
|
});
|
|
20972
21003
|
const _hoisted_1$7 = { class: "lupa-chat-spinner" };
|
|
20973
21004
|
const _hoisted_2$5 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20974
|
-
const _hoisted_3$
|
|
21005
|
+
const _hoisted_3$3 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20975
21006
|
const _hoisted_4$2 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20976
21007
|
const _hoisted_5$2 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20977
21008
|
const _hoisted_6$1 = [
|
|
20978
21009
|
_hoisted_2$5,
|
|
20979
|
-
_hoisted_3$
|
|
21010
|
+
_hoisted_3$3,
|
|
20980
21011
|
_hoisted_4$2,
|
|
20981
21012
|
_hoisted_5$2
|
|
20982
21013
|
];
|
|
@@ -21000,7 +21031,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21000
21031
|
});
|
|
21001
21032
|
const _hoisted_1$6 = { class: "lupa-chat-input-container" };
|
|
21002
21033
|
const _hoisted_2$4 = { id: "lupa-search-box-input" };
|
|
21003
|
-
const _hoisted_3$
|
|
21034
|
+
const _hoisted_3$2 = {
|
|
21004
21035
|
key: 0,
|
|
21005
21036
|
class: "lupa-chat-form-submit"
|
|
21006
21037
|
};
|
|
@@ -21036,7 +21067,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21036
21067
|
[vModelText, inputValue.value]
|
|
21037
21068
|
])
|
|
21038
21069
|
]),
|
|
21039
|
-
!_ctx.disabled ? (openBlock(), createElementBlock("button", _hoisted_3$
|
|
21070
|
+
!_ctx.disabled ? (openBlock(), createElementBlock("button", _hoisted_3$2, "Ask LupaChat")) : (openBlock(), createBlock(_sfc_main$7, {
|
|
21040
21071
|
key: 1,
|
|
21041
21072
|
small: true
|
|
21042
21073
|
}))
|
|
@@ -21203,7 +21234,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21203
21234
|
});
|
|
21204
21235
|
const _hoisted_1$4 = { class: "lupa-chat-content-entry-phrase" };
|
|
21205
21236
|
const _hoisted_2$3 = { class: "lupa-chat-phrase-title" };
|
|
21206
|
-
const _hoisted_3$
|
|
21237
|
+
const _hoisted_3$1 = {
|
|
21207
21238
|
key: 0,
|
|
21208
21239
|
class: "alert"
|
|
21209
21240
|
};
|
|
@@ -21304,7 +21335,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21304
21335
|
createBaseVNode("div", _hoisted_2$3, [
|
|
21305
21336
|
createBaseVNode("h3", null, toDisplayString(displayPhrase.value), 1),
|
|
21306
21337
|
createBaseVNode("sub", null, toDisplayString(usedAlternativePhrases.value.join(", ")), 1),
|
|
21307
|
-
usedPartialResults.value ? (openBlock(), createElementBlock("sub", _hoisted_3$
|
|
21338
|
+
usedPartialResults.value ? (openBlock(), createElementBlock("sub", _hoisted_3$1, "Including partial matches - which might not be what you are looking for")) : createCommentVNode("", true)
|
|
21308
21339
|
]),
|
|
21309
21340
|
createBaseVNode("div", null, [
|
|
21310
21341
|
createVNode(_sfc_main$5, {
|
|
@@ -21323,7 +21354,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21323
21354
|
});
|
|
21324
21355
|
const _hoisted_1$3 = { class: "lupa-chat-best-matches lupa-chat-content-entry" };
|
|
21325
21356
|
const _hoisted_2$2 = /* @__PURE__ */ createBaseVNode("h3", null, "Best matches", -1);
|
|
21326
|
-
const
|
|
21357
|
+
const MAX_SOURCES_FOR_BEST_ITEM_MATCHING = 250;
|
|
21327
21358
|
const _sfc_main$3$1 = /* @__PURE__ */ defineComponent({
|
|
21328
21359
|
__name: "ChatContentEntry",
|
|
21329
21360
|
props: {
|
|
@@ -21353,20 +21384,18 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21353
21384
|
return (_a = props.options.displayOptions.titleKey) != null ? _a : "title";
|
|
21354
21385
|
});
|
|
21355
21386
|
const loadFinalRecommendations = () => __async(this, null, function* () {
|
|
21356
|
-
var _a;
|
|
21387
|
+
var _a, _b;
|
|
21357
21388
|
try {
|
|
21358
|
-
const productResultStrings = loadedResults.value.map(
|
|
21359
|
-
|
|
21360
|
-
|
|
21361
|
-
|
|
21362
|
-
}
|
|
21363
|
-
);
|
|
21389
|
+
const productResultStrings = (_a = loadedResults.value.map((result) => {
|
|
21390
|
+
var _a2, _b2;
|
|
21391
|
+
return (_b2 = (_a2 = result[titleKey.value]) == null ? void 0 : _a2.toString()) != null ? _b2 : "";
|
|
21392
|
+
})) == null ? void 0 : _a.slice(0, MAX_SOURCES_FOR_BEST_ITEM_MATCHING);
|
|
21364
21393
|
const { products } = yield ChatService.suggestBestProductMatches(
|
|
21365
21394
|
props.options.sdkOptions,
|
|
21366
21395
|
{
|
|
21367
21396
|
initialQuery: props.entry.userInput,
|
|
21368
21397
|
productStrings: productResultStrings,
|
|
21369
|
-
messageHistory: (
|
|
21398
|
+
messageHistory: (_b = props.history) != null ? _b : [],
|
|
21370
21399
|
queryKey: props.options.displayOptions.queryKey
|
|
21371
21400
|
},
|
|
21372
21401
|
props.options.chatSettings
|
|
@@ -21379,13 +21408,9 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21379
21408
|
});
|
|
21380
21409
|
const bestMatchProducts = computed(() => {
|
|
21381
21410
|
return bestMatches.value.map((productName) => {
|
|
21382
|
-
return loadedResults.value
|
|
21411
|
+
return findClosestStringValue(productName, loadedResults.value, titleKey.value);
|
|
21383
21412
|
}).filter(Boolean);
|
|
21384
21413
|
});
|
|
21385
|
-
const explanation = computed(() => {
|
|
21386
|
-
var _a, _b;
|
|
21387
|
-
return ((_a = bestMatches.value) == null ? void 0 : _a.length) > 0 && !bestMatchProducts.value.length ? (_b = bestMatches == null ? void 0 : bestMatches.value) == null ? void 0 : _b[0] : "";
|
|
21388
|
-
});
|
|
21389
21414
|
return (_ctx, _cache) => {
|
|
21390
21415
|
return openBlock(), createElementBlock("div", null, [
|
|
21391
21416
|
createBaseVNode("ul", null, [
|
|
@@ -21405,13 +21430,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21405
21430
|
]),
|
|
21406
21431
|
createBaseVNode("section", _hoisted_1$3, [
|
|
21407
21432
|
_hoisted_2$2,
|
|
21408
|
-
explanation.value ? (openBlock(), createElementBlock("p", _hoisted_3$1, toDisplayString(explanation.value), 1)) : createCommentVNode("", true),
|
|
21409
21433
|
loading.value ? (openBlock(), createBlock(_sfc_main$7, {
|
|
21410
|
-
key:
|
|
21434
|
+
key: 0,
|
|
21411
21435
|
message: "Selecting the best matches for you. This might take a few seconds."
|
|
21412
21436
|
})) : createCommentVNode("", true),
|
|
21413
21437
|
bestMatches.value.length ? (openBlock(), createBlock(_sfc_main$5, {
|
|
21414
|
-
key:
|
|
21438
|
+
key: 1,
|
|
21415
21439
|
"search-results": bestMatchProducts.value,
|
|
21416
21440
|
options: _ctx.options.displayOptions
|
|
21417
21441
|
}, null, 8, ["search-results", "options"])) : createCommentVNode("", true)
|