@getlupa/client 1.23.2 → 1.24.0
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 +397 -201
- package/dist/lupaSearch.js +397 -201
- package/dist/lupaSearch.mjs +397 -201
- package/dist/lupaSearch.umd.js +397 -201
- package/dist/style.css +1 -1
- package/package.json +2 -2
package/dist/lupaSearch.js
CHANGED
|
@@ -10972,11 +10972,11 @@ var parsePath = (string) => {
|
|
|
10972
10972
|
return result2;
|
|
10973
10973
|
};
|
|
10974
10974
|
init_esm_shims();
|
|
10975
|
-
function simpleTransformation(isApplicable, annotation,
|
|
10975
|
+
function simpleTransformation(isApplicable, annotation, transform2, untransform) {
|
|
10976
10976
|
return {
|
|
10977
10977
|
isApplicable,
|
|
10978
10978
|
annotation,
|
|
10979
|
-
transform,
|
|
10979
|
+
transform: transform2,
|
|
10980
10980
|
untransform
|
|
10981
10981
|
};
|
|
10982
10982
|
}
|
|
@@ -11037,11 +11037,11 @@ var simpleRules = [
|
|
|
11037
11037
|
}, Number),
|
|
11038
11038
|
simpleTransformation(isURL, "URL", (v) => v.toString(), (v) => new URL(v))
|
|
11039
11039
|
];
|
|
11040
|
-
function compositeTransformation(isApplicable, annotation,
|
|
11040
|
+
function compositeTransformation(isApplicable, annotation, transform2, untransform) {
|
|
11041
11041
|
return {
|
|
11042
11042
|
isApplicable,
|
|
11043
11043
|
annotation,
|
|
11044
|
-
transform,
|
|
11044
|
+
transform: transform2,
|
|
11045
11045
|
untransform
|
|
11046
11046
|
};
|
|
11047
11047
|
}
|
|
@@ -11990,33 +11990,6 @@ const addCustomParams = (url, customParams) => {
|
|
|
11990
11990
|
const separator = url.includes("?") ? "&" : "?";
|
|
11991
11991
|
return url + separator + e(customParams);
|
|
11992
11992
|
};
|
|
11993
|
-
var __awaiter = function(thisArg, _arguments, P, generator) {
|
|
11994
|
-
function adopt(value) {
|
|
11995
|
-
return value instanceof P ? value : new P(function(resolve2) {
|
|
11996
|
-
resolve2(value);
|
|
11997
|
-
});
|
|
11998
|
-
}
|
|
11999
|
-
return new (P || (P = Promise))(function(resolve2, reject) {
|
|
12000
|
-
function fulfilled(value) {
|
|
12001
|
-
try {
|
|
12002
|
-
step(generator.next(value));
|
|
12003
|
-
} catch (e2) {
|
|
12004
|
-
reject(e2);
|
|
12005
|
-
}
|
|
12006
|
-
}
|
|
12007
|
-
function rejected(value) {
|
|
12008
|
-
try {
|
|
12009
|
-
step(generator["throw"](value));
|
|
12010
|
-
} catch (e2) {
|
|
12011
|
-
reject(e2);
|
|
12012
|
-
}
|
|
12013
|
-
}
|
|
12014
|
-
function step(result2) {
|
|
12015
|
-
result2.done ? resolve2(result2.value) : adopt(result2.value).then(fulfilled, rejected);
|
|
12016
|
-
}
|
|
12017
|
-
step((generator = generator.apply(thisArg, [])).next());
|
|
12018
|
-
});
|
|
12019
|
-
};
|
|
12020
11993
|
const defaultConfig = {
|
|
12021
11994
|
method: "POST",
|
|
12022
11995
|
headers: { "Content-Type": "application/json" }
|
|
@@ -12027,7 +12000,7 @@ const customRequestConfig = ({ customHeaders }) => {
|
|
|
12027
12000
|
headers: Object.assign(Object.assign({}, defaultConfig.headers), customHeaders !== null && customHeaders !== void 0 ? customHeaders : {})
|
|
12028
12001
|
};
|
|
12029
12002
|
};
|
|
12030
|
-
const searchCustom = (query, options) =>
|
|
12003
|
+
const searchCustom = (query, options) => __async2(null, null, function* () {
|
|
12031
12004
|
var _a25;
|
|
12032
12005
|
const res = yield fetch(options.customUrl, Object.assign(Object.assign({}, customRequestConfig({ customHeaders: options.customHeaders })), { body: JSON.stringify(Object.assign({ publicQuery: query }, (_a25 = options.customPayload) !== null && _a25 !== void 0 ? _a25 : {})) }));
|
|
12033
12006
|
if (res.status < 400) {
|
|
@@ -12037,9 +12010,9 @@ const searchCustom = (query, options) => __awaiter(void 0, void 0, void 0, funct
|
|
|
12037
12010
|
const errors = yield res.json();
|
|
12038
12011
|
return { success: false, errors };
|
|
12039
12012
|
});
|
|
12040
|
-
const suggestCustom = (query, options) =>
|
|
12041
|
-
var
|
|
12042
|
-
const res = yield fetch(options.customUrl, Object.assign(Object.assign({}, customRequestConfig({ customHeaders: options.customHeaders })), { body: JSON.stringify(Object.assign({ publicQuery: query }, (
|
|
12013
|
+
const suggestCustom = (query, options) => __async2(null, null, function* () {
|
|
12014
|
+
var _a25;
|
|
12015
|
+
const res = yield fetch(options.customUrl, Object.assign(Object.assign({}, customRequestConfig({ customHeaders: options.customHeaders })), { body: JSON.stringify(Object.assign({ publicQuery: query }, (_a25 = options.customPayload) !== null && _a25 !== void 0 ? _a25 : {})) }));
|
|
12043
12016
|
if (res.status < 400) {
|
|
12044
12017
|
const items = yield res.json();
|
|
12045
12018
|
return { items, success: true };
|
|
@@ -12047,7 +12020,7 @@ const suggestCustom = (query, options) => __awaiter(void 0, void 0, void 0, func
|
|
|
12047
12020
|
const errors = yield res.json();
|
|
12048
12021
|
return { success: false, errors };
|
|
12049
12022
|
});
|
|
12050
|
-
const search = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
12023
|
+
const search = (queryKey, query, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12051
12024
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}`;
|
|
12052
12025
|
const url = addCustomParams(endpoint, customParams);
|
|
12053
12026
|
const res = yield fetch(url, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(query) }));
|
|
@@ -12058,7 +12031,7 @@ const search = (queryKey, query, environment, customBaseUrl, customParams) => __
|
|
|
12058
12031
|
const errors = yield res.json();
|
|
12059
12032
|
return { success: false, errors };
|
|
12060
12033
|
});
|
|
12061
|
-
const facets = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
12034
|
+
const facets = (queryKey, query, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12062
12035
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}/facets`;
|
|
12063
12036
|
const url = addCustomParams(endpoint, customParams);
|
|
12064
12037
|
const res = yield fetch(url, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(query) }));
|
|
@@ -12069,7 +12042,7 @@ const facets = (queryKey, query, environment, customBaseUrl, customParams) => __
|
|
|
12069
12042
|
const errors = yield res.json();
|
|
12070
12043
|
return { success: false, errors };
|
|
12071
12044
|
});
|
|
12072
|
-
const refiners = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
12045
|
+
const refiners = (queryKey, query, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12073
12046
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}/refiners`;
|
|
12074
12047
|
const url = addCustomParams(endpoint, customParams);
|
|
12075
12048
|
const res = yield fetch(url, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(query) }));
|
|
@@ -12080,7 +12053,7 @@ const refiners = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
|
12080
12053
|
const errors = yield res.json();
|
|
12081
12054
|
return { success: false, errors };
|
|
12082
12055
|
});
|
|
12083
|
-
const relatedQueries = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
12056
|
+
const relatedQueries = (queryKey, query, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12084
12057
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}/related`;
|
|
12085
12058
|
const url = addCustomParams(endpoint, customParams);
|
|
12086
12059
|
const res = yield fetch(url, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(query) }));
|
|
@@ -12091,7 +12064,7 @@ const relatedQueries = (queryKey, query, environment, customBaseUrl, customParam
|
|
|
12091
12064
|
const errors = yield res.json();
|
|
12092
12065
|
return { success: false, errors };
|
|
12093
12066
|
});
|
|
12094
|
-
const queryByIds = (queryKey, ids, environment, customBaseUrl, customParams) =>
|
|
12067
|
+
const queryByIds = (queryKey, ids, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12095
12068
|
const idParam = ids.map((id) => `ids=${id}`).join("&");
|
|
12096
12069
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}/ids?${idParam}`;
|
|
12097
12070
|
const url = addCustomParams(endpoint, customParams);
|
|
@@ -12103,7 +12076,7 @@ const queryByIds = (queryKey, ids, environment, customBaseUrl, customParams) =>
|
|
|
12103
12076
|
const errors = yield res.json();
|
|
12104
12077
|
return { success: false, errors };
|
|
12105
12078
|
});
|
|
12106
|
-
const recommendForSingleId = (queryKey, recommendForId, filters, environment, customBaseUrl, customParams) =>
|
|
12079
|
+
const recommendForSingleId = (queryKey, recommendForId, filters, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12107
12080
|
let endpoint = `${getApiUrl$1(environment, customBaseUrl)}recommendations/document/${recommendForId}?recommendationQueryKey=${queryKey}`;
|
|
12108
12081
|
if (filters) {
|
|
12109
12082
|
endpoint += `&${e({ filters })}`;
|
|
@@ -12117,7 +12090,7 @@ const recommendForSingleId = (queryKey, recommendForId, filters, environment, cu
|
|
|
12117
12090
|
const errors = yield res.json();
|
|
12118
12091
|
return { success: false, errors };
|
|
12119
12092
|
});
|
|
12120
|
-
const recommendForMultipleIds = (queryKey, recommendForIds, filters, environment, customBaseUrl, customParams) =>
|
|
12093
|
+
const recommendForMultipleIds = (queryKey, recommendForIds, filters, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12121
12094
|
const limitedRecommendForIds = recommendForIds.slice(0, 20);
|
|
12122
12095
|
let endpoint = `${getApiUrl$1(environment, customBaseUrl)}recommendations/documentsByMultipleIds?recommendationQueryKey=${queryKey}&itemId[]=${limitedRecommendForIds.join("&itemId[]=")}`;
|
|
12123
12096
|
if (filters) {
|
|
@@ -12132,10 +12105,10 @@ const recommendForMultipleIds = (queryKey, recommendForIds, filters, environment
|
|
|
12132
12105
|
const errors = yield res.json();
|
|
12133
12106
|
return { success: false, errors };
|
|
12134
12107
|
});
|
|
12135
|
-
const recommend = (queryKey, recommendForId, filters, environment, customBaseUrl, customParams) =>
|
|
12108
|
+
const recommend = (queryKey, recommendForId, filters, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12136
12109
|
return Array.isArray(recommendForId) ? yield recommendForMultipleIds(queryKey, recommendForId, filters, environment, customBaseUrl, customParams) : yield recommendForSingleId(queryKey, recommendForId, filters, environment, customBaseUrl, customParams);
|
|
12137
12110
|
});
|
|
12138
|
-
const suggest = (queryKey, query, environment, customBaseUrl, customParams) =>
|
|
12111
|
+
const suggest = (queryKey, query, environment, customBaseUrl, customParams) => __async2(null, null, function* () {
|
|
12139
12112
|
const endpoint = `${getApiUrl$1(environment, customBaseUrl)}query/${queryKey}`;
|
|
12140
12113
|
const url = addCustomParams(endpoint, customParams);
|
|
12141
12114
|
const res = yield fetch(url, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(query) }));
|
|
@@ -12146,18 +12119,18 @@ const suggest = (queryKey, query, environment, customBaseUrl, customParams) => _
|
|
|
12146
12119
|
const errors = yield res.json();
|
|
12147
12120
|
return { success: false, errors };
|
|
12148
12121
|
});
|
|
12149
|
-
const track$1 = (queryKey, event, environment, customBaseUrl) =>
|
|
12122
|
+
const track$1 = (queryKey, event, environment, customBaseUrl) => __async2(null, null, function* () {
|
|
12150
12123
|
try {
|
|
12151
12124
|
const res = yield fetch(`${getApiUrl$1(environment, customBaseUrl)}events`, Object.assign(Object.assign({}, defaultConfig), { body: JSON.stringify(Object.assign({ queryKey }, event)) }));
|
|
12152
12125
|
if (res.status < 400) {
|
|
12153
12126
|
return { success: false };
|
|
12154
12127
|
}
|
|
12155
12128
|
return res.json();
|
|
12156
|
-
} catch (
|
|
12129
|
+
} catch (_a25) {
|
|
12157
12130
|
return { success: false };
|
|
12158
12131
|
}
|
|
12159
12132
|
});
|
|
12160
|
-
const loadRedirectionRules = (queryKey, environment, customBaseUrl) =>
|
|
12133
|
+
const loadRedirectionRules = (queryKey, environment, customBaseUrl) => __async2(null, null, function* () {
|
|
12161
12134
|
const res = yield fetch(`${getApiUrl$1(environment, customBaseUrl)}redirections/${queryKey}`, Object.assign(Object.assign({}, defaultConfig), { method: "GET" }));
|
|
12162
12135
|
if (res.status < 400) {
|
|
12163
12136
|
return res.json();
|
|
@@ -12165,27 +12138,164 @@ const loadRedirectionRules = (queryKey, environment, customBaseUrl) => __awaiter
|
|
|
12165
12138
|
const errors = yield res.json();
|
|
12166
12139
|
return { success: false, errors };
|
|
12167
12140
|
});
|
|
12141
|
+
const FORBIDDEN_KEYS = /* @__PURE__ */ new Set(["__proto__", "prototype", "constructor"]);
|
|
12142
|
+
const isSafeKey = (key) => !FORBIDDEN_KEYS.has(key);
|
|
12143
|
+
const toPath = (key) => key.split(".").filter(Boolean);
|
|
12144
|
+
const isObjectLike = (v) => typeof v === "object" && v !== null;
|
|
12145
|
+
const hasByPath = (obj, path) => {
|
|
12146
|
+
let cur = obj;
|
|
12147
|
+
for (let i = 0; i < path.length; i++) {
|
|
12148
|
+
const k = path[i];
|
|
12149
|
+
if (!isSafeKey(k) || !isObjectLike(cur)) {
|
|
12150
|
+
return false;
|
|
12151
|
+
}
|
|
12152
|
+
if (!Object.prototype.hasOwnProperty.call(cur, k)) {
|
|
12153
|
+
return false;
|
|
12154
|
+
}
|
|
12155
|
+
cur = cur[k];
|
|
12156
|
+
}
|
|
12157
|
+
return true;
|
|
12158
|
+
};
|
|
12159
|
+
const getByPath = (obj, path) => {
|
|
12160
|
+
let cur = obj;
|
|
12161
|
+
for (const k of path) {
|
|
12162
|
+
if (!isSafeKey(k) || !isObjectLike(cur)) {
|
|
12163
|
+
return void 0;
|
|
12164
|
+
}
|
|
12165
|
+
cur = cur[k];
|
|
12166
|
+
}
|
|
12167
|
+
return cur;
|
|
12168
|
+
};
|
|
12169
|
+
const setByPath = (obj, path, value) => {
|
|
12170
|
+
if (!path.length) {
|
|
12171
|
+
return;
|
|
12172
|
+
}
|
|
12173
|
+
let cur = obj;
|
|
12174
|
+
for (let i = 0; i < path.length - 1; i++) {
|
|
12175
|
+
const k = path[i];
|
|
12176
|
+
if (!isSafeKey(k) || !isObjectLike(cur)) {
|
|
12177
|
+
return;
|
|
12178
|
+
}
|
|
12179
|
+
const next = cur[k];
|
|
12180
|
+
if (!isObjectLike(next))
|
|
12181
|
+
cur[k] = {};
|
|
12182
|
+
cur = cur[k];
|
|
12183
|
+
}
|
|
12184
|
+
const lastKey = path[path.length - 1];
|
|
12185
|
+
if (!isSafeKey(lastKey) || !isObjectLike(cur)) {
|
|
12186
|
+
return;
|
|
12187
|
+
}
|
|
12188
|
+
cur[lastKey] = value;
|
|
12189
|
+
};
|
|
12190
|
+
const unsetByPath = (obj, path) => {
|
|
12191
|
+
if (!path.length) {
|
|
12192
|
+
return;
|
|
12193
|
+
}
|
|
12194
|
+
let cur = obj;
|
|
12195
|
+
for (let i = 0; i < path.length - 1; i++) {
|
|
12196
|
+
const k = path[i];
|
|
12197
|
+
if (!isSafeKey(k) || !isObjectLike(cur)) {
|
|
12198
|
+
return;
|
|
12199
|
+
}
|
|
12200
|
+
if (!Object.prototype.hasOwnProperty.call(cur, k)) {
|
|
12201
|
+
return;
|
|
12202
|
+
}
|
|
12203
|
+
cur = cur[k];
|
|
12204
|
+
}
|
|
12205
|
+
const lastKey = path[path.length - 1];
|
|
12206
|
+
if (!isSafeKey(lastKey) || !isObjectLike(cur)) {
|
|
12207
|
+
return;
|
|
12208
|
+
}
|
|
12209
|
+
delete cur[lastKey];
|
|
12210
|
+
};
|
|
12211
|
+
const transformItems = (items, transformOptions) => {
|
|
12212
|
+
var _a25;
|
|
12213
|
+
const mapping = (_a25 = transformOptions === null || transformOptions === void 0 ? void 0 : transformOptions.transform) === null || _a25 === void 0 ? void 0 : _a25.fieldNames;
|
|
12214
|
+
if (!(items === null || items === void 0 ? void 0 : items.length) || !mapping) {
|
|
12215
|
+
return items;
|
|
12216
|
+
}
|
|
12217
|
+
return items.map((item) => {
|
|
12218
|
+
for (const [originalField, newField] of Object.entries(mapping)) {
|
|
12219
|
+
const fromPath = toPath(originalField);
|
|
12220
|
+
const toPathArr = toPath(newField);
|
|
12221
|
+
if (!fromPath.length || !toPathArr.length) {
|
|
12222
|
+
continue;
|
|
12223
|
+
}
|
|
12224
|
+
if (!hasByPath(item, fromPath)) {
|
|
12225
|
+
continue;
|
|
12226
|
+
}
|
|
12227
|
+
const value = getByPath(item, fromPath);
|
|
12228
|
+
setByPath(item, toPathArr, value);
|
|
12229
|
+
unsetByPath(item, fromPath);
|
|
12230
|
+
}
|
|
12231
|
+
return item;
|
|
12232
|
+
});
|
|
12233
|
+
};
|
|
12234
|
+
const transform = (result2, transformOptions) => {
|
|
12235
|
+
var _a25, _b25, _c, _d, _e, _f, _g;
|
|
12236
|
+
let transformedResult = result2;
|
|
12237
|
+
if (!result2 || !(transformOptions === null || transformOptions === void 0 ? void 0 : transformOptions.transform)) {
|
|
12238
|
+
return result2;
|
|
12239
|
+
}
|
|
12240
|
+
if ((_a25 = result2 === null || result2 === void 0 ? void 0 : result2.items) === null || _a25 === void 0 ? void 0 : _a25.length) {
|
|
12241
|
+
transformedResult = Object.assign(Object.assign({}, transformedResult), { items: transformItems(transformedResult.items, transformOptions) });
|
|
12242
|
+
}
|
|
12243
|
+
if ((_b25 = result2 === null || result2 === void 0 ? void 0 : result2.similarQueries) === null || _b25 === void 0 ? void 0 : _b25.length) {
|
|
12244
|
+
transformedResult = Object.assign(Object.assign({}, transformedResult), { similarQueries: (_c = transformedResult.similarQueries) === null || _c === void 0 ? void 0 : _c.map((similarQuery) => Object.assign(Object.assign({}, similarQuery), { items: transformItems(similarQuery.items, transformOptions) })) });
|
|
12245
|
+
}
|
|
12246
|
+
if ((_e = (_d = result2 === null || result2 === void 0 ? void 0 : result2.similarResults) === null || _d === void 0 ? void 0 : _d.items) === null || _e === void 0 ? void 0 : _e.length) {
|
|
12247
|
+
transformedResult = Object.assign(Object.assign({}, transformedResult), { similarResults: Object.assign(Object.assign({}, transformedResult.similarResults), { items: transformItems(transformedResult.similarResults.items, transformOptions) }) });
|
|
12248
|
+
}
|
|
12249
|
+
if ((_f = result2.relatedQueries) === null || _f === void 0 ? void 0 : _f.length) {
|
|
12250
|
+
transformedResult = Object.assign(Object.assign({}, transformedResult), { relatedQueries: (_g = transformedResult.relatedQueries) === null || _g === void 0 ? void 0 : _g.map((relatedQuery) => Object.assign(Object.assign({}, relatedQuery), { topItems: transformItems(relatedQuery.topItems, transformOptions) })) });
|
|
12251
|
+
}
|
|
12252
|
+
return transformedResult;
|
|
12253
|
+
};
|
|
12254
|
+
const transformSearchQueryResult = (result2, transformOptions) => {
|
|
12255
|
+
if (result2.success === false) {
|
|
12256
|
+
return result2;
|
|
12257
|
+
}
|
|
12258
|
+
return transform(result2, transformOptions);
|
|
12259
|
+
};
|
|
12260
|
+
const transformSearchQueryRefinersResult = (result2, transformOptions) => {
|
|
12261
|
+
if (result2.success === false) {
|
|
12262
|
+
return result2;
|
|
12263
|
+
}
|
|
12264
|
+
return transform(result2, transformOptions);
|
|
12265
|
+
};
|
|
12266
|
+
const transformRelatedQueries = (result2, transformOptions) => {
|
|
12267
|
+
if (result2.success === false) {
|
|
12268
|
+
return result2;
|
|
12269
|
+
}
|
|
12270
|
+
return transform(result2, transformOptions);
|
|
12271
|
+
};
|
|
12168
12272
|
const LupaSearchSdk = {
|
|
12169
|
-
query: (queryKey, publicQuery, options = null) => {
|
|
12273
|
+
query: (queryKey, publicQuery, options = null) => __async2(null, null, function* () {
|
|
12170
12274
|
if (options === null || options === void 0 ? void 0 : options.customUrl) {
|
|
12171
|
-
|
|
12275
|
+
const result3 = yield searchCustom(publicQuery, options);
|
|
12276
|
+
return transformSearchQueryResult(result3, options);
|
|
12172
12277
|
}
|
|
12173
|
-
|
|
12174
|
-
|
|
12278
|
+
const result2 = yield search(queryKey, publicQuery, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl, options === null || options === void 0 ? void 0 : options.customParams);
|
|
12279
|
+
return transformSearchQueryResult(result2, options);
|
|
12280
|
+
}),
|
|
12175
12281
|
queryFacets: (queryKey, publicQuery, options = null) => {
|
|
12176
12282
|
return facets(queryKey, publicQuery, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl, options === null || options === void 0 ? void 0 : options.customParams);
|
|
12177
12283
|
},
|
|
12178
|
-
queryRefiners: (queryKey, publicQuery, options = null) => {
|
|
12179
|
-
|
|
12180
|
-
|
|
12181
|
-
|
|
12182
|
-
|
|
12183
|
-
|
|
12284
|
+
queryRefiners: (queryKey, publicQuery, options = null) => __async2(null, null, function* () {
|
|
12285
|
+
const result2 = yield refiners(queryKey, publicQuery, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl, options === null || options === void 0 ? void 0 : options.customParams);
|
|
12286
|
+
return transformSearchQueryRefinersResult(result2, options);
|
|
12287
|
+
}),
|
|
12288
|
+
queryRelated: (queryKey, publicQuery, options = null) => __async2(null, null, function* () {
|
|
12289
|
+
const result2 = yield relatedQueries(queryKey, publicQuery, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl, options === null || options === void 0 ? void 0 : options.customParams);
|
|
12290
|
+
return transformRelatedQueries(result2, options);
|
|
12291
|
+
}),
|
|
12184
12292
|
suggestions: (queryKey, suggestionQuery, options = null) => {
|
|
12185
12293
|
if (options === null || options === void 0 ? void 0 : options.customUrl) {
|
|
12186
|
-
|
|
12294
|
+
const result3 = suggestCustom(suggestionQuery, options);
|
|
12295
|
+
return result3;
|
|
12187
12296
|
}
|
|
12188
|
-
|
|
12297
|
+
const result2 = suggest(queryKey, suggestionQuery, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl, options === null || options === void 0 ? void 0 : options.customParams);
|
|
12298
|
+
return result2;
|
|
12189
12299
|
},
|
|
12190
12300
|
track: (queryKey, eventData, options = null) => {
|
|
12191
12301
|
return track$1(queryKey, eventData, (options === null || options === void 0 ? void 0 : options.environment) || "production", options === null || options === void 0 ? void 0 : options.customBaseUrl);
|
|
@@ -12860,9 +12970,9 @@ function requireLodash$1() {
|
|
|
12860
12970
|
});
|
|
12861
12971
|
return result2;
|
|
12862
12972
|
}
|
|
12863
|
-
function overArg(func,
|
|
12973
|
+
function overArg(func, transform2) {
|
|
12864
12974
|
return function(arg) {
|
|
12865
|
-
return func(
|
|
12975
|
+
return func(transform2(arg));
|
|
12866
12976
|
};
|
|
12867
12977
|
}
|
|
12868
12978
|
function replaceHolders(array, placeholder) {
|
|
@@ -12969,7 +13079,7 @@ function requireLodash$1() {
|
|
|
12969
13079
|
var dataViewCtorString = toSource(DataView2), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set2), weakMapCtorString = toSource(WeakMap2);
|
|
12970
13080
|
var symbolProto = Symbol2 ? Symbol2.prototype : undefined$1, symbolValueOf = symbolProto ? symbolProto.valueOf : undefined$1, symbolToString = symbolProto ? symbolProto.toString : undefined$1;
|
|
12971
13081
|
function lodash2(value) {
|
|
12972
|
-
if (
|
|
13082
|
+
if (isObjectLike2(value) && !isArray3(value) && !(value instanceof LazyWrapper)) {
|
|
12973
13083
|
if (value instanceof LodashWrapper) {
|
|
12974
13084
|
return value;
|
|
12975
13085
|
}
|
|
@@ -13650,19 +13760,19 @@ function requireLodash$1() {
|
|
|
13650
13760
|
return func == null ? undefined$1 : apply2(func, object, args);
|
|
13651
13761
|
}
|
|
13652
13762
|
function baseIsArguments(value) {
|
|
13653
|
-
return
|
|
13763
|
+
return isObjectLike2(value) && baseGetTag(value) == argsTag;
|
|
13654
13764
|
}
|
|
13655
13765
|
function baseIsArrayBuffer(value) {
|
|
13656
|
-
return
|
|
13766
|
+
return isObjectLike2(value) && baseGetTag(value) == arrayBufferTag;
|
|
13657
13767
|
}
|
|
13658
13768
|
function baseIsDate(value) {
|
|
13659
|
-
return
|
|
13769
|
+
return isObjectLike2(value) && baseGetTag(value) == dateTag;
|
|
13660
13770
|
}
|
|
13661
13771
|
function baseIsEqual(value, other, bitmask, customizer, stack2) {
|
|
13662
13772
|
if (value === other) {
|
|
13663
13773
|
return true;
|
|
13664
13774
|
}
|
|
13665
|
-
if (value == null || other == null || !
|
|
13775
|
+
if (value == null || other == null || !isObjectLike2(value) && !isObjectLike2(other)) {
|
|
13666
13776
|
return value !== value && other !== other;
|
|
13667
13777
|
}
|
|
13668
13778
|
return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack2);
|
|
@@ -13698,7 +13808,7 @@ function requireLodash$1() {
|
|
|
13698
13808
|
return equalObjects(object, other, bitmask, customizer, equalFunc, stack2);
|
|
13699
13809
|
}
|
|
13700
13810
|
function baseIsMap(value) {
|
|
13701
|
-
return
|
|
13811
|
+
return isObjectLike2(value) && getTag(value) == mapTag;
|
|
13702
13812
|
}
|
|
13703
13813
|
function baseIsMatch(object, source, matchData, customizer) {
|
|
13704
13814
|
var index = matchData.length, length = index, noCustomizer = !customizer;
|
|
@@ -13739,13 +13849,13 @@ function requireLodash$1() {
|
|
|
13739
13849
|
return pattern.test(toSource(value));
|
|
13740
13850
|
}
|
|
13741
13851
|
function baseIsRegExp(value) {
|
|
13742
|
-
return
|
|
13852
|
+
return isObjectLike2(value) && baseGetTag(value) == regexpTag;
|
|
13743
13853
|
}
|
|
13744
13854
|
function baseIsSet(value) {
|
|
13745
|
-
return
|
|
13855
|
+
return isObjectLike2(value) && getTag(value) == setTag;
|
|
13746
13856
|
}
|
|
13747
13857
|
function baseIsTypedArray(value) {
|
|
13748
|
-
return
|
|
13858
|
+
return isObjectLike2(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
|
|
13749
13859
|
}
|
|
13750
13860
|
function baseIteratee(value) {
|
|
13751
13861
|
if (typeof value == "function") {
|
|
@@ -15255,7 +15365,7 @@ function requireLodash$1() {
|
|
|
15255
15365
|
function objectToString2(value) {
|
|
15256
15366
|
return nativeObjectToString.call(value);
|
|
15257
15367
|
}
|
|
15258
|
-
function overRest(func, start,
|
|
15368
|
+
function overRest(func, start, transform3) {
|
|
15259
15369
|
start = nativeMax(start === undefined$1 ? func.length - 1 : start, 0);
|
|
15260
15370
|
return function() {
|
|
15261
15371
|
var args = arguments, index = -1, length = nativeMax(args.length - start, 0), array = Array2(length);
|
|
@@ -15267,7 +15377,7 @@ function requireLodash$1() {
|
|
|
15267
15377
|
while (++index < start) {
|
|
15268
15378
|
otherArgs[index] = args[index];
|
|
15269
15379
|
}
|
|
15270
|
-
otherArgs[start] =
|
|
15380
|
+
otherArgs[start] = transform3(array);
|
|
15271
15381
|
return apply2(func, this, otherArgs);
|
|
15272
15382
|
};
|
|
15273
15383
|
}
|
|
@@ -16289,7 +16399,7 @@ function requireLodash$1() {
|
|
|
16289
16399
|
var isArguments = baseIsArguments(/* @__PURE__ */ function() {
|
|
16290
16400
|
return arguments;
|
|
16291
16401
|
}()) ? baseIsArguments : function(value) {
|
|
16292
|
-
return
|
|
16402
|
+
return isObjectLike2(value) && hasOwnProperty2.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
|
|
16293
16403
|
};
|
|
16294
16404
|
var isArray3 = Array2.isArray;
|
|
16295
16405
|
var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer;
|
|
@@ -16297,15 +16407,15 @@ function requireLodash$1() {
|
|
|
16297
16407
|
return value != null && isLength(value.length) && !isFunction2(value);
|
|
16298
16408
|
}
|
|
16299
16409
|
function isArrayLikeObject(value) {
|
|
16300
|
-
return
|
|
16410
|
+
return isObjectLike2(value) && isArrayLike(value);
|
|
16301
16411
|
}
|
|
16302
16412
|
function isBoolean2(value) {
|
|
16303
|
-
return value === true || value === false ||
|
|
16413
|
+
return value === true || value === false || isObjectLike2(value) && baseGetTag(value) == boolTag;
|
|
16304
16414
|
}
|
|
16305
16415
|
var isBuffer = nativeIsBuffer || stubFalse;
|
|
16306
16416
|
var isDate2 = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;
|
|
16307
16417
|
function isElement(value) {
|
|
16308
|
-
return
|
|
16418
|
+
return isObjectLike2(value) && value.nodeType === 1 && !isPlainObject4(value);
|
|
16309
16419
|
}
|
|
16310
16420
|
function isEmpty(value) {
|
|
16311
16421
|
if (value == null) {
|
|
@@ -16337,7 +16447,7 @@ function requireLodash$1() {
|
|
|
16337
16447
|
return result3 === undefined$1 ? baseIsEqual(value, other, undefined$1, customizer) : !!result3;
|
|
16338
16448
|
}
|
|
16339
16449
|
function isError2(value) {
|
|
16340
|
-
if (!
|
|
16450
|
+
if (!isObjectLike2(value)) {
|
|
16341
16451
|
return false;
|
|
16342
16452
|
}
|
|
16343
16453
|
var tag = baseGetTag(value);
|
|
@@ -16363,7 +16473,7 @@ function requireLodash$1() {
|
|
|
16363
16473
|
var type = typeof value;
|
|
16364
16474
|
return value != null && (type == "object" || type == "function");
|
|
16365
16475
|
}
|
|
16366
|
-
function
|
|
16476
|
+
function isObjectLike2(value) {
|
|
16367
16477
|
return value != null && typeof value == "object";
|
|
16368
16478
|
}
|
|
16369
16479
|
var isMap2 = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
|
|
@@ -16390,10 +16500,10 @@ function requireLodash$1() {
|
|
|
16390
16500
|
return value == null;
|
|
16391
16501
|
}
|
|
16392
16502
|
function isNumber2(value) {
|
|
16393
|
-
return typeof value == "number" ||
|
|
16503
|
+
return typeof value == "number" || isObjectLike2(value) && baseGetTag(value) == numberTag;
|
|
16394
16504
|
}
|
|
16395
16505
|
function isPlainObject4(value) {
|
|
16396
|
-
if (!
|
|
16506
|
+
if (!isObjectLike2(value) || baseGetTag(value) != objectTag) {
|
|
16397
16507
|
return false;
|
|
16398
16508
|
}
|
|
16399
16509
|
var proto = getPrototype(value);
|
|
@@ -16409,20 +16519,20 @@ function requireLodash$1() {
|
|
|
16409
16519
|
}
|
|
16410
16520
|
var isSet2 = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
|
|
16411
16521
|
function isString2(value) {
|
|
16412
|
-
return typeof value == "string" || !isArray3(value) &&
|
|
16522
|
+
return typeof value == "string" || !isArray3(value) && isObjectLike2(value) && baseGetTag(value) == stringTag;
|
|
16413
16523
|
}
|
|
16414
16524
|
function isSymbol2(value) {
|
|
16415
|
-
return typeof value == "symbol" ||
|
|
16525
|
+
return typeof value == "symbol" || isObjectLike2(value) && baseGetTag(value) == symbolTag;
|
|
16416
16526
|
}
|
|
16417
16527
|
var isTypedArray2 = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
|
|
16418
16528
|
function isUndefined2(value) {
|
|
16419
16529
|
return value === undefined$1;
|
|
16420
16530
|
}
|
|
16421
16531
|
function isWeakMap(value) {
|
|
16422
|
-
return
|
|
16532
|
+
return isObjectLike2(value) && getTag(value) == weakMapTag;
|
|
16423
16533
|
}
|
|
16424
16534
|
function isWeakSet(value) {
|
|
16425
|
-
return
|
|
16535
|
+
return isObjectLike2(value) && baseGetTag(value) == weakSetTag;
|
|
16426
16536
|
}
|
|
16427
16537
|
var lt = createRelationalOperation(baseLt);
|
|
16428
16538
|
var lte = createRelationalOperation(function(value, other) {
|
|
@@ -16682,7 +16792,7 @@ function requireLodash$1() {
|
|
|
16682
16792
|
}
|
|
16683
16793
|
var toPairs = createToPairs(keys);
|
|
16684
16794
|
var toPairsIn = createToPairs(keysIn);
|
|
16685
|
-
function
|
|
16795
|
+
function transform2(object, iteratee2, accumulator) {
|
|
16686
16796
|
var isArr = isArray3(object), isArrLike = isArr || isBuffer(object) || isTypedArray2(object);
|
|
16687
16797
|
iteratee2 = getIteratee(iteratee2, 4);
|
|
16688
16798
|
if (accumulator == null) {
|
|
@@ -17185,7 +17295,7 @@ function requireLodash$1() {
|
|
|
17185
17295
|
}
|
|
17186
17296
|
return result3;
|
|
17187
17297
|
}
|
|
17188
|
-
function
|
|
17298
|
+
function toPath2(value) {
|
|
17189
17299
|
if (isArray3(value)) {
|
|
17190
17300
|
return arrayMap(value, toKey);
|
|
17191
17301
|
}
|
|
@@ -17356,9 +17466,9 @@ function requireLodash$1() {
|
|
|
17356
17466
|
lodash2.toArray = toArray;
|
|
17357
17467
|
lodash2.toPairs = toPairs;
|
|
17358
17468
|
lodash2.toPairsIn = toPairsIn;
|
|
17359
|
-
lodash2.toPath =
|
|
17469
|
+
lodash2.toPath = toPath2;
|
|
17360
17470
|
lodash2.toPlainObject = toPlainObject;
|
|
17361
|
-
lodash2.transform =
|
|
17471
|
+
lodash2.transform = transform2;
|
|
17362
17472
|
lodash2.unary = unary;
|
|
17363
17473
|
lodash2.union = union;
|
|
17364
17474
|
lodash2.unionBy = unionBy;
|
|
@@ -17457,7 +17567,7 @@ function requireLodash$1() {
|
|
|
17457
17567
|
lodash2.isNull = isNull2;
|
|
17458
17568
|
lodash2.isNumber = isNumber2;
|
|
17459
17569
|
lodash2.isObject = isObject2;
|
|
17460
|
-
lodash2.isObjectLike =
|
|
17570
|
+
lodash2.isObjectLike = isObjectLike2;
|
|
17461
17571
|
lodash2.isPlainObject = isPlainObject4;
|
|
17462
17572
|
lodash2.isRegExp = isRegExp2;
|
|
17463
17573
|
lodash2.isSafeInteger = isSafeInteger;
|
|
@@ -19152,6 +19262,10 @@ const useParamsStore = /* @__PURE__ */ defineStore("params", () => {
|
|
|
19152
19262
|
const page2 = Number(params.value[QUERY_PARAMS_PARSED.PAGE]) || 1;
|
|
19153
19263
|
return page2 <= 0 ? 1 : page2;
|
|
19154
19264
|
});
|
|
19265
|
+
const disableNavigationToSearchResults = computed(() => {
|
|
19266
|
+
var _a25;
|
|
19267
|
+
return ((_a25 = optionsStore.searchBoxOptions) == null ? void 0 : _a25.disableNavigationToSearchResults) || false;
|
|
19268
|
+
});
|
|
19155
19269
|
const limit = computed(() => {
|
|
19156
19270
|
return Number(params.value[QUERY_PARAMS_PARSED.LIMIT]) || optionsStore.defaultSearchResultPageSize || defaultLimit.value;
|
|
19157
19271
|
});
|
|
@@ -19245,6 +19359,9 @@ const useParamsStore = /* @__PURE__ */ defineStore("params", () => {
|
|
|
19245
19359
|
if (redirectionApplied) {
|
|
19246
19360
|
return;
|
|
19247
19361
|
}
|
|
19362
|
+
if (disableNavigationToSearchResults.value) {
|
|
19363
|
+
return;
|
|
19364
|
+
}
|
|
19248
19365
|
const forceFullReload = (_a25 = optionsStore.searchBoxOptions.forceFullReloadOnParams) == null ? void 0 : _a25.some(
|
|
19249
19366
|
(p2) => getQueryParam$1(p2)
|
|
19250
19367
|
);
|
|
@@ -19809,10 +19926,10 @@ const _hoisted_1$1o = {
|
|
|
19809
19926
|
key: 0,
|
|
19810
19927
|
class: "lupa-dialog-overlay"
|
|
19811
19928
|
};
|
|
19812
|
-
const _hoisted_2$
|
|
19929
|
+
const _hoisted_2$Z = { class: "lupa-dialog-content" };
|
|
19813
19930
|
const _hoisted_3$G = { class: "lupa-listening-text" };
|
|
19814
|
-
const _hoisted_4$
|
|
19815
|
-
const _hoisted_5$
|
|
19931
|
+
const _hoisted_4$v = { class: "lupa-mic-button-wrapper" };
|
|
19932
|
+
const _hoisted_5$l = ["aria-label"];
|
|
19816
19933
|
const _sfc_main$1F = /* @__PURE__ */ defineComponent({
|
|
19817
19934
|
__name: "VoiceSearchDialog",
|
|
19818
19935
|
props: {
|
|
@@ -19923,15 +20040,15 @@ const _sfc_main$1F = /* @__PURE__ */ defineComponent({
|
|
|
19923
20040
|
class: "lupa-dialog-box-close-button",
|
|
19924
20041
|
onClick: _cache[0] || (_cache[0] = () => emit2("close"))
|
|
19925
20042
|
}),
|
|
19926
|
-
createBaseVNode("div", _hoisted_2$
|
|
20043
|
+
createBaseVNode("div", _hoisted_2$Z, [
|
|
19927
20044
|
createBaseVNode("p", _hoisted_3$G, toDisplayString(description.value), 1),
|
|
19928
|
-
createBaseVNode("div", _hoisted_4$
|
|
20045
|
+
createBaseVNode("div", _hoisted_4$v, [
|
|
19929
20046
|
createBaseVNode("button", {
|
|
19930
20047
|
class: normalizeClass(["lupa-mic-button", { recording: unref(isRecording) }]),
|
|
19931
20048
|
onClick: handleRecordingButtonClick,
|
|
19932
20049
|
"aria-controls": "voice-search-microphone",
|
|
19933
20050
|
"aria-label": ((_b25 = (_a25 = labels.value) == null ? void 0 : _a25.aria) == null ? void 0 : _b25.microphone) || "Toggle microphone"
|
|
19934
|
-
}, null, 10, _hoisted_5$
|
|
20051
|
+
}, null, 10, _hoisted_5$l),
|
|
19935
20052
|
createVNode(_sfc_main$1G, {
|
|
19936
20053
|
ref_key: "voiceSearchProgressBar",
|
|
19937
20054
|
ref: voiceSearchProgressBar,
|
|
@@ -19948,10 +20065,10 @@ const _sfc_main$1F = /* @__PURE__ */ defineComponent({
|
|
|
19948
20065
|
}
|
|
19949
20066
|
});
|
|
19950
20067
|
const _hoisted_1$1n = { id: "lupa-search-box-input-container" };
|
|
19951
|
-
const _hoisted_2$
|
|
20068
|
+
const _hoisted_2$Y = { class: "lupa-input-clear" };
|
|
19952
20069
|
const _hoisted_3$F = { id: "lupa-search-box-input" };
|
|
19953
|
-
const _hoisted_4$
|
|
19954
|
-
const _hoisted_5$
|
|
20070
|
+
const _hoisted_4$u = ["value"];
|
|
20071
|
+
const _hoisted_5$k = ["aria-label", "placeholder"];
|
|
19955
20072
|
const _hoisted_6$7 = {
|
|
19956
20073
|
key: 0,
|
|
19957
20074
|
class: "lupa-close-label"
|
|
@@ -20091,7 +20208,7 @@ const _sfc_main$1E = /* @__PURE__ */ defineComponent({
|
|
|
20091
20208
|
__expose({ focus });
|
|
20092
20209
|
return (_ctx, _cache) => {
|
|
20093
20210
|
return openBlock(), createElementBlock("div", _hoisted_1$1n, [
|
|
20094
|
-
createBaseVNode("div", _hoisted_2$
|
|
20211
|
+
createBaseVNode("div", _hoisted_2$Y, [
|
|
20095
20212
|
createBaseVNode("div", {
|
|
20096
20213
|
class: normalizeClass(["lupa-input-clear-content", { "lupa-input-clear-filled": inputValue.value }]),
|
|
20097
20214
|
onClick: clear
|
|
@@ -20103,7 +20220,7 @@ const _sfc_main$1E = /* @__PURE__ */ defineComponent({
|
|
|
20103
20220
|
"aria-hidden": "true",
|
|
20104
20221
|
value: showHint.value ? suggestedValue.value.item.suggestion : "",
|
|
20105
20222
|
disabled: ""
|
|
20106
|
-
}, null, 8, _hoisted_4$
|
|
20223
|
+
}, null, 8, _hoisted_4$u),
|
|
20107
20224
|
withDirectives(createBaseVNode("input", mergeProps({
|
|
20108
20225
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputValue.value = $event)
|
|
20109
20226
|
}, inputAttributes.value, {
|
|
@@ -20117,7 +20234,7 @@ const _sfc_main$1E = /* @__PURE__ */ defineComponent({
|
|
|
20117
20234
|
placeholder: labels.value.placeholder,
|
|
20118
20235
|
onInput: handleInput,
|
|
20119
20236
|
onFocus: handleFocus
|
|
20120
|
-
}), null, 16, _hoisted_5$
|
|
20237
|
+
}), null, 16, _hoisted_5$k), [
|
|
20121
20238
|
[vModelText, inputValue.value]
|
|
20122
20239
|
]),
|
|
20123
20240
|
_ctx.options.showSubmitButton ? (openBlock(), createElementBlock("button", {
|
|
@@ -20196,7 +20313,7 @@ const _sfc_main$1D = /* @__PURE__ */ defineComponent({
|
|
|
20196
20313
|
}
|
|
20197
20314
|
});
|
|
20198
20315
|
const _hoisted_1$1m = { class: "lupa-search-box-history-item" };
|
|
20199
|
-
const _hoisted_2$
|
|
20316
|
+
const _hoisted_2$X = { class: "lupa-search-box-history-item-content" };
|
|
20200
20317
|
const _sfc_main$1C = /* @__PURE__ */ defineComponent({
|
|
20201
20318
|
__name: "SearchBoxHistoryItem",
|
|
20202
20319
|
props: {
|
|
@@ -20215,7 +20332,7 @@ const _sfc_main$1C = /* @__PURE__ */ defineComponent({
|
|
|
20215
20332
|
};
|
|
20216
20333
|
return (_ctx, _cache) => {
|
|
20217
20334
|
return openBlock(), createElementBlock("div", _hoisted_1$1m, [
|
|
20218
|
-
createBaseVNode("div", _hoisted_2$
|
|
20335
|
+
createBaseVNode("div", _hoisted_2$X, [
|
|
20219
20336
|
createBaseVNode("div", {
|
|
20220
20337
|
class: normalizeClass(["lupa-search-box-history-item-text", { "lupa-search-box-history-item-highlighted": _ctx.highlighted }]),
|
|
20221
20338
|
onClick: click2
|
|
@@ -20302,15 +20419,31 @@ const _sfc_main$1B = /* @__PURE__ */ defineComponent({
|
|
|
20302
20419
|
};
|
|
20303
20420
|
}
|
|
20304
20421
|
});
|
|
20305
|
-
const _hoisted_1$1k =
|
|
20422
|
+
const _hoisted_1$1k = ["innerHTML"];
|
|
20423
|
+
const _hoisted_2$W = {
|
|
20424
|
+
key: 1,
|
|
20425
|
+
class: "lupa-search-box-no-results"
|
|
20426
|
+
};
|
|
20306
20427
|
const _sfc_main$1A = /* @__PURE__ */ defineComponent({
|
|
20307
20428
|
__name: "SearchBoxNoResults",
|
|
20308
20429
|
props: {
|
|
20309
|
-
|
|
20430
|
+
options: {}
|
|
20310
20431
|
},
|
|
20311
20432
|
setup(__props) {
|
|
20433
|
+
const props = __props;
|
|
20434
|
+
const customHtml = computed(() => {
|
|
20435
|
+
return props.options.noResultsCustomHtml;
|
|
20436
|
+
});
|
|
20437
|
+
const labels = computed(() => {
|
|
20438
|
+
return props.options.labels;
|
|
20439
|
+
});
|
|
20312
20440
|
return (_ctx, _cache) => {
|
|
20313
|
-
|
|
20441
|
+
var _a25;
|
|
20442
|
+
return customHtml.value ? (openBlock(), createElementBlock("div", {
|
|
20443
|
+
key: 0,
|
|
20444
|
+
class: "lupa-search-box-no-results",
|
|
20445
|
+
innerHTML: customHtml.value
|
|
20446
|
+
}, null, 8, _hoisted_1$1k)) : (openBlock(), createElementBlock("p", _hoisted_2$W, toDisplayString((_a25 = labels.value) == null ? void 0 : _a25.noResults), 1));
|
|
20314
20447
|
};
|
|
20315
20448
|
}
|
|
20316
20449
|
});
|
|
@@ -20353,11 +20486,11 @@ const _hoisted_3$E = {
|
|
|
20353
20486
|
class: "lupa-suggestion-facet",
|
|
20354
20487
|
"data-cy": "lupa-suggestion-facet"
|
|
20355
20488
|
};
|
|
20356
|
-
const _hoisted_4$
|
|
20489
|
+
const _hoisted_4$t = {
|
|
20357
20490
|
class: "lupa-suggestion-facet-label",
|
|
20358
20491
|
"data-cy": "lupa-suggestion-facet-label"
|
|
20359
20492
|
};
|
|
20360
|
-
const _hoisted_5$
|
|
20493
|
+
const _hoisted_5$j = {
|
|
20361
20494
|
class: "lupa-suggestion-facet-value",
|
|
20362
20495
|
"data-cy": "lupa-suggestion-facet-value"
|
|
20363
20496
|
};
|
|
@@ -20400,8 +20533,8 @@ const _sfc_main$1z = /* @__PURE__ */ defineComponent({
|
|
|
20400
20533
|
innerHTML: _ctx.suggestion.displayHighlight
|
|
20401
20534
|
}, null, 8, _hoisted_1$1j)) : (openBlock(), createElementBlock("div", _hoisted_2$V, toDisplayString(_ctx.suggestion.display), 1)),
|
|
20402
20535
|
_ctx.suggestion.facet ? (openBlock(), createElementBlock("div", _hoisted_3$E, [
|
|
20403
|
-
createBaseVNode("span", _hoisted_4$
|
|
20404
|
-
createBaseVNode("span", _hoisted_5$
|
|
20536
|
+
createBaseVNode("span", _hoisted_4$t, toDisplayString(facetLabel.value), 1),
|
|
20537
|
+
createBaseVNode("span", _hoisted_5$j, toDisplayString(_ctx.suggestion.facet.title), 1)
|
|
20405
20538
|
])) : createCommentVNode("", true)
|
|
20406
20539
|
]);
|
|
20407
20540
|
};
|
|
@@ -28467,12 +28600,12 @@ and ensure you are accounting for this risk.
|
|
|
28467
28600
|
});
|
|
28468
28601
|
const transformTagsMap = {};
|
|
28469
28602
|
let transformTagsAll;
|
|
28470
|
-
each(options.transformTags, function(
|
|
28603
|
+
each(options.transformTags, function(transform2, tag) {
|
|
28471
28604
|
let transFun;
|
|
28472
|
-
if (typeof
|
|
28473
|
-
transFun =
|
|
28474
|
-
} else if (typeof
|
|
28475
|
-
transFun = sanitizeHtml2.simpleTransform(
|
|
28605
|
+
if (typeof transform2 === "function") {
|
|
28606
|
+
transFun = transform2;
|
|
28607
|
+
} else if (typeof transform2 === "string") {
|
|
28608
|
+
transFun = sanitizeHtml2.simpleTransform(transform2);
|
|
28476
28609
|
}
|
|
28477
28610
|
if (tag === "*") {
|
|
28478
28611
|
transformTagsAll = transFun;
|
|
@@ -30140,8 +30273,8 @@ const _sfc_main$1r = /* @__PURE__ */ defineComponent({
|
|
|
30140
30273
|
const _hoisted_1$1d = ["innerHTML"];
|
|
30141
30274
|
const _hoisted_2$R = { key: 0 };
|
|
30142
30275
|
const _hoisted_3$D = { key: 1 };
|
|
30143
|
-
const _hoisted_4$
|
|
30144
|
-
const _hoisted_5$
|
|
30276
|
+
const _hoisted_4$s = { class: "lupa-search-box-custom-label" };
|
|
30277
|
+
const _hoisted_5$i = { class: "lupa-search-box-custom-text" };
|
|
30145
30278
|
const _sfc_main$1q = /* @__PURE__ */ defineComponent({
|
|
30146
30279
|
__name: "SearchBoxProductCustom",
|
|
30147
30280
|
props: {
|
|
@@ -30173,8 +30306,8 @@ const _sfc_main$1q = /* @__PURE__ */ defineComponent({
|
|
|
30173
30306
|
class: [className.value, "lupa-search-box-product-custom"]
|
|
30174
30307
|
}, toHandlers(_ctx.options.action ? { click: handleClick } : {})), [
|
|
30175
30308
|
!label.value ? (openBlock(), createElementBlock("div", _hoisted_2$R, toDisplayString(text.value), 1)) : (openBlock(), createElementBlock("div", _hoisted_3$D, [
|
|
30176
|
-
createBaseVNode("div", _hoisted_4$
|
|
30177
|
-
createBaseVNode("div", _hoisted_5$
|
|
30309
|
+
createBaseVNode("div", _hoisted_4$s, toDisplayString(label.value), 1),
|
|
30310
|
+
createBaseVNode("div", _hoisted_5$i, toDisplayString(text.value), 1)
|
|
30178
30311
|
]))
|
|
30179
30312
|
], 16));
|
|
30180
30313
|
};
|
|
@@ -30564,8 +30697,8 @@ const useSearchResultStore = /* @__PURE__ */ defineStore("searchResult", () => {
|
|
|
30564
30697
|
const _hoisted_1$1b = { class: "lupa-search-box-add-to-cart-wrapper" };
|
|
30565
30698
|
const _hoisted_2$Q = { class: "lupa-search-box-product-addtocart" };
|
|
30566
30699
|
const _hoisted_3$C = ["disabled"];
|
|
30567
|
-
const _hoisted_4$
|
|
30568
|
-
const _hoisted_5$
|
|
30700
|
+
const _hoisted_4$r = ["href"];
|
|
30701
|
+
const _hoisted_5$h = ["disabled"];
|
|
30569
30702
|
const _sfc_main$1o = /* @__PURE__ */ defineComponent({
|
|
30570
30703
|
__name: "SearchBoxProductAddToCart",
|
|
30571
30704
|
props: {
|
|
@@ -30620,7 +30753,7 @@ const _sfc_main$1o = /* @__PURE__ */ defineComponent({
|
|
|
30620
30753
|
"data-cy": "lupa-add-to-cart",
|
|
30621
30754
|
disabled: !inStockValue.value || loading.value
|
|
30622
30755
|
}, _ctx.dynamicAttributes, { onClick: handleClick }), [
|
|
30623
|
-
createBaseVNode("a", { href: _ctx.link }, toDisplayString(label.value), 9, _hoisted_4$
|
|
30756
|
+
createBaseVNode("a", { href: _ctx.link }, toDisplayString(label.value), 9, _hoisted_4$r)
|
|
30624
30757
|
], 16, _hoisted_3$C)) : (openBlock(), createElementBlock("button", mergeProps({
|
|
30625
30758
|
key: 1,
|
|
30626
30759
|
onClick: withModifiers(handleClick, ["stop", "prevent"]),
|
|
@@ -30628,7 +30761,7 @@ const _sfc_main$1o = /* @__PURE__ */ defineComponent({
|
|
|
30628
30761
|
"data-cy": "lupa-add-to-cart",
|
|
30629
30762
|
type: "button",
|
|
30630
30763
|
disabled: !inStockValue.value || loading.value
|
|
30631
|
-
}, _ctx.dynamicAttributes), toDisplayString(label.value), 17, _hoisted_5$
|
|
30764
|
+
}, _ctx.dynamicAttributes), toDisplayString(label.value), 17, _hoisted_5$h))
|
|
30632
30765
|
])
|
|
30633
30766
|
]);
|
|
30634
30767
|
};
|
|
@@ -30740,7 +30873,7 @@ const _sfc_main$1n = /* @__PURE__ */ defineComponent(__spreadProps2(__spreadValu
|
|
|
30740
30873
|
const _hoisted_1$19 = { class: "lupa-badge-title" };
|
|
30741
30874
|
const _hoisted_2$P = ["src"];
|
|
30742
30875
|
const _hoisted_3$B = { key: 1 };
|
|
30743
|
-
const _hoisted_4$
|
|
30876
|
+
const _hoisted_4$q = {
|
|
30744
30877
|
key: 0,
|
|
30745
30878
|
class: "lupa-badge-full-text"
|
|
30746
30879
|
};
|
|
@@ -30784,7 +30917,7 @@ const _sfc_main$1m = /* @__PURE__ */ defineComponent({
|
|
|
30784
30917
|
}, null, 8, _hoisted_2$P)) : createCommentVNode("", true),
|
|
30785
30918
|
hasTitleText.value && showTitle.value ? (openBlock(), createElementBlock("span", _hoisted_3$B, toDisplayString(_ctx.badge.titleText), 1)) : createCommentVNode("", true)
|
|
30786
30919
|
]),
|
|
30787
|
-
hasAdditionalText.value ? (openBlock(), createElementBlock("span", _hoisted_4$
|
|
30920
|
+
hasAdditionalText.value ? (openBlock(), createElementBlock("span", _hoisted_4$q, toDisplayString(_ctx.badge.additionalText), 1)) : createCommentVNode("", true)
|
|
30788
30921
|
], 6);
|
|
30789
30922
|
};
|
|
30790
30923
|
}
|
|
@@ -31317,7 +31450,7 @@ const useTrackingStore = /* @__PURE__ */ defineStore("tracking", () => {
|
|
|
31317
31450
|
};
|
|
31318
31451
|
return { trackSearch, trackResults, trackEvent, trackDelayedEvent };
|
|
31319
31452
|
});
|
|
31320
|
-
const _hoisted_1$12 =
|
|
31453
|
+
const _hoisted_1$12 = ["innerHTML"];
|
|
31321
31454
|
const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
31322
31455
|
__name: "SearchBoxProducts",
|
|
31323
31456
|
props: {
|
|
@@ -31343,6 +31476,29 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
31343
31476
|
}
|
|
31344
31477
|
return (_c = (_b25 = highlightedItem.value) == null ? void 0 : _b25.index) != null ? _c : -1;
|
|
31345
31478
|
});
|
|
31479
|
+
const showAll = ref(false);
|
|
31480
|
+
const hasResults = computed(() => {
|
|
31481
|
+
return props.items && props.items.length > 0;
|
|
31482
|
+
});
|
|
31483
|
+
const hasUncollapsedDocumentCountLimit = computed(() => {
|
|
31484
|
+
var _a25;
|
|
31485
|
+
return Boolean((_a25 = props.panelOptions) == null ? void 0 : _a25.uncollapsedDocumentCount);
|
|
31486
|
+
});
|
|
31487
|
+
const showAllItemsToggleButton = computed(() => {
|
|
31488
|
+
var _a25, _b25, _c;
|
|
31489
|
+
if (!hasUncollapsedDocumentCountLimit.value) {
|
|
31490
|
+
return false;
|
|
31491
|
+
}
|
|
31492
|
+
return ((_a25 = props.items) == null ? void 0 : _a25.length) > ((_c = (_b25 = props.panelOptions) == null ? void 0 : _b25.uncollapsedDocumentCount) != null ? _c : 0);
|
|
31493
|
+
});
|
|
31494
|
+
const displayItems = computed(() => {
|
|
31495
|
+
var _a25, _b25;
|
|
31496
|
+
if (showAll.value) {
|
|
31497
|
+
return props.items;
|
|
31498
|
+
}
|
|
31499
|
+
const count = (_b25 = (_a25 = props.panelOptions.uncollapsedDocumentCount) != null ? _a25 : props.panelOptions.limit) != null ? _b25 : props.items.length;
|
|
31500
|
+
return props.items.slice(0, count);
|
|
31501
|
+
});
|
|
31346
31502
|
const handleProductClick = ({
|
|
31347
31503
|
item,
|
|
31348
31504
|
eventType,
|
|
@@ -31390,8 +31546,12 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
31390
31546
|
}
|
|
31391
31547
|
};
|
|
31392
31548
|
return (_ctx, _cache) => {
|
|
31393
|
-
|
|
31394
|
-
|
|
31549
|
+
var _a25, _b25, _c;
|
|
31550
|
+
return openBlock(), createElementBlock("div", {
|
|
31551
|
+
id: "lupa-search-box-products",
|
|
31552
|
+
class: normalizeClass({ "lupa-search-box-products-expanded": showAll.value })
|
|
31553
|
+
}, [
|
|
31554
|
+
_ctx.$slots.productCard ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(displayItems.value, (item, index) => {
|
|
31395
31555
|
return renderSlot(_ctx.$slots, "productCard", {
|
|
31396
31556
|
key: index,
|
|
31397
31557
|
item,
|
|
@@ -31401,7 +31561,7 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
31401
31561
|
inputValue: _ctx.inputValue,
|
|
31402
31562
|
itemClicked: handleProductClick
|
|
31403
31563
|
});
|
|
31404
|
-
}), 128)) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(
|
|
31564
|
+
}), 128)) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(displayItems.value, (item, index) => {
|
|
31405
31565
|
return openBlock(), createBlock(_sfc_main$1f, {
|
|
31406
31566
|
key: index,
|
|
31407
31567
|
item,
|
|
@@ -31412,8 +31572,17 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
31412
31572
|
onProductClick: handleProductClick
|
|
31413
31573
|
}, null, 8, ["item", "panelOptions", "labels", "highlighted", "inputValue"]);
|
|
31414
31574
|
}), 128)),
|
|
31575
|
+
hasResults.value && ((_a25 = _ctx.panelOptions) == null ? void 0 : _a25.appendCustomHtml) && (showAll.value || !showAllItemsToggleButton.value) ? (openBlock(), createElementBlock("div", {
|
|
31576
|
+
key: 2,
|
|
31577
|
+
innerHTML: _ctx.panelOptions.appendCustomHtml
|
|
31578
|
+
}, null, 8, _hoisted_1$12)) : createCommentVNode("", true),
|
|
31579
|
+
showAllItemsToggleButton.value ? (openBlock(), createElementBlock("a", {
|
|
31580
|
+
key: 3,
|
|
31581
|
+
class: "lupa-search-box-expand",
|
|
31582
|
+
onClick: _cache[0] || (_cache[0] = ($event) => showAll.value = !showAll.value)
|
|
31583
|
+
}, toDisplayString(showAll.value ? (_b25 = _ctx.labels) == null ? void 0 : _b25.showLess : (_c = _ctx.labels) == null ? void 0 : _c.showMore), 1)) : createCommentVNode("", true),
|
|
31415
31584
|
renderSlot(_ctx.$slots, "default")
|
|
31416
|
-
]);
|
|
31585
|
+
], 2);
|
|
31417
31586
|
};
|
|
31418
31587
|
}
|
|
31419
31588
|
});
|
|
@@ -31601,6 +31770,7 @@ const _sfc_main$1c = /* @__PURE__ */ defineComponent({
|
|
|
31601
31770
|
searchText: props.inputValue,
|
|
31602
31771
|
limit: props.panel.limit,
|
|
31603
31772
|
filters: extractedInitialFilters.value,
|
|
31773
|
+
selectFields: props.panel.selectFields,
|
|
31604
31774
|
modifiers: {
|
|
31605
31775
|
facets: false,
|
|
31606
31776
|
refiners: false
|
|
@@ -31743,23 +31913,15 @@ const _sfc_main$1b = /* @__PURE__ */ defineComponent({
|
|
|
31743
31913
|
};
|
|
31744
31914
|
}
|
|
31745
31915
|
});
|
|
31746
|
-
const _hoisted_1$10 =
|
|
31747
|
-
|
|
31748
|
-
id: "lupa-search-box-panel"
|
|
31749
|
-
};
|
|
31750
|
-
const _hoisted_2$L = ["data-cy"];
|
|
31751
|
-
const _hoisted_3$z = {
|
|
31916
|
+
const _hoisted_1$10 = ["data-cy"];
|
|
31917
|
+
const _hoisted_2$L = {
|
|
31752
31918
|
key: 0,
|
|
31753
31919
|
class: "lupa-panel-title lupa-panel-title-top-results"
|
|
31754
31920
|
};
|
|
31755
|
-
const
|
|
31921
|
+
const _hoisted_3$z = {
|
|
31756
31922
|
key: 1,
|
|
31757
31923
|
class: "lupa-panel-title"
|
|
31758
31924
|
};
|
|
31759
|
-
const _hoisted_5$h = {
|
|
31760
|
-
key: 1,
|
|
31761
|
-
id: "lupa-search-box-panel"
|
|
31762
|
-
};
|
|
31763
31925
|
const __default__$2 = {
|
|
31764
31926
|
components: {
|
|
31765
31927
|
SearchBoxSuggestionsWrapper: _sfc_main$1x,
|
|
@@ -31932,7 +32094,11 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent(__spreadProps2(__spreadValu
|
|
|
31932
32094
|
ref_key: "panelContainer",
|
|
31933
32095
|
ref: panelContainer
|
|
31934
32096
|
}, [
|
|
31935
|
-
displayResults.value ? (openBlock(), createElementBlock("div",
|
|
32097
|
+
displayResults.value ? (openBlock(), createElementBlock("div", {
|
|
32098
|
+
key: 0,
|
|
32099
|
+
id: "lupa-search-box-panel",
|
|
32100
|
+
class: normalizeClass({ "lupa-search-text-empty": isSearchEmpty.value })
|
|
32101
|
+
}, [
|
|
31936
32102
|
labels.value.closePanel ? (openBlock(), createElementBlock("a", {
|
|
31937
32103
|
key: 0,
|
|
31938
32104
|
class: "lupa-search-box-close-panel",
|
|
@@ -31954,8 +32120,8 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent(__spreadProps2(__spreadValu
|
|
|
31954
32120
|
style: normalizeStyle(panel.gridArea ? { gridArea: `${panel.gridArea}${index}` } : {}),
|
|
31955
32121
|
"data-cy": "lupa-panel-" + panel.type + "-index"
|
|
31956
32122
|
}, [
|
|
31957
|
-
((_a25 = panel.labels) == null ? void 0 : _a25.topResultsTitle) && showTopResultsPanelTitle(panel.queryKey) ? (openBlock(), createElementBlock("div",
|
|
31958
|
-
((_c = panel.labels) == null ? void 0 : _c.title) && showPanelTitle(panel) ? (openBlock(), createElementBlock("div",
|
|
32123
|
+
((_a25 = panel.labels) == null ? void 0 : _a25.topResultsTitle) && showTopResultsPanelTitle(panel.queryKey) ? (openBlock(), createElementBlock("div", _hoisted_2$L, toDisplayString((_b25 = panel.labels) == null ? void 0 : _b25.topResultsTitle), 1)) : createCommentVNode("", true),
|
|
32124
|
+
((_c = panel.labels) == null ? void 0 : _c.title) && showPanelTitle(panel) ? (openBlock(), createElementBlock("div", _hoisted_3$z, toDisplayString((_d = panel.labels) == null ? void 0 : _d.title), 1)) : createCommentVNode("", true),
|
|
31959
32125
|
panel.queryKey && canShowPanel(panel) ? (openBlock(), createBlock(resolveDynamicComponent(getComponent(panel.type)), {
|
|
31960
32126
|
key: 2,
|
|
31961
32127
|
panel,
|
|
@@ -31977,20 +32143,24 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent(__spreadProps2(__spreadValu
|
|
|
31977
32143
|
key: "0"
|
|
31978
32144
|
} : void 0
|
|
31979
32145
|
]), 1064, ["panel", "search-box-options", "options", "debounce", "inputValue", "labels"])) : createCommentVNode("", true)
|
|
31980
|
-
], 14,
|
|
32146
|
+
], 14, _hoisted_1$10);
|
|
31981
32147
|
}), 128))
|
|
31982
32148
|
], 4),
|
|
31983
32149
|
!unref(hasAnyResults) && _ctx.options.showNoResultsPanel ? (openBlock(), createBlock(_sfc_main$1A, {
|
|
31984
32150
|
key: 1,
|
|
31985
|
-
|
|
31986
|
-
}, null, 8, ["
|
|
32151
|
+
options: _ctx.options
|
|
32152
|
+
}, null, 8, ["options"])) : createCommentVNode("", true),
|
|
31987
32153
|
displayShowMoreResultsButton.value ? (openBlock(), createBlock(_sfc_main$1D, {
|
|
31988
32154
|
key: 2,
|
|
31989
32155
|
labels: labels.value,
|
|
31990
32156
|
options: _ctx.options,
|
|
31991
32157
|
onGoToResults: _cache[4] || (_cache[4] = ($event) => _ctx.$emit("go-to-results"))
|
|
31992
32158
|
}, null, 8, ["labels", "options"])) : createCommentVNode("", true)
|
|
31993
|
-
])) : displayHistory.value ? (openBlock(), createElementBlock("div",
|
|
32159
|
+
], 2)) : displayHistory.value ? (openBlock(), createElementBlock("div", {
|
|
32160
|
+
key: 1,
|
|
32161
|
+
id: "lupa-search-box-panel",
|
|
32162
|
+
class: normalizeClass({ "lupa-search-text-empty": isSearchEmpty.value })
|
|
32163
|
+
}, [
|
|
31994
32164
|
createVNode(_sfc_main$1B, {
|
|
31995
32165
|
options: _ctx.options.history,
|
|
31996
32166
|
history: history.value,
|
|
@@ -31998,7 +32168,7 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent(__spreadProps2(__spreadValu
|
|
|
31998
32168
|
onRemove: remove2,
|
|
31999
32169
|
onRemoveAll: removeAll
|
|
32000
32170
|
}, null, 8, ["options", "history"])
|
|
32001
|
-
])) : createCommentVNode("", true)
|
|
32171
|
+
], 2)) : createCommentVNode("", true)
|
|
32002
32172
|
], 512);
|
|
32003
32173
|
};
|
|
32004
32174
|
}
|
|
@@ -32071,7 +32241,8 @@ const _sfc_main$19 = /* @__PURE__ */ defineComponent({
|
|
|
32071
32241
|
"hideMoreResultsButtonOnEmptyQuery",
|
|
32072
32242
|
"showNoResultsPanel",
|
|
32073
32243
|
"expandOnSinglePanel",
|
|
32074
|
-
"showMoreResultsButton"
|
|
32244
|
+
"showMoreResultsButton",
|
|
32245
|
+
"noResultsCustomHtml"
|
|
32075
32246
|
])
|
|
32076
32247
|
);
|
|
32077
32248
|
const searchTriggers = computed(() => {
|
|
@@ -32137,22 +32308,31 @@ const _sfc_main$19 = /* @__PURE__ */ defineComponent({
|
|
|
32137
32308
|
(_b25 = props.options.callbacks) == null ? void 0 : _b25.onClosed();
|
|
32138
32309
|
}
|
|
32139
32310
|
};
|
|
32140
|
-
const
|
|
32311
|
+
const fillInputWithSuggestion = () => {
|
|
32141
32312
|
var _a26, _b25;
|
|
32313
|
+
if ((_b25 = (_a26 = suggestedValue == null ? void 0 : suggestedValue.value) == null ? void 0 : _a26.item) == null ? void 0 : _b25.suggestion) {
|
|
32314
|
+
selectSuggestion(__spreadProps2(__spreadValues2({}, suggestedValue.value), { override: true }));
|
|
32315
|
+
}
|
|
32316
|
+
};
|
|
32317
|
+
const goToResults = () => {
|
|
32318
|
+
handleSearch();
|
|
32319
|
+
resetValues();
|
|
32320
|
+
};
|
|
32321
|
+
const handleKeyDown = (e2) => {
|
|
32142
32322
|
if (!focused.value) {
|
|
32143
32323
|
return;
|
|
32144
32324
|
}
|
|
32145
32325
|
switch (e2.key) {
|
|
32146
32326
|
case "Tab":
|
|
32147
|
-
|
|
32148
|
-
e2.preventDefault();
|
|
32149
|
-
selectSuggestion(__spreadProps2(__spreadValues2({}, suggestedValue.value), { override: true }));
|
|
32150
|
-
}
|
|
32327
|
+
fillInputWithSuggestion();
|
|
32151
32328
|
break;
|
|
32152
32329
|
case "Enter":
|
|
32153
32330
|
e2.preventDefault();
|
|
32154
|
-
|
|
32155
|
-
|
|
32331
|
+
if (props.options.disableNavigationToSearchResults) {
|
|
32332
|
+
fillInputWithSuggestion();
|
|
32333
|
+
} else {
|
|
32334
|
+
goToResults();
|
|
32335
|
+
}
|
|
32156
32336
|
break;
|
|
32157
32337
|
case "Escape":
|
|
32158
32338
|
opened.value = false;
|
|
@@ -32213,7 +32393,11 @@ const _sfc_main$19 = /* @__PURE__ */ defineComponent({
|
|
|
32213
32393
|
inputValue.value = inputSuggestion.override ? inputSuggestion.item.suggestion : inputValue.value;
|
|
32214
32394
|
}
|
|
32215
32395
|
if (shouldSearch) {
|
|
32216
|
-
|
|
32396
|
+
if (props.options.disableNavigationToSearchResults) {
|
|
32397
|
+
fillInputWithSuggestion();
|
|
32398
|
+
} else {
|
|
32399
|
+
handleSearch();
|
|
32400
|
+
}
|
|
32217
32401
|
}
|
|
32218
32402
|
};
|
|
32219
32403
|
const handleNavigateDocument = ({ link }) => {
|
|
@@ -32379,7 +32563,7 @@ const _sfc_main$19 = /* @__PURE__ */ defineComponent({
|
|
|
32379
32563
|
};
|
|
32380
32564
|
}
|
|
32381
32565
|
});
|
|
32382
|
-
const createPublicQuery = (queryParams, sortOptions, defaultPageSize) => {
|
|
32566
|
+
const createPublicQuery = (queryParams, sortOptions, defaultPageSize, selectFields) => {
|
|
32383
32567
|
var _a25;
|
|
32384
32568
|
const publicQuery = {};
|
|
32385
32569
|
for (const param in queryParams) {
|
|
@@ -32413,6 +32597,9 @@ const createPublicQuery = (queryParams, sortOptions, defaultPageSize) => {
|
|
|
32413
32597
|
}
|
|
32414
32598
|
publicQuery.sort = publicQuery.sort || getDefaultSort(sortOptions);
|
|
32415
32599
|
publicQuery.filters = queryParams.filters;
|
|
32600
|
+
if (selectFields) {
|
|
32601
|
+
publicQuery.selectFields = selectFields;
|
|
32602
|
+
}
|
|
32416
32603
|
return publicQuery;
|
|
32417
32604
|
};
|
|
32418
32605
|
const getDefaultSort = (sortOptions) => {
|
|
@@ -34144,7 +34331,7 @@ const _sfc_main$10 = /* @__PURE__ */ defineComponent({
|
|
|
34144
34331
|
}
|
|
34145
34332
|
);
|
|
34146
34333
|
const facetMin = computed(() => Math.floor(facetValue.value.min * currencyMultiplier.value));
|
|
34147
|
-
const facetMax = computed(() =>
|
|
34334
|
+
const facetMax = computed(() => Number((facetValue.value.max * currencyMultiplier.value).toFixed(2)));
|
|
34148
34335
|
const currentGte = computed(
|
|
34149
34336
|
() => getAdjustedNumber(currentFilters.value.gte, currencyMultiplier.value)
|
|
34150
34337
|
);
|
|
@@ -35614,7 +35801,7 @@ const _hoisted_3$n = {
|
|
|
35614
35801
|
class: "lupa-select-label",
|
|
35615
35802
|
for: "lupa-page-size-select-dropdown"
|
|
35616
35803
|
};
|
|
35617
|
-
const _hoisted_4$g = ["aria-label"];
|
|
35804
|
+
const _hoisted_4$g = ["value", "aria-label"];
|
|
35618
35805
|
const _hoisted_5$b = ["value"];
|
|
35619
35806
|
const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
35620
35807
|
__name: "SearchResultsPageSize",
|
|
@@ -35627,6 +35814,7 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
35627
35814
|
const paramsStore = useParamsStore();
|
|
35628
35815
|
const optionsStore = useOptionsStore();
|
|
35629
35816
|
const { ariaLabels } = storeToRefs(optionsStore);
|
|
35817
|
+
const { limit } = storeToRefs(paramsStore);
|
|
35630
35818
|
const select = ref(null);
|
|
35631
35819
|
const prefixLabel = computed(() => {
|
|
35632
35820
|
var _a25, _b25;
|
|
@@ -35650,6 +35838,7 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
35650
35838
|
createBaseVNode("div", _hoisted_2$v, [
|
|
35651
35839
|
createBaseVNode("label", _hoisted_3$n, toDisplayString(label.value), 1),
|
|
35652
35840
|
createBaseVNode("select", {
|
|
35841
|
+
value: unref(limit),
|
|
35653
35842
|
id: "lupa-page-size-select-dropdown",
|
|
35654
35843
|
class: "lupa-select-dropdown",
|
|
35655
35844
|
"aria-label": (_c = (_b25 = (_a25 = unref(ariaLabels)) == null ? void 0 : _a25.pageSizeSelect) != null ? _b25 : label.value) != null ? _c : "Select page size",
|
|
@@ -35708,6 +35897,7 @@ const useSorting = () => {
|
|
|
35708
35897
|
previousKey.value = selectedKey.value;
|
|
35709
35898
|
};
|
|
35710
35899
|
watch(sort, () => setSortValue());
|
|
35900
|
+
watch(sortOptions, () => setSortValue());
|
|
35711
35901
|
const handleSelect = () => {
|
|
35712
35902
|
var _a25, _b25, _c;
|
|
35713
35903
|
const value = (_a25 = sortItems.value.find((x) => x.key === selectedKey.value)) == null ? void 0 : _a25.key;
|
|
@@ -35723,12 +35913,15 @@ const useSorting = () => {
|
|
|
35723
35913
|
previousKey.value = selectedKey.value;
|
|
35724
35914
|
};
|
|
35725
35915
|
return {
|
|
35916
|
+
sort,
|
|
35726
35917
|
sotyByTitleLabel,
|
|
35727
35918
|
sortItems,
|
|
35728
35919
|
selectedKey,
|
|
35920
|
+
previousKey,
|
|
35729
35921
|
ariaLabels,
|
|
35730
35922
|
sortOptions,
|
|
35731
35923
|
sortStyle,
|
|
35924
|
+
defaultSortValue,
|
|
35732
35925
|
handleSelect,
|
|
35733
35926
|
setSortValue
|
|
35734
35927
|
};
|
|
@@ -37281,7 +37474,7 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
37281
37474
|
} : {};
|
|
37282
37475
|
});
|
|
37283
37476
|
const searchForRelatedQuery = () => __async2(null, null, function* () {
|
|
37284
|
-
var _a25, _b25, _c, _d, _e, _f, _g, _h;
|
|
37477
|
+
var _a25, _b25, _c, _d, _e, _f, _g, _h, _i;
|
|
37285
37478
|
if (!props.query) {
|
|
37286
37479
|
return;
|
|
37287
37480
|
}
|
|
@@ -37290,6 +37483,7 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
37290
37483
|
limit: 3,
|
|
37291
37484
|
filters: relatedQueryFilters.value,
|
|
37292
37485
|
trackTerm: false,
|
|
37486
|
+
selectFields: (_a25 = searchResultOptions.value) == null ? void 0 : _a25.selectFields,
|
|
37293
37487
|
modifiers: {
|
|
37294
37488
|
facets: false,
|
|
37295
37489
|
refiners: false
|
|
@@ -37300,18 +37494,18 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
37300
37494
|
const result2 = yield LupaSearchSdk.query(
|
|
37301
37495
|
queryKey.value,
|
|
37302
37496
|
lupaQuery,
|
|
37303
|
-
(
|
|
37497
|
+
(_b25 = searchResultOptions.value) == null ? void 0 : _b25.options
|
|
37304
37498
|
);
|
|
37305
37499
|
if (result2.success) {
|
|
37306
37500
|
relatedQueryResult.value = result2;
|
|
37307
37501
|
}
|
|
37308
|
-
const firstItem = (
|
|
37309
|
-
itemToDisplay.value = (
|
|
37502
|
+
const firstItem = (_d = (_c = relatedQueryResult.value) == null ? void 0 : _c.items) == null ? void 0 : _d[0];
|
|
37503
|
+
itemToDisplay.value = (_g = (_f = (_e = relatedQueryResult == null ? void 0 : relatedQueryResult.value) == null ? void 0 : _e.items) == null ? void 0 : _f.find(
|
|
37310
37504
|
(i) => !props.existingItemsFromOtherQueries[`${i.id}`]
|
|
37311
|
-
)) != null ?
|
|
37505
|
+
)) != null ? _g : firstItem;
|
|
37312
37506
|
emit2("loaded", itemToDisplay.value);
|
|
37313
37507
|
} catch (error) {
|
|
37314
|
-
(
|
|
37508
|
+
(_i = (_h = searchResultOptions.value) == null ? void 0 : _h.options) == null ? void 0 : _i.onError(error);
|
|
37315
37509
|
} finally {
|
|
37316
37510
|
loading.value = false;
|
|
37317
37511
|
}
|
|
@@ -38442,7 +38636,8 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
38442
38636
|
const publicQuery = createPublicQuery(
|
|
38443
38637
|
parseParams(optionStore.getQueryParamName, searchParams),
|
|
38444
38638
|
props.options.sort,
|
|
38445
|
-
defaultSearchResultPageSize.value
|
|
38639
|
+
defaultSearchResultPageSize.value,
|
|
38640
|
+
props.options.selectFields
|
|
38446
38641
|
);
|
|
38447
38642
|
searchResultStore.setLoading(true);
|
|
38448
38643
|
const finalPublicQuery = getPublicQuery(publicQuery, initialFilters.value, props.isProductList);
|
|
@@ -38917,8 +39112,8 @@ function getNumberInRange({ val, max, min }) {
|
|
|
38917
39112
|
return Math.min(Math.max(val, isNaN(min) ? val : min), isNaN(max) ? val : max);
|
|
38918
39113
|
}
|
|
38919
39114
|
function getTransformValues(el) {
|
|
38920
|
-
const { transform } = window.getComputedStyle(el);
|
|
38921
|
-
return
|
|
39115
|
+
const { transform: transform2 } = window.getComputedStyle(el);
|
|
39116
|
+
return transform2.split(/[(,)]/).slice(1, -1).map((v) => parseFloat(v));
|
|
38922
39117
|
}
|
|
38923
39118
|
function getScaleMultipliers(transformElements) {
|
|
38924
39119
|
let widthMultiplier = 1;
|
|
@@ -42034,9 +42229,9 @@ function requireLodash() {
|
|
|
42034
42229
|
});
|
|
42035
42230
|
return result2;
|
|
42036
42231
|
}
|
|
42037
|
-
function overArg(func,
|
|
42232
|
+
function overArg(func, transform2) {
|
|
42038
42233
|
return function(arg) {
|
|
42039
|
-
return func(
|
|
42234
|
+
return func(transform2(arg));
|
|
42040
42235
|
};
|
|
42041
42236
|
}
|
|
42042
42237
|
function replaceHolders(array, placeholder) {
|
|
@@ -42143,7 +42338,7 @@ function requireLodash() {
|
|
|
42143
42338
|
var dataViewCtorString = toSource(DataView2), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set2), weakMapCtorString = toSource(WeakMap2);
|
|
42144
42339
|
var symbolProto = Symbol2 ? Symbol2.prototype : undefined$1, symbolValueOf = symbolProto ? symbolProto.valueOf : undefined$1, symbolToString = symbolProto ? symbolProto.toString : undefined$1;
|
|
42145
42340
|
function lodash2(value) {
|
|
42146
|
-
if (
|
|
42341
|
+
if (isObjectLike2(value) && !isArray3(value) && !(value instanceof LazyWrapper)) {
|
|
42147
42342
|
if (value instanceof LodashWrapper) {
|
|
42148
42343
|
return value;
|
|
42149
42344
|
}
|
|
@@ -42824,19 +43019,19 @@ function requireLodash() {
|
|
|
42824
43019
|
return func == null ? undefined$1 : apply2(func, object, args);
|
|
42825
43020
|
}
|
|
42826
43021
|
function baseIsArguments(value) {
|
|
42827
|
-
return
|
|
43022
|
+
return isObjectLike2(value) && baseGetTag(value) == argsTag;
|
|
42828
43023
|
}
|
|
42829
43024
|
function baseIsArrayBuffer(value) {
|
|
42830
|
-
return
|
|
43025
|
+
return isObjectLike2(value) && baseGetTag(value) == arrayBufferTag;
|
|
42831
43026
|
}
|
|
42832
43027
|
function baseIsDate(value) {
|
|
42833
|
-
return
|
|
43028
|
+
return isObjectLike2(value) && baseGetTag(value) == dateTag;
|
|
42834
43029
|
}
|
|
42835
43030
|
function baseIsEqual(value, other, bitmask, customizer, stack2) {
|
|
42836
43031
|
if (value === other) {
|
|
42837
43032
|
return true;
|
|
42838
43033
|
}
|
|
42839
|
-
if (value == null || other == null || !
|
|
43034
|
+
if (value == null || other == null || !isObjectLike2(value) && !isObjectLike2(other)) {
|
|
42840
43035
|
return value !== value && other !== other;
|
|
42841
43036
|
}
|
|
42842
43037
|
return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack2);
|
|
@@ -42872,7 +43067,7 @@ function requireLodash() {
|
|
|
42872
43067
|
return equalObjects(object, other, bitmask, customizer, equalFunc, stack2);
|
|
42873
43068
|
}
|
|
42874
43069
|
function baseIsMap(value) {
|
|
42875
|
-
return
|
|
43070
|
+
return isObjectLike2(value) && getTag(value) == mapTag;
|
|
42876
43071
|
}
|
|
42877
43072
|
function baseIsMatch(object, source, matchData, customizer) {
|
|
42878
43073
|
var index = matchData.length, length = index, noCustomizer = !customizer;
|
|
@@ -42913,13 +43108,13 @@ function requireLodash() {
|
|
|
42913
43108
|
return pattern.test(toSource(value));
|
|
42914
43109
|
}
|
|
42915
43110
|
function baseIsRegExp(value) {
|
|
42916
|
-
return
|
|
43111
|
+
return isObjectLike2(value) && baseGetTag(value) == regexpTag;
|
|
42917
43112
|
}
|
|
42918
43113
|
function baseIsSet(value) {
|
|
42919
|
-
return
|
|
43114
|
+
return isObjectLike2(value) && getTag(value) == setTag;
|
|
42920
43115
|
}
|
|
42921
43116
|
function baseIsTypedArray(value) {
|
|
42922
|
-
return
|
|
43117
|
+
return isObjectLike2(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
|
|
42923
43118
|
}
|
|
42924
43119
|
function baseIteratee(value) {
|
|
42925
43120
|
if (typeof value == "function") {
|
|
@@ -44429,7 +44624,7 @@ function requireLodash() {
|
|
|
44429
44624
|
function objectToString2(value) {
|
|
44430
44625
|
return nativeObjectToString.call(value);
|
|
44431
44626
|
}
|
|
44432
|
-
function overRest(func, start,
|
|
44627
|
+
function overRest(func, start, transform3) {
|
|
44433
44628
|
start = nativeMax(start === undefined$1 ? func.length - 1 : start, 0);
|
|
44434
44629
|
return function() {
|
|
44435
44630
|
var args = arguments, index = -1, length = nativeMax(args.length - start, 0), array = Array2(length);
|
|
@@ -44441,7 +44636,7 @@ function requireLodash() {
|
|
|
44441
44636
|
while (++index < start) {
|
|
44442
44637
|
otherArgs[index] = args[index];
|
|
44443
44638
|
}
|
|
44444
|
-
otherArgs[start] =
|
|
44639
|
+
otherArgs[start] = transform3(array);
|
|
44445
44640
|
return apply2(func, this, otherArgs);
|
|
44446
44641
|
};
|
|
44447
44642
|
}
|
|
@@ -45463,7 +45658,7 @@ function requireLodash() {
|
|
|
45463
45658
|
var isArguments = baseIsArguments(/* @__PURE__ */ function() {
|
|
45464
45659
|
return arguments;
|
|
45465
45660
|
}()) ? baseIsArguments : function(value) {
|
|
45466
|
-
return
|
|
45661
|
+
return isObjectLike2(value) && hasOwnProperty2.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
|
|
45467
45662
|
};
|
|
45468
45663
|
var isArray3 = Array2.isArray;
|
|
45469
45664
|
var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer;
|
|
@@ -45471,15 +45666,15 @@ function requireLodash() {
|
|
|
45471
45666
|
return value != null && isLength(value.length) && !isFunction2(value);
|
|
45472
45667
|
}
|
|
45473
45668
|
function isArrayLikeObject(value) {
|
|
45474
|
-
return
|
|
45669
|
+
return isObjectLike2(value) && isArrayLike(value);
|
|
45475
45670
|
}
|
|
45476
45671
|
function isBoolean2(value) {
|
|
45477
|
-
return value === true || value === false ||
|
|
45672
|
+
return value === true || value === false || isObjectLike2(value) && baseGetTag(value) == boolTag;
|
|
45478
45673
|
}
|
|
45479
45674
|
var isBuffer = nativeIsBuffer || stubFalse;
|
|
45480
45675
|
var isDate2 = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;
|
|
45481
45676
|
function isElement(value) {
|
|
45482
|
-
return
|
|
45677
|
+
return isObjectLike2(value) && value.nodeType === 1 && !isPlainObject4(value);
|
|
45483
45678
|
}
|
|
45484
45679
|
function isEmpty(value) {
|
|
45485
45680
|
if (value == null) {
|
|
@@ -45511,7 +45706,7 @@ function requireLodash() {
|
|
|
45511
45706
|
return result3 === undefined$1 ? baseIsEqual(value, other, undefined$1, customizer) : !!result3;
|
|
45512
45707
|
}
|
|
45513
45708
|
function isError2(value) {
|
|
45514
|
-
if (!
|
|
45709
|
+
if (!isObjectLike2(value)) {
|
|
45515
45710
|
return false;
|
|
45516
45711
|
}
|
|
45517
45712
|
var tag = baseGetTag(value);
|
|
@@ -45537,7 +45732,7 @@ function requireLodash() {
|
|
|
45537
45732
|
var type = typeof value;
|
|
45538
45733
|
return value != null && (type == "object" || type == "function");
|
|
45539
45734
|
}
|
|
45540
|
-
function
|
|
45735
|
+
function isObjectLike2(value) {
|
|
45541
45736
|
return value != null && typeof value == "object";
|
|
45542
45737
|
}
|
|
45543
45738
|
var isMap2 = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
|
|
@@ -45564,10 +45759,10 @@ function requireLodash() {
|
|
|
45564
45759
|
return value == null;
|
|
45565
45760
|
}
|
|
45566
45761
|
function isNumber2(value) {
|
|
45567
|
-
return typeof value == "number" ||
|
|
45762
|
+
return typeof value == "number" || isObjectLike2(value) && baseGetTag(value) == numberTag;
|
|
45568
45763
|
}
|
|
45569
45764
|
function isPlainObject4(value) {
|
|
45570
|
-
if (!
|
|
45765
|
+
if (!isObjectLike2(value) || baseGetTag(value) != objectTag) {
|
|
45571
45766
|
return false;
|
|
45572
45767
|
}
|
|
45573
45768
|
var proto = getPrototype(value);
|
|
@@ -45583,20 +45778,20 @@ function requireLodash() {
|
|
|
45583
45778
|
}
|
|
45584
45779
|
var isSet2 = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
|
|
45585
45780
|
function isString2(value) {
|
|
45586
|
-
return typeof value == "string" || !isArray3(value) &&
|
|
45781
|
+
return typeof value == "string" || !isArray3(value) && isObjectLike2(value) && baseGetTag(value) == stringTag;
|
|
45587
45782
|
}
|
|
45588
45783
|
function isSymbol2(value) {
|
|
45589
|
-
return typeof value == "symbol" ||
|
|
45784
|
+
return typeof value == "symbol" || isObjectLike2(value) && baseGetTag(value) == symbolTag;
|
|
45590
45785
|
}
|
|
45591
45786
|
var isTypedArray2 = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
|
|
45592
45787
|
function isUndefined2(value) {
|
|
45593
45788
|
return value === undefined$1;
|
|
45594
45789
|
}
|
|
45595
45790
|
function isWeakMap(value) {
|
|
45596
|
-
return
|
|
45791
|
+
return isObjectLike2(value) && getTag(value) == weakMapTag;
|
|
45597
45792
|
}
|
|
45598
45793
|
function isWeakSet(value) {
|
|
45599
|
-
return
|
|
45794
|
+
return isObjectLike2(value) && baseGetTag(value) == weakSetTag;
|
|
45600
45795
|
}
|
|
45601
45796
|
var lt = createRelationalOperation(baseLt);
|
|
45602
45797
|
var lte = createRelationalOperation(function(value, other) {
|
|
@@ -45856,7 +46051,7 @@ function requireLodash() {
|
|
|
45856
46051
|
}
|
|
45857
46052
|
var toPairs = createToPairs(keys);
|
|
45858
46053
|
var toPairsIn = createToPairs(keysIn);
|
|
45859
|
-
function
|
|
46054
|
+
function transform2(object, iteratee2, accumulator) {
|
|
45860
46055
|
var isArr = isArray3(object), isArrLike = isArr || isBuffer(object) || isTypedArray2(object);
|
|
45861
46056
|
iteratee2 = getIteratee(iteratee2, 4);
|
|
45862
46057
|
if (accumulator == null) {
|
|
@@ -46359,7 +46554,7 @@ function requireLodash() {
|
|
|
46359
46554
|
}
|
|
46360
46555
|
return result3;
|
|
46361
46556
|
}
|
|
46362
|
-
function
|
|
46557
|
+
function toPath2(value) {
|
|
46363
46558
|
if (isArray3(value)) {
|
|
46364
46559
|
return arrayMap(value, toKey);
|
|
46365
46560
|
}
|
|
@@ -46530,9 +46725,9 @@ function requireLodash() {
|
|
|
46530
46725
|
lodash2.toArray = toArray;
|
|
46531
46726
|
lodash2.toPairs = toPairs;
|
|
46532
46727
|
lodash2.toPairsIn = toPairsIn;
|
|
46533
|
-
lodash2.toPath =
|
|
46728
|
+
lodash2.toPath = toPath2;
|
|
46534
46729
|
lodash2.toPlainObject = toPlainObject;
|
|
46535
|
-
lodash2.transform =
|
|
46730
|
+
lodash2.transform = transform2;
|
|
46536
46731
|
lodash2.unary = unary;
|
|
46537
46732
|
lodash2.union = union;
|
|
46538
46733
|
lodash2.unionBy = unionBy;
|
|
@@ -46631,7 +46826,7 @@ function requireLodash() {
|
|
|
46631
46826
|
lodash2.isNull = isNull2;
|
|
46632
46827
|
lodash2.isNumber = isNumber2;
|
|
46633
46828
|
lodash2.isObject = isObject2;
|
|
46634
|
-
lodash2.isObjectLike =
|
|
46829
|
+
lodash2.isObjectLike = isObjectLike2;
|
|
46635
46830
|
lodash2.isPlainObject = isPlainObject4;
|
|
46636
46831
|
lodash2.isRegExp = isRegExp2;
|
|
46637
46832
|
lodash2.isSafeInteger = isSafeInteger;
|
|
@@ -47207,7 +47402,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
47207
47402
|
setup(__props, { expose: __expose }) {
|
|
47208
47403
|
const productRecommendations = ref(null);
|
|
47209
47404
|
const fetch2 = () => {
|
|
47210
|
-
|
|
47405
|
+
var _a25;
|
|
47406
|
+
(_a25 = productRecommendations == null ? void 0 : productRecommendations.value) == null ? void 0 : _a25.fetch();
|
|
47211
47407
|
};
|
|
47212
47408
|
__expose({ fetch: fetch2 });
|
|
47213
47409
|
return (_ctx, _cache) => {
|