@getlupa/client 1.8.6 → 1.8.8
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 +118 -91
- package/dist/lupaSearch.js +118 -91
- package/dist/lupaSearch.mjs +118 -91
- package/dist/lupaSearch.umd.js +118 -91
- 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,
|
|
@@ -9537,13 +9568,16 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9537
9568
|
suggestedValue.value = defaultSuggestedValue;
|
|
9538
9569
|
};
|
|
9539
9570
|
const handleKeyDown = (e) => {
|
|
9571
|
+
var _a2, _b;
|
|
9540
9572
|
if (!opened.value) {
|
|
9541
9573
|
return;
|
|
9542
9574
|
}
|
|
9543
9575
|
switch (e.key) {
|
|
9544
9576
|
case "Tab":
|
|
9545
|
-
|
|
9546
|
-
|
|
9577
|
+
if ((_b = (_a2 = suggestedValue == null ? void 0 : suggestedValue.value) == null ? void 0 : _a2.item) == null ? void 0 : _b.suggestion) {
|
|
9578
|
+
e.preventDefault();
|
|
9579
|
+
selectSuggestion(__spreadProps2(__spreadValues2({}, suggestedValue.value), { override: true }));
|
|
9580
|
+
}
|
|
9547
9581
|
break;
|
|
9548
9582
|
case "Enter":
|
|
9549
9583
|
e.preventDefault();
|
|
@@ -9801,7 +9835,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9801
9835
|
key: 0,
|
|
9802
9836
|
"data-cy": "suggested-search-text-label"
|
|
9803
9837
|
};
|
|
9804
|
-
const _hoisted_3$
|
|
9838
|
+
const _hoisted_3$u = {
|
|
9805
9839
|
key: 1,
|
|
9806
9840
|
"data-cy": "did-you-mean-label"
|
|
9807
9841
|
};
|
|
@@ -9848,7 +9882,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9848
9882
|
]);
|
|
9849
9883
|
}), 128))
|
|
9850
9884
|
])) : createCommentVNode("", true),
|
|
9851
|
-
didYouMeanValue.value ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
9885
|
+
didYouMeanValue.value ? (openBlock(), createElementBlock("div", _hoisted_3$u, [
|
|
9852
9886
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.labels.didYouMean.split(" "), (label, index) => {
|
|
9853
9887
|
return openBlock(), createElementBlock("span", { key: index }, [
|
|
9854
9888
|
label.includes("{1}") ? (openBlock(), createElementBlock("span", {
|
|
@@ -9902,7 +9936,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9902
9936
|
"data-cy": "lupa-result-page-title"
|
|
9903
9937
|
};
|
|
9904
9938
|
const _hoisted_2$D = { key: 0 };
|
|
9905
|
-
const _hoisted_3$
|
|
9939
|
+
const _hoisted_3$t = {
|
|
9906
9940
|
key: 1,
|
|
9907
9941
|
class: "lupa-results-total-count"
|
|
9908
9942
|
};
|
|
@@ -9945,7 +9979,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9945
9979
|
showSearchTitle.value ? (openBlock(), createElementBlock("h1", _hoisted_1$U, [
|
|
9946
9980
|
createTextVNode(toDisplayString(_ctx.options.labels.searchResults), 1),
|
|
9947
9981
|
queryText.value ? (openBlock(), createElementBlock("span", _hoisted_2$D, "'" + toDisplayString(queryText.value) + "'", 1)) : createCommentVNode("", true),
|
|
9948
|
-
showProductCount.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
9982
|
+
showProductCount.value ? (openBlock(), createElementBlock("span", _hoisted_3$t, "(" + toDisplayString(unref(totalItems)) + ")", 1)) : createCommentVNode("", true)
|
|
9949
9983
|
])) : createCommentVNode("", true),
|
|
9950
9984
|
_ctx.showSummary ? (openBlock(), createBlock(_sfc_main$Y, {
|
|
9951
9985
|
key: 1,
|
|
@@ -9965,7 +9999,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9965
9999
|
class: "lupa-current-filter-label",
|
|
9966
10000
|
"data-cy": "lupa-current-filter-label"
|
|
9967
10001
|
};
|
|
9968
|
-
const _hoisted_3$
|
|
10002
|
+
const _hoisted_3$s = {
|
|
9969
10003
|
class: "lupa-current-filter-value",
|
|
9970
10004
|
"data-cy": "lupa-current-filter-value"
|
|
9971
10005
|
};
|
|
@@ -9987,7 +10021,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9987
10021
|
onClick: handleClick
|
|
9988
10022
|
}, "⨉"),
|
|
9989
10023
|
createBaseVNode("div", _hoisted_2$C, toDisplayString(_ctx.filter.label) + ": ", 1),
|
|
9990
|
-
createBaseVNode("div", _hoisted_3$
|
|
10024
|
+
createBaseVNode("div", _hoisted_3$s, toDisplayString(_ctx.filter.value), 1)
|
|
9991
10025
|
]);
|
|
9992
10026
|
};
|
|
9993
10027
|
}
|
|
@@ -9997,7 +10031,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
9997
10031
|
key: 0,
|
|
9998
10032
|
class: "lupa-filter-count"
|
|
9999
10033
|
};
|
|
10000
|
-
const _hoisted_3$
|
|
10034
|
+
const _hoisted_3$r = {
|
|
10001
10035
|
key: 0,
|
|
10002
10036
|
class: "filter-values"
|
|
10003
10037
|
};
|
|
@@ -10066,7 +10100,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10066
10100
|
class: normalizeClass(["lupa-filter-title-caret", isOpen.value && "open"])
|
|
10067
10101
|
}, null, 2)) : createCommentVNode("", true)
|
|
10068
10102
|
]),
|
|
10069
|
-
!_ctx.expandable || isOpen.value ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
10103
|
+
!_ctx.expandable || isOpen.value ? (openBlock(), createElementBlock("div", _hoisted_3$r, [
|
|
10070
10104
|
createBaseVNode("div", _hoisted_4$l, [
|
|
10071
10105
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(displayFilters), (filter) => {
|
|
10072
10106
|
return openBlock(), createBlock(_sfc_main$W, {
|
|
@@ -10134,7 +10168,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10134
10168
|
"data-cy": "lupa-category-filter"
|
|
10135
10169
|
};
|
|
10136
10170
|
const _hoisted_2$A = { class: "lupa-category-back" };
|
|
10137
|
-
const _hoisted_3$
|
|
10171
|
+
const _hoisted_3$q = ["href"];
|
|
10138
10172
|
const _hoisted_4$k = ["href"];
|
|
10139
10173
|
const _hoisted_5$d = { class: "lupa-child-category-list" };
|
|
10140
10174
|
const _sfc_main$T = /* @__PURE__ */ defineComponent({
|
|
@@ -10230,7 +10264,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10230
10264
|
"data-cy": "lupa-category-back",
|
|
10231
10265
|
href: backUrlLink.value,
|
|
10232
10266
|
onClick: handleNavigationBack
|
|
10233
|
-
}, toDisplayString(backTitle.value), 9, _hoisted_3$
|
|
10267
|
+
}, toDisplayString(backTitle.value), 9, _hoisted_3$q)) : createCommentVNode("", true)
|
|
10234
10268
|
]),
|
|
10235
10269
|
createBaseVNode("div", {
|
|
10236
10270
|
class: normalizeClass(["lupa-current-category", { "lupa-current-category-active": isActive }])
|
|
@@ -10260,7 +10294,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10260
10294
|
"data-cy": "lupa-search-result-facet-term-values"
|
|
10261
10295
|
};
|
|
10262
10296
|
const _hoisted_2$z = ["placeholder"];
|
|
10263
|
-
const _hoisted_3$
|
|
10297
|
+
const _hoisted_3$p = { class: "lupa-terms-list" };
|
|
10264
10298
|
const _hoisted_4$j = ["onClick"];
|
|
10265
10299
|
const _hoisted_5$c = { class: "lupa-term-checkbox-wrapper" };
|
|
10266
10300
|
const _hoisted_6$8 = { class: "lupa-term-checkbox-label" };
|
|
@@ -10350,7 +10384,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
10350
10384
|
}, null, 8, _hoisted_2$z)), [
|
|
10351
10385
|
[vModelText, termFilter.value]
|
|
10352
10386
|
]) : createCommentVNode("", true),
|
|
10353
|
-
createBaseVNode("div", _hoisted_3$
|
|
10387
|
+
createBaseVNode("div", _hoisted_3$p, [
|
|
10354
10388
|
(openBlock(true), createElementBlock(Fragment, null, renderList(displayValues.value, (item) => {
|
|
10355
10389
|
return openBlock(), createElementBlock("div", {
|
|
10356
10390
|
class: normalizeClass(["lupa-facet-term", { checked: isChecked(item) }]),
|
|
@@ -11363,7 +11397,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11363
11397
|
key: 0,
|
|
11364
11398
|
class: "lupa-stats-facet-summary"
|
|
11365
11399
|
};
|
|
11366
|
-
const _hoisted_3$
|
|
11400
|
+
const _hoisted_3$o = {
|
|
11367
11401
|
key: 1,
|
|
11368
11402
|
class: "lupa-stats-facet-summary-input"
|
|
11369
11403
|
};
|
|
@@ -11549,7 +11583,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11549
11583
|
};
|
|
11550
11584
|
return (_ctx, _cache) => {
|
|
11551
11585
|
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$
|
|
11586
|
+
!isInputVisible.value ? (openBlock(), createElementBlock("div", _hoisted_2$y, toDisplayString(statsSummary.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$o, [
|
|
11553
11587
|
createBaseVNode("div", null, [
|
|
11554
11588
|
rangeLabelFrom.value ? (openBlock(), createElementBlock("div", _hoisted_4$i, toDisplayString(rangeLabelFrom.value), 1)) : createCommentVNode("", true),
|
|
11555
11589
|
createBaseVNode("div", _hoisted_5$b, [
|
|
@@ -11617,7 +11651,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11617
11651
|
});
|
|
11618
11652
|
const _hoisted_1$N = { class: "lupa-term-checkbox-wrapper" };
|
|
11619
11653
|
const _hoisted_2$x = { class: "lupa-term-checkbox-label" };
|
|
11620
|
-
const _hoisted_3$
|
|
11654
|
+
const _hoisted_3$n = { class: "lupa-term-label" };
|
|
11621
11655
|
const _hoisted_4$h = {
|
|
11622
11656
|
key: 0,
|
|
11623
11657
|
class: "lupa-term-count"
|
|
@@ -11678,7 +11712,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11678
11712
|
}, null, 2)
|
|
11679
11713
|
]),
|
|
11680
11714
|
createBaseVNode("div", _hoisted_2$x, [
|
|
11681
|
-
createBaseVNode("span", _hoisted_3$
|
|
11715
|
+
createBaseVNode("span", _hoisted_3$n, toDisplayString(_ctx.item.title) + toDisplayString(" "), 1),
|
|
11682
11716
|
_ctx.options.showDocumentCount ? (openBlock(), createElementBlock("span", _hoisted_4$h, "(" + toDisplayString(_ctx.item.count) + ")", 1)) : createCommentVNode("", true)
|
|
11683
11717
|
])
|
|
11684
11718
|
]),
|
|
@@ -11703,7 +11737,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11703
11737
|
"data-cy": "lupa-search-result-facet-term-values"
|
|
11704
11738
|
};
|
|
11705
11739
|
const _hoisted_2$w = { key: 0 };
|
|
11706
|
-
const _hoisted_3$
|
|
11740
|
+
const _hoisted_3$m = ["placeholder"];
|
|
11707
11741
|
const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
11708
11742
|
__name: "HierarchyFacet",
|
|
11709
11743
|
props: {
|
|
@@ -11761,7 +11795,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
11761
11795
|
"data-cy": "lupa-term-filter",
|
|
11762
11796
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => termFilter.value = $event),
|
|
11763
11797
|
placeholder: _ctx.options.labels.facetFilter
|
|
11764
|
-
}, null, 8, _hoisted_3$
|
|
11798
|
+
}, null, 8, _hoisted_3$m), [
|
|
11765
11799
|
[vModelText, termFilter.value]
|
|
11766
11800
|
])
|
|
11767
11801
|
])) : createCommentVNode("", true),
|
|
@@ -12129,7 +12163,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12129
12163
|
class: "lupa-mobile-filter-sidebar"
|
|
12130
12164
|
};
|
|
12131
12165
|
const _hoisted_2$t = ["onClick"];
|
|
12132
|
-
const _hoisted_3$
|
|
12166
|
+
const _hoisted_3$l = { class: "lupa-mobile-sidebar-content" };
|
|
12133
12167
|
const _hoisted_4$g = { class: "lupa-sidebar-top" };
|
|
12134
12168
|
const _hoisted_5$9 = { class: "lupa-sidebar-title" };
|
|
12135
12169
|
const _hoisted_6$6 = {
|
|
@@ -12168,7 +12202,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12168
12202
|
class: "lupa-sidebar-close",
|
|
12169
12203
|
onClick: withModifiers(handleMobileToggle, ["stop"])
|
|
12170
12204
|
}, null, 8, _hoisted_2$t),
|
|
12171
|
-
createBaseVNode("div", _hoisted_3$
|
|
12205
|
+
createBaseVNode("div", _hoisted_3$l, [
|
|
12172
12206
|
createBaseVNode("div", _hoisted_4$g, [
|
|
12173
12207
|
createBaseVNode("div", _hoisted_5$9, [
|
|
12174
12208
|
createTextVNode(toDisplayString(sidebarTitle.value) + " ", 1),
|
|
@@ -12192,7 +12226,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12192
12226
|
});
|
|
12193
12227
|
const _hoisted_1$G = { id: "lupa-search-results-breadcrumbs" };
|
|
12194
12228
|
const _hoisted_2$s = ["href", "onClick"];
|
|
12195
|
-
const _hoisted_3$
|
|
12229
|
+
const _hoisted_3$k = {
|
|
12196
12230
|
key: 1,
|
|
12197
12231
|
class: "lupa-search-results-breadcrumb-text"
|
|
12198
12232
|
};
|
|
@@ -12236,7 +12270,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12236
12270
|
var _a;
|
|
12237
12271
|
return handleNavigation(e, (_a = breadcrumb == null ? void 0 : breadcrumb.link) != null ? _a : "");
|
|
12238
12272
|
}
|
|
12239
|
-
}, toDisplayString(getLabel(breadcrumb.label)), 9, _hoisted_2$s)) : (openBlock(), createElementBlock("span", _hoisted_3$
|
|
12273
|
+
}, toDisplayString(getLabel(breadcrumb.label)), 9, _hoisted_2$s)) : (openBlock(), createElementBlock("span", _hoisted_3$k, toDisplayString(getLabel(breadcrumb.label)), 1)),
|
|
12240
12274
|
index < breadcrumbsValue.value.length - 1 ? (openBlock(), createElementBlock("span", _hoisted_4$f, " / ")) : createCommentVNode("", true)
|
|
12241
12275
|
]);
|
|
12242
12276
|
}), 128))
|
|
@@ -12337,7 +12371,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12337
12371
|
key: 0,
|
|
12338
12372
|
class: "lupa-page-number-separator"
|
|
12339
12373
|
};
|
|
12340
|
-
const _hoisted_3$
|
|
12374
|
+
const _hoisted_3$j = ["onClick"];
|
|
12341
12375
|
const _hoisted_4$e = {
|
|
12342
12376
|
key: 0,
|
|
12343
12377
|
class: "lupa-page-number-separator"
|
|
@@ -12441,7 +12475,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12441
12475
|
page === _ctx.options.selectedPage ? "lupa-page-number-selected" : ""
|
|
12442
12476
|
]),
|
|
12443
12477
|
"data-cy": "lupa-page-number"
|
|
12444
|
-
}, toDisplayString(page), 11, _hoisted_3$
|
|
12478
|
+
}, toDisplayString(page), 11, _hoisted_3$j);
|
|
12445
12479
|
}), 128)),
|
|
12446
12480
|
showLastPage.value ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
12447
12481
|
showLastPageSeparator.value ? (openBlock(), createElementBlock("div", _hoisted_4$e, "...")) : createCommentVNode("", true),
|
|
@@ -12468,7 +12502,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12468
12502
|
"data-cy": "lupa-search-results-page-size"
|
|
12469
12503
|
};
|
|
12470
12504
|
const _hoisted_2$q = { id: "lupa-select" };
|
|
12471
|
-
const _hoisted_3$
|
|
12505
|
+
const _hoisted_3$i = { class: "lupa-select-label" };
|
|
12472
12506
|
const _hoisted_4$d = ["aria-label"];
|
|
12473
12507
|
const _sfc_main$E = /* @__PURE__ */ defineComponent({
|
|
12474
12508
|
__name: "SearchResultsPageSize",
|
|
@@ -12489,7 +12523,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12489
12523
|
return (_ctx, _cache) => {
|
|
12490
12524
|
return openBlock(), createElementBlock("div", _hoisted_1$B, [
|
|
12491
12525
|
createBaseVNode("div", _hoisted_2$q, [
|
|
12492
|
-
createBaseVNode("label", _hoisted_3$
|
|
12526
|
+
createBaseVNode("label", _hoisted_3$i, toDisplayString(_ctx.label), 1),
|
|
12493
12527
|
createBaseVNode("select", {
|
|
12494
12528
|
class: "lupa-select-dropdown",
|
|
12495
12529
|
"aria-label": _ctx.label,
|
|
@@ -12512,7 +12546,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12512
12546
|
class: "lupa-search-results-sort"
|
|
12513
12547
|
};
|
|
12514
12548
|
const _hoisted_2$p = { id: "lupa-select" };
|
|
12515
|
-
const _hoisted_3$
|
|
12549
|
+
const _hoisted_3$h = { class: "lupa-select-label" };
|
|
12516
12550
|
const _hoisted_4$c = ["aria-label"];
|
|
12517
12551
|
const _hoisted_5$8 = ["value"];
|
|
12518
12552
|
const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
@@ -12565,7 +12599,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12565
12599
|
return (_ctx, _cache) => {
|
|
12566
12600
|
return openBlock(), createElementBlock("div", _hoisted_1$A, [
|
|
12567
12601
|
createBaseVNode("div", _hoisted_2$p, [
|
|
12568
|
-
createBaseVNode("label", _hoisted_3$
|
|
12602
|
+
createBaseVNode("label", _hoisted_3$h, toDisplayString(_ctx.options.label), 1),
|
|
12569
12603
|
withDirectives(createBaseVNode("select", {
|
|
12570
12604
|
class: "lupa-select-dropdown",
|
|
12571
12605
|
"aria-label": _ctx.options.label,
|
|
@@ -12590,7 +12624,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12590
12624
|
});
|
|
12591
12625
|
const _hoisted_1$z = { class: "lupa-toolbar-left" };
|
|
12592
12626
|
const _hoisted_2$o = { key: 1 };
|
|
12593
|
-
const _hoisted_3$
|
|
12627
|
+
const _hoisted_3$g = { key: 3 };
|
|
12594
12628
|
const _hoisted_4$b = { key: 5 };
|
|
12595
12629
|
const _hoisted_5$7 = { class: "lupa-toolbar-right" };
|
|
12596
12630
|
const _hoisted_6$5 = { key: 1 };
|
|
@@ -12701,7 +12735,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12701
12735
|
label: searchSummaryLabel.value,
|
|
12702
12736
|
clearable: unref(hasAnyFilter) && showFilterClear.value,
|
|
12703
12737
|
onClear: handleClearAll
|
|
12704
|
-
}, null, 8, ["label", "clearable"])) : (openBlock(), createElementBlock("div", _hoisted_3$
|
|
12738
|
+
}, null, 8, ["label", "clearable"])) : (openBlock(), createElementBlock("div", _hoisted_3$g)),
|
|
12705
12739
|
displayPageSelect.value ? (openBlock(), createBlock(_sfc_main$F, {
|
|
12706
12740
|
key: 4,
|
|
12707
12741
|
options: paginationOptions.value.pageSelect,
|
|
@@ -12731,7 +12765,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12731
12765
|
});
|
|
12732
12766
|
const _hoisted_1$y = { class: "lupa-badge-title" };
|
|
12733
12767
|
const _hoisted_2$n = ["src"];
|
|
12734
|
-
const _hoisted_3$
|
|
12768
|
+
const _hoisted_3$f = { key: 1 };
|
|
12735
12769
|
const _hoisted_4$a = {
|
|
12736
12770
|
key: 0,
|
|
12737
12771
|
class: "lupa-badge-full-text"
|
|
@@ -12774,7 +12808,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
12774
12808
|
key: 0,
|
|
12775
12809
|
src: image.value
|
|
12776
12810
|
}, null, 8, _hoisted_2$n)) : createCommentVNode("", true),
|
|
12777
|
-
hasTitleText.value && showTitle.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
12811
|
+
hasTitleText.value && showTitle.value ? (openBlock(), createElementBlock("span", _hoisted_3$f, toDisplayString(_ctx.badge.titleText), 1)) : createCommentVNode("", true)
|
|
12778
12812
|
]),
|
|
12779
12813
|
hasAdditionalText.value ? (openBlock(), createElementBlock("span", _hoisted_4$a, toDisplayString(_ctx.badge.additionalText), 1)) : createCommentVNode("", true)
|
|
12780
12814
|
], 6);
|
|
@@ -13001,7 +13035,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13001
13035
|
});
|
|
13002
13036
|
const _hoisted_1$s = ["innerHTML"];
|
|
13003
13037
|
const _hoisted_2$l = ["title"];
|
|
13004
|
-
const _hoisted_3$
|
|
13038
|
+
const _hoisted_3$e = {
|
|
13005
13039
|
key: 0,
|
|
13006
13040
|
class: "lupa-search-results-product-title-text"
|
|
13007
13041
|
};
|
|
@@ -13045,7 +13079,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13045
13079
|
style: normalizeStyle(`-webkit-line-clamp: ${maxLines.value}`),
|
|
13046
13080
|
title: title.value
|
|
13047
13081
|
}, [
|
|
13048
|
-
!_ctx.options.link ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
13082
|
+
!_ctx.options.link ? (openBlock(), createElementBlock("span", _hoisted_3$e, toDisplayString(title.value), 1)) : createCommentVNode("", true),
|
|
13049
13083
|
_ctx.options.link ? (openBlock(), createElementBlock("a", {
|
|
13050
13084
|
key: 1,
|
|
13051
13085
|
href: _ctx.link,
|
|
@@ -13091,7 +13125,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13091
13125
|
});
|
|
13092
13126
|
const _hoisted_1$q = { id: "lupa-search-results-rating" };
|
|
13093
13127
|
const _hoisted_2$k = { class: "lupa-ratings" };
|
|
13094
|
-
const _hoisted_3$
|
|
13128
|
+
const _hoisted_3$d = { class: "lupa-ratings-base" };
|
|
13095
13129
|
const _hoisted_4$8 = ["innerHTML"];
|
|
13096
13130
|
const _hoisted_5$6 = { class: "lupa-rating-wrapper" };
|
|
13097
13131
|
const _hoisted_6$4 = ["innerHTML"];
|
|
@@ -13130,7 +13164,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13130
13164
|
return (_ctx, _cache) => {
|
|
13131
13165
|
return openBlock(), createElementBlock("div", _hoisted_1$q, [
|
|
13132
13166
|
createBaseVNode("div", _hoisted_2$k, [
|
|
13133
|
-
createBaseVNode("div", _hoisted_3$
|
|
13167
|
+
createBaseVNode("div", _hoisted_3$d, [
|
|
13134
13168
|
(openBlock(true), createElementBlock(Fragment, null, renderList(baseStars.value, (star, index) => {
|
|
13135
13169
|
return openBlock(), createElementBlock("div", {
|
|
13136
13170
|
key: index,
|
|
@@ -13218,7 +13252,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13218
13252
|
});
|
|
13219
13253
|
const _hoisted_1$n = { class: "lupa-search-results-add-to-cart-wrapper" };
|
|
13220
13254
|
const _hoisted_2$j = { class: "lupa-search-results-product-addtocart" };
|
|
13221
|
-
const _hoisted_3$
|
|
13255
|
+
const _hoisted_3$c = ["onClick", "disabled"];
|
|
13222
13256
|
const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
13223
13257
|
__name: "SearchResultsProductAddToCart",
|
|
13224
13258
|
props: {
|
|
@@ -13253,7 +13287,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13253
13287
|
class: normalizeClass(loading.value ? "lupa-add-to-cart-loading" : "lupa-add-to-cart"),
|
|
13254
13288
|
"data-cy": "lupa-add-to-cart",
|
|
13255
13289
|
disabled: !inStockValue.value || loading.value
|
|
13256
|
-
}, toDisplayString(label.value), 11, _hoisted_3$
|
|
13290
|
+
}, toDisplayString(label.value), 11, _hoisted_3$c)
|
|
13257
13291
|
])
|
|
13258
13292
|
]);
|
|
13259
13293
|
};
|
|
@@ -13261,7 +13295,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13261
13295
|
});
|
|
13262
13296
|
const _hoisted_1$m = ["innerHTML"];
|
|
13263
13297
|
const _hoisted_2$i = { key: 0 };
|
|
13264
|
-
const _hoisted_3$
|
|
13298
|
+
const _hoisted_3$b = { key: 1 };
|
|
13265
13299
|
const _hoisted_4$7 = { class: "lupa-search-box-custom-label" };
|
|
13266
13300
|
const _hoisted_5$5 = { class: "lupa-search-box-custom-text" };
|
|
13267
13301
|
const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
@@ -13306,7 +13340,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13306
13340
|
key: 1,
|
|
13307
13341
|
class: className.value
|
|
13308
13342
|
}, 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$
|
|
13343
|
+
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$i, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$b, [
|
|
13310
13344
|
createBaseVNode("div", _hoisted_4$7, toDisplayString(label.value), 1),
|
|
13311
13345
|
createBaseVNode("div", _hoisted_5$5, toDisplayString(text.value), 1)
|
|
13312
13346
|
]))
|
|
@@ -13345,7 +13379,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13345
13379
|
});
|
|
13346
13380
|
const _hoisted_1$k = { id: "lupa-search-results-rating" };
|
|
13347
13381
|
const _hoisted_2$h = ["innerHTML"];
|
|
13348
|
-
const _hoisted_3$
|
|
13382
|
+
const _hoisted_3$a = { class: "lupa-ratings" };
|
|
13349
13383
|
const _hoisted_4$6 = ["href"];
|
|
13350
13384
|
const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
13351
13385
|
__name: "SearchResultsProductSingleStarRating",
|
|
@@ -13380,7 +13414,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13380
13414
|
innerHTML: star.value,
|
|
13381
13415
|
class: "lupa-rating lupa-rating-highlighted"
|
|
13382
13416
|
}, null, 8, _hoisted_2$h),
|
|
13383
|
-
createBaseVNode("div", _hoisted_3$
|
|
13417
|
+
createBaseVNode("div", _hoisted_3$a, toDisplayString(rating.value), 1),
|
|
13384
13418
|
createBaseVNode("a", {
|
|
13385
13419
|
href: ratingLink.value,
|
|
13386
13420
|
class: "lupa-total-ratings"
|
|
@@ -13478,7 +13512,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13478
13512
|
key: 0,
|
|
13479
13513
|
class: "lupa-out-of-stock"
|
|
13480
13514
|
};
|
|
13481
|
-
const _hoisted_3$
|
|
13515
|
+
const _hoisted_3$9 = { class: "lupa-search-result-product-details-section" };
|
|
13482
13516
|
const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
13483
13517
|
__name: "SearchResultsProductCard",
|
|
13484
13518
|
props: {
|
|
@@ -13654,7 +13688,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13654
13688
|
}, null, 8, ["options"]),
|
|
13655
13689
|
((_a = labels.value) == null ? void 0 : _a.outOfStock) && !isInStock.value ? (openBlock(), createElementBlock("div", _hoisted_2$g, toDisplayString(labels.value.outOfStock), 1)) : createCommentVNode("", true)
|
|
13656
13690
|
], 8, _hoisted_1$j),
|
|
13657
|
-
createBaseVNode("div", _hoisted_3$
|
|
13691
|
+
createBaseVNode("div", _hoisted_3$9, [
|
|
13658
13692
|
(openBlock(true), createElementBlock(Fragment, null, renderList(detailElements.value, (element) => {
|
|
13659
13693
|
return openBlock(), createBlock(_sfc_main$l, {
|
|
13660
13694
|
class: "lupa-search-results-product-element",
|
|
@@ -13697,7 +13731,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13697
13731
|
"data-cy": "lupa-search-results-similar-queries"
|
|
13698
13732
|
};
|
|
13699
13733
|
const _hoisted_2$f = { class: "lupa-similar-queries-label" };
|
|
13700
|
-
const _hoisted_3$
|
|
13734
|
+
const _hoisted_3$8 = {
|
|
13701
13735
|
class: "lupa-similar-query-label",
|
|
13702
13736
|
"data-cy": "lupa-similar-query-label"
|
|
13703
13737
|
};
|
|
@@ -13742,7 +13776,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13742
13776
|
createBaseVNode("div", _hoisted_2$f, toDisplayString(_ctx.labels.similarQueries), 1),
|
|
13743
13777
|
(openBlock(true), createElementBlock(Fragment, null, renderList(similarQueries.value, (similarQuery, index) => {
|
|
13744
13778
|
return openBlock(), createElementBlock("div", { key: index }, [
|
|
13745
|
-
createBaseVNode("div", _hoisted_3$
|
|
13779
|
+
createBaseVNode("div", _hoisted_3$8, [
|
|
13746
13780
|
createBaseVNode("span", null, toDisplayString(similarQueryLabel.value), 1),
|
|
13747
13781
|
createBaseVNode("span", {
|
|
13748
13782
|
id: "lupa-similar-query-text-component",
|
|
@@ -13931,7 +13965,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13931
13965
|
"data-cy": "lupa-search-results-similar-results"
|
|
13932
13966
|
};
|
|
13933
13967
|
const _hoisted_2$c = { class: "lupa-similar-results-label" };
|
|
13934
|
-
const _hoisted_3$
|
|
13968
|
+
const _hoisted_3$7 = {
|
|
13935
13969
|
class: "lupa-products",
|
|
13936
13970
|
"data-cy": "lupa-products"
|
|
13937
13971
|
};
|
|
@@ -13953,7 +13987,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13953
13987
|
return (_ctx, _cache) => {
|
|
13954
13988
|
return openBlock(), createElementBlock("div", _hoisted_1$e, [
|
|
13955
13989
|
createBaseVNode("div", _hoisted_2$c, toDisplayString(_ctx.labels.similarResultsLabel), 1),
|
|
13956
|
-
createBaseVNode("div", _hoisted_3$
|
|
13990
|
+
createBaseVNode("div", _hoisted_3$7, [
|
|
13957
13991
|
(openBlock(true), createElementBlock(Fragment, null, renderList(similarResults.value.items, (product, index) => {
|
|
13958
13992
|
return openBlock(), createBlock(_sfc_main$k, {
|
|
13959
13993
|
style: normalizeStyle(_ctx.columnSize),
|
|
@@ -13972,7 +14006,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
13972
14006
|
class: "lupa-products",
|
|
13973
14007
|
"data-cy": "lupa-products"
|
|
13974
14008
|
};
|
|
13975
|
-
const _hoisted_3$
|
|
14009
|
+
const _hoisted_3$6 = {
|
|
13976
14010
|
key: 0,
|
|
13977
14011
|
class: "lupa-empty-results",
|
|
13978
14012
|
"data-cy": "lupa-no-results-in-page"
|
|
@@ -14135,7 +14169,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14135
14169
|
}, null, 8, ["style", "product", "options"]);
|
|
14136
14170
|
}), 128))
|
|
14137
14171
|
]),
|
|
14138
|
-
unref(isPageEmpty) && _ctx.options.labels.noItemsInPage ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
14172
|
+
unref(isPageEmpty) && _ctx.options.labels.noItemsInPage ? (openBlock(), createElementBlock("div", _hoisted_3$6, [
|
|
14139
14173
|
createTextVNode(toDisplayString(_ctx.options.labels.noItemsInPage) + " ", 1),
|
|
14140
14174
|
_ctx.options.labels.backToFirstPage ? (openBlock(), createElementBlock("span", {
|
|
14141
14175
|
key: 0,
|
|
@@ -14181,7 +14215,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14181
14215
|
key: 0,
|
|
14182
14216
|
class: "lupa-category-back"
|
|
14183
14217
|
};
|
|
14184
|
-
const _hoisted_3$
|
|
14218
|
+
const _hoisted_3$5 = ["href"];
|
|
14185
14219
|
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
14186
14220
|
__name: "CategoryTopFilters",
|
|
14187
14221
|
props: {
|
|
@@ -14220,7 +14254,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14220
14254
|
"data-cy": "lupa-category-back",
|
|
14221
14255
|
href: backUrlLink.value,
|
|
14222
14256
|
onClick: handleNavigationBack
|
|
14223
|
-
}, toDisplayString(backTitle.value), 9, _hoisted_3$
|
|
14257
|
+
}, toDisplayString(backTitle.value), 9, _hoisted_3$5)
|
|
14224
14258
|
])) : createCommentVNode("", true),
|
|
14225
14259
|
createVNode(_sfc_main$C, {
|
|
14226
14260
|
class: "lupa-toolbar-mobile",
|
|
@@ -14241,7 +14275,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14241
14275
|
id: "lupa-search-results",
|
|
14242
14276
|
class: "top-layout-wrapper"
|
|
14243
14277
|
};
|
|
14244
|
-
const _hoisted_3$
|
|
14278
|
+
const _hoisted_3$4 = { class: "search-content" };
|
|
14245
14279
|
const _hoisted_4$3 = { id: "lupa-search-results" };
|
|
14246
14280
|
const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
14247
14281
|
__name: "SearchResults",
|
|
@@ -14480,7 +14514,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
14480
14514
|
ref_key: "searchResultsFilters",
|
|
14481
14515
|
ref: searchResultsFilters
|
|
14482
14516
|
}, null, 8, ["options"])) : createCommentVNode("", true),
|
|
14483
|
-
createBaseVNode("div", _hoisted_3$
|
|
14517
|
+
createBaseVNode("div", _hoisted_3$4, [
|
|
14484
14518
|
createVNode(_sfc_main$Z, { labels: didYouMeanLabels.value }, null, 8, ["labels"]),
|
|
14485
14519
|
createVNode(_sfc_main$X, {
|
|
14486
14520
|
options: _ctx.options,
|
|
@@ -20971,12 +21005,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
20971
21005
|
});
|
|
20972
21006
|
const _hoisted_1$7 = { class: "lupa-chat-spinner" };
|
|
20973
21007
|
const _hoisted_2$5 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20974
|
-
const _hoisted_3$
|
|
21008
|
+
const _hoisted_3$3 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20975
21009
|
const _hoisted_4$2 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20976
21010
|
const _hoisted_5$2 = /* @__PURE__ */ createBaseVNode("div", null, null, -1);
|
|
20977
21011
|
const _hoisted_6$1 = [
|
|
20978
21012
|
_hoisted_2$5,
|
|
20979
|
-
_hoisted_3$
|
|
21013
|
+
_hoisted_3$3,
|
|
20980
21014
|
_hoisted_4$2,
|
|
20981
21015
|
_hoisted_5$2
|
|
20982
21016
|
];
|
|
@@ -21000,7 +21034,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21000
21034
|
});
|
|
21001
21035
|
const _hoisted_1$6 = { class: "lupa-chat-input-container" };
|
|
21002
21036
|
const _hoisted_2$4 = { id: "lupa-search-box-input" };
|
|
21003
|
-
const _hoisted_3$
|
|
21037
|
+
const _hoisted_3$2 = {
|
|
21004
21038
|
key: 0,
|
|
21005
21039
|
class: "lupa-chat-form-submit"
|
|
21006
21040
|
};
|
|
@@ -21036,7 +21070,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21036
21070
|
[vModelText, inputValue.value]
|
|
21037
21071
|
])
|
|
21038
21072
|
]),
|
|
21039
|
-
!_ctx.disabled ? (openBlock(), createElementBlock("button", _hoisted_3$
|
|
21073
|
+
!_ctx.disabled ? (openBlock(), createElementBlock("button", _hoisted_3$2, "Ask LupaChat")) : (openBlock(), createBlock(_sfc_main$7, {
|
|
21040
21074
|
key: 1,
|
|
21041
21075
|
small: true
|
|
21042
21076
|
}))
|
|
@@ -21203,7 +21237,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21203
21237
|
});
|
|
21204
21238
|
const _hoisted_1$4 = { class: "lupa-chat-content-entry-phrase" };
|
|
21205
21239
|
const _hoisted_2$3 = { class: "lupa-chat-phrase-title" };
|
|
21206
|
-
const _hoisted_3$
|
|
21240
|
+
const _hoisted_3$1 = {
|
|
21207
21241
|
key: 0,
|
|
21208
21242
|
class: "alert"
|
|
21209
21243
|
};
|
|
@@ -21304,7 +21338,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21304
21338
|
createBaseVNode("div", _hoisted_2$3, [
|
|
21305
21339
|
createBaseVNode("h3", null, toDisplayString(displayPhrase.value), 1),
|
|
21306
21340
|
createBaseVNode("sub", null, toDisplayString(usedAlternativePhrases.value.join(", ")), 1),
|
|
21307
|
-
usedPartialResults.value ? (openBlock(), createElementBlock("sub", _hoisted_3$
|
|
21341
|
+
usedPartialResults.value ? (openBlock(), createElementBlock("sub", _hoisted_3$1, "Including partial matches - which might not be what you are looking for")) : createCommentVNode("", true)
|
|
21308
21342
|
]),
|
|
21309
21343
|
createBaseVNode("div", null, [
|
|
21310
21344
|
createVNode(_sfc_main$5, {
|
|
@@ -21323,7 +21357,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21323
21357
|
});
|
|
21324
21358
|
const _hoisted_1$3 = { class: "lupa-chat-best-matches lupa-chat-content-entry" };
|
|
21325
21359
|
const _hoisted_2$2 = /* @__PURE__ */ createBaseVNode("h3", null, "Best matches", -1);
|
|
21326
|
-
const
|
|
21360
|
+
const MAX_SOURCES_FOR_BEST_ITEM_MATCHING = 250;
|
|
21327
21361
|
const _sfc_main$3$1 = /* @__PURE__ */ defineComponent({
|
|
21328
21362
|
__name: "ChatContentEntry",
|
|
21329
21363
|
props: {
|
|
@@ -21353,20 +21387,18 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21353
21387
|
return (_a = props.options.displayOptions.titleKey) != null ? _a : "title";
|
|
21354
21388
|
});
|
|
21355
21389
|
const loadFinalRecommendations = () => __async(this, null, function* () {
|
|
21356
|
-
var _a;
|
|
21390
|
+
var _a, _b;
|
|
21357
21391
|
try {
|
|
21358
|
-
const productResultStrings = loadedResults.value.map(
|
|
21359
|
-
|
|
21360
|
-
|
|
21361
|
-
|
|
21362
|
-
}
|
|
21363
|
-
);
|
|
21392
|
+
const productResultStrings = (_a = loadedResults.value.map((result) => {
|
|
21393
|
+
var _a2, _b2;
|
|
21394
|
+
return (_b2 = (_a2 = result[titleKey.value]) == null ? void 0 : _a2.toString()) != null ? _b2 : "";
|
|
21395
|
+
})) == null ? void 0 : _a.slice(0, MAX_SOURCES_FOR_BEST_ITEM_MATCHING);
|
|
21364
21396
|
const { products } = yield ChatService.suggestBestProductMatches(
|
|
21365
21397
|
props.options.sdkOptions,
|
|
21366
21398
|
{
|
|
21367
21399
|
initialQuery: props.entry.userInput,
|
|
21368
21400
|
productStrings: productResultStrings,
|
|
21369
|
-
messageHistory: (
|
|
21401
|
+
messageHistory: (_b = props.history) != null ? _b : [],
|
|
21370
21402
|
queryKey: props.options.displayOptions.queryKey
|
|
21371
21403
|
},
|
|
21372
21404
|
props.options.chatSettings
|
|
@@ -21379,13 +21411,9 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21379
21411
|
});
|
|
21380
21412
|
const bestMatchProducts = computed(() => {
|
|
21381
21413
|
return bestMatches.value.map((productName) => {
|
|
21382
|
-
return loadedResults.value
|
|
21414
|
+
return findClosestStringValue(productName, loadedResults.value, titleKey.value);
|
|
21383
21415
|
}).filter(Boolean);
|
|
21384
21416
|
});
|
|
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
21417
|
return (_ctx, _cache) => {
|
|
21390
21418
|
return openBlock(), createElementBlock("div", null, [
|
|
21391
21419
|
createBaseVNode("ul", null, [
|
|
@@ -21405,13 +21433,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21405
21433
|
]),
|
|
21406
21434
|
createBaseVNode("section", _hoisted_1$3, [
|
|
21407
21435
|
_hoisted_2$2,
|
|
21408
|
-
explanation.value ? (openBlock(), createElementBlock("p", _hoisted_3$1, toDisplayString(explanation.value), 1)) : createCommentVNode("", true),
|
|
21409
21436
|
loading.value ? (openBlock(), createBlock(_sfc_main$7, {
|
|
21410
|
-
key:
|
|
21437
|
+
key: 0,
|
|
21411
21438
|
message: "Selecting the best matches for you. This might take a few seconds."
|
|
21412
21439
|
})) : createCommentVNode("", true),
|
|
21413
21440
|
bestMatches.value.length ? (openBlock(), createBlock(_sfc_main$5, {
|
|
21414
|
-
key:
|
|
21441
|
+
key: 1,
|
|
21415
21442
|
"search-results": bestMatchProducts.value,
|
|
21416
21443
|
options: _ctx.options.displayOptions
|
|
21417
21444
|
}, null, 8, ["search-results", "options"])) : createCommentVNode("", true)
|