@searchcraft/javascript-sdk 0.2.5 → 0.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{searchcraft-auto-search-form_17.cjs.entry.js → searchcraft-auto-search-form_18.cjs.entry.js} +28 -16
- package/dist/cjs/searchcraft-auto-search-form_18.cjs.entry.js.map +1 -0
- package/dist/cjs/searchcraft-base-search-form.cjs.entry.js +1 -1
- package/dist/cjs/searchcraft-button.cjs.entry.js +1 -1
- package/dist/cjs/searchcraft-javascript-sdk.cjs.js +1 -1
- package/dist/collection/assets/searchcraft-check-icon.js +9 -0
- package/dist/collection/assets/searchcraft-check-icon.js.map +1 -0
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/searchcraft-auto-search-form/searchcraft-auto-search-form.js +1 -1
- package/dist/collection/components/searchcraft-base-search-form/searchcraft-base-search-form.js +1 -1
- package/dist/collection/components/searchcraft-base-search-result/searchcraft-base-search-result.js +3 -3
- package/dist/collection/components/searchcraft-base-search-result/searchcraft-base-search-result.js.map +1 -1
- package/dist/collection/components/searchcraft-base-search-result/searchcraft-base-search-result.module.css +10 -0
- package/dist/collection/components/searchcraft-button/searchcraft-button.js +1 -1
- package/dist/collection/components/searchcraft-error-message/searchcraft-error-message.js +1 -1
- package/dist/collection/components/searchcraft-filters-list/searchcraft-filters-list.js +7 -5
- package/dist/collection/components/searchcraft-filters-list/searchcraft-filters-list.js.map +1 -1
- package/dist/collection/components/searchcraft-filters-list/searchcraft-filters-list.module.css +20 -7
- package/dist/collection/components/searchcraft-input/searchcraft-input.js +1 -1
- package/dist/collection/components/searchcraft-spinner-dark/searchcraft-spinner-dark.js +1 -1
- package/dist/collection/components/searchcraft-spinner-light/searchcraft-spinner-light.js +1 -1
- package/dist/components/index.js +2 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/{p-1c377190.js → p-0eb562da.js} +3 -3
- package/dist/components/{p-1c377190.js.map → p-0eb562da.js.map} +1 -1
- package/dist/components/{p-848301b7.js → p-14f328f4.js} +2 -2
- package/dist/components/{p-848301b7.js.map → p-14f328f4.js.map} +1 -1
- package/dist/components/{p-bdf281cc.js → p-1b18e9fe.js} +5 -5
- package/dist/components/p-1b18e9fe.js.map +1 -0
- package/dist/components/{p-576f0d2b.js → p-52b81ff4.js} +3 -3
- package/dist/components/{p-576f0d2b.js.map → p-52b81ff4.js.map} +1 -1
- package/dist/components/{p-b5f97e04.js → p-643cfdcf.js} +5 -5
- package/dist/components/{p-b5f97e04.js.map → p-643cfdcf.js.map} +1 -1
- package/dist/components/{p-3fece4e2.js → p-9952c9ba.js} +2 -2
- package/dist/components/{p-3fece4e2.js.map → p-9952c9ba.js.map} +1 -1
- package/dist/components/{p-25f18f2e.js → p-bdf84774.js} +2 -2
- package/dist/components/{p-25f18f2e.js.map → p-bdf84774.js.map} +1 -1
- package/dist/components/p-d3187f5a.js +29 -0
- package/dist/components/p-d3187f5a.js.map +1 -0
- package/dist/components/searchcraft-auto-search-form.js +6 -6
- package/dist/components/searchcraft-base-search-form.js +7 -7
- package/dist/components/searchcraft-base-search-result.js +1 -1
- package/dist/components/searchcraft-base-search-results.js +2 -2
- package/dist/components/searchcraft-button.js +1 -1
- package/dist/components/searchcraft-check-icon.d.ts +11 -0
- package/dist/components/searchcraft-check-icon.js +8 -0
- package/dist/components/searchcraft-check-icon.js.map +1 -0
- package/dist/components/searchcraft-clear-input-button.js +1 -1
- package/dist/components/searchcraft-error-message.js +1 -1
- package/dist/components/searchcraft-filters-list.js +15 -7
- package/dist/components/searchcraft-filters-list.js.map +1 -1
- package/dist/components/searchcraft-input.js +1 -1
- package/dist/components/searchcraft-spinner-dark.js +1 -1
- package/dist/components/searchcraft-spinner-light.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{searchcraft-auto-search-form_17.entry.js → searchcraft-auto-search-form_18.entry.js} +28 -17
- package/dist/esm/searchcraft-auto-search-form_18.entry.js.map +1 -0
- package/dist/esm/searchcraft-base-search-form.entry.js +1 -1
- package/dist/esm/searchcraft-button.entry.js +1 -1
- package/dist/esm/searchcraft-javascript-sdk.js +1 -1
- package/dist/searchcraft-javascript-sdk/{p-cc454542.entry.js → p-66f38e89.entry.js} +2 -2
- package/dist/searchcraft-javascript-sdk/p-67cc5ccb.entry.js +2 -0
- package/dist/searchcraft-javascript-sdk/p-67cc5ccb.entry.js.map +1 -0
- package/dist/searchcraft-javascript-sdk/{p-63b3b565.entry.js → p-d9efd790.entry.js} +2 -2
- package/dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js +1 -1
- package/dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js.map +1 -1
- package/dist/types/assets/searchcraft-check-icon.d.ts +3 -0
- package/dist/types/components.d.ts +13 -0
- package/package.json +1 -1
- package/dist/cjs/searchcraft-auto-search-form_17.cjs.entry.js.map +0 -1
- package/dist/components/p-bdf281cc.js.map +0 -1
- package/dist/esm/searchcraft-auto-search-form_17.entry.js.map +0 -1
- package/dist/searchcraft-javascript-sdk/p-cc9a02ef.entry.js +0 -2
- package/dist/searchcraft-javascript-sdk/p-cc9a02ef.entry.js.map +0 -1
- /package/dist/searchcraft-javascript-sdk/{p-cc454542.entry.js.map → p-66f38e89.entry.js.map} +0 -0
- /package/dist/searchcraft-javascript-sdk/{p-63b3b565.entry.js.map → p-d9efd790.entry.js.map} +0 -0
|
@@ -104,12 +104,12 @@ const SearchcraftAutoSearchForm = class {
|
|
|
104
104
|
if (this.query.length > 0 && ((_c = (_b = (_a = this.searchResults) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.hits) === null || _c === void 0 ? void 0 : _c.length) === 0) {
|
|
105
105
|
this.inputClearedOrNoResults.emit();
|
|
106
106
|
}
|
|
107
|
-
return (h("form", { key: '
|
|
107
|
+
return (h("form", { key: 'cfc0e29f0f35598c13f5d87720f38d74cba292fb', class: `${formClass}`, onSubmit: this.handleFormSubmit }, h("searchcraft-input-label", { key: 'fd5635505ee5f863f128912377960752d4dccd2d', label: this.labelForInput }), h("searchcraft-input", { key: '84c3a6da7ed48e835aa74f87ad862672d38876c7', customStyles: parsedCustomStyles, "input-caption-value": this.inputCaptionValue, "input-icon-height": this.inputIconHeight, "input-icon-width": this.inputIconWidth, "is-requesting": this.isRequesting, onClearInput: this.handleClearInput, onInputKeyUp: this.handleInputKeyUp, onSearchInputChange: this.handleInputChange, "placeholder-value": this.placeholderValue, query: this.query, "right-to-left-orientation": this.rightToLeftOrientation }), this.error && (h("searchcraft-error-message", { key: 'bcb99f333d73ed811c7d7a6d85736ba94fb7fa56', errorMessage: 'Please enter a search query.' }))));
|
|
108
108
|
}
|
|
109
109
|
};
|
|
110
110
|
SearchcraftAutoSearchForm.style = SearchcraftAutoSearchFormStyle0;
|
|
111
111
|
|
|
112
|
-
const searchcraftBaseSearchResultModuleCss = "@charset \"UTF-8\";:root{--font-stack:Helvetica, Arial, sans-serif}.interactiveResultContainerLight{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#FAFAFA}@media (min-width: 600px){.interactiveResultContainerLight{flex-direction:row}}.interactiveResultContainerDark{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#2E2E2E}@media (min-width: 600px){.interactiveResultContainerDark{flex-direction:row}}.resultContainer{align-items:flex-start;display:flex;flex-direction:column;gap:16px}@media (min-width: 600px){.resultContainer{flex-direction:row}}.interactiveIconLarge{display:inline-block;position:absolute;right:5px;top:8px}@media (max-width: 600px){.interactiveIconLarge{display:none}}.interactiveIconSmall{display:inline-block;position:absolute;right:5px;top:-2px}@media (min-width: 600px){.interactiveIconSmall{display:none}}.imageContainer{max-width:100%}.contentContainer{max-height:100%;max-width:100%}@media (min-width: 600px){.contentContainer{max-width:50%}}.secondaryContentContainer{display:flex}.imageLight{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #D9D9D9}.imageDark{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #333}.headingLight{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;color:#292929}.headingDark{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;color:#FFF}.subheadingLight{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;color:#737373}.subheadingDark{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;color:#BFBFBF}.primaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#404040}.primaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#E6E6E6}.secondaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#404040}.secondaryContentLight::after{content:\"•\";color:#404040;font-size:1em;margin-left:5px;margin-right:5px}.secondaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#E6E6E6}.tertiaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#404040}.tertiaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;color:#E6E6E6}";
|
|
112
|
+
const searchcraftBaseSearchResultModuleCss = "@charset \"UTF-8\";:root{--font-stack:Helvetica, Arial, sans-serif}.interactiveResultContainerLight{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#FAFAFA}@media (min-width: 600px){.interactiveResultContainerLight{flex-direction:row}}.interactiveResultContainerDark{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#2E2E2E}@media (min-width: 600px){.interactiveResultContainerDark{flex-direction:row}}.resultContainer{align-items:flex-start;display:flex;flex-direction:column;gap:16px}@media (min-width: 600px){.resultContainer{flex-direction:row}}.interactiveIconLarge{display:inline-block;position:absolute;right:5px;top:8px}@media (max-width: 600px){.interactiveIconLarge{display:none}}.interactiveIconSmall{display:inline-block;position:absolute;right:5px;top:-2px}@media (min-width: 600px){.interactiveIconSmall{display:none}}.imageContainer{max-width:100%}.contentContainer{max-height:100%;max-width:100%}@media (min-width: 600px){.contentContainer{max-width:50%}}.secondaryContentContainer{display:flex}.imageLight{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #D9D9D9}.imageDark{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #333}.headingLight{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;-webkit-font-smoothing:antialiased;color:#292929}.headingDark{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;-webkit-font-smoothing:antialiased;color:#FFF}.subheadingLight{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#737373}.subheadingDark{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#BFBFBF}.primaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.primaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}.secondaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.secondaryContentLight::after{content:\"•\";color:#404040;font-size:1em;margin-left:5px;margin-right:5px}.secondaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}.tertiaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.tertiaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}";
|
|
113
113
|
const SearchcraftBaseSearchResultStyle0 = searchcraftBaseSearchResultModuleCss;
|
|
114
114
|
|
|
115
115
|
const SearchcraftBaseSearchResult = class {
|
|
@@ -154,9 +154,9 @@ const SearchcraftBaseSearchResult = class {
|
|
|
154
154
|
render() {
|
|
155
155
|
const isLightTheme = this.themeMode === 'light';
|
|
156
156
|
const styles = this.parseStyles();
|
|
157
|
-
const imageContainer = (h("div", { key: '
|
|
158
|
-
const contentContainer = (h("div", { key: '
|
|
159
|
-
return (h("div", { key: '
|
|
157
|
+
const imageContainer = this.imageSource && (h("div", { key: 'bc2c9e7e6fdfdd7a159adeaae93ee295f3871bb1', class: 'imageContainer' }, h("img", { key: '403cf6f083a0fab8c0d84f858e6f799bb5e39856', alt: this.imageDescription, class: isLightTheme ? 'imageLight' : 'imageDark', src: this.imageSource, style: styles.image || {} })));
|
|
158
|
+
const contentContainer = (h("div", { key: 'ec56243d676a5dfbdc7d9dc5be9f2e078ab3e599', class: 'contentContainer' }, h("h2", { key: 'e2d73b3c6c18753fee3e3a2a8526a68c62a0a2f5', class: isLightTheme ? 'headingLight' : 'headingDark', style: styles.heading || {} }, this.headingText), h("h3", { key: 'fccf35b5a06c09c96150568d4cd71bacea1fe15d', class: isLightTheme ? 'subheadingLight' : 'subheadingDark', style: styles.subheading || {} }, this.subheadingText), h("p", { key: '95b64831fd0248f69773cafa6357133f9758748c', class: isLightTheme ? 'primaryContentLight' : 'primaryContentDark', style: styles.primaryContent || {} }, this.primaryContent), h("div", { key: 'f1e597968aab316067762bca3e39bccb50f3b34a', class: 'secondaryContentContainer' }, h("p", { key: '05ccdbb2854cd538fa2fd9e3a6efe8fa8ea46003', class: isLightTheme ? 'secondaryContentLight' : 'secondaryContentDark', style: styles.secondaryContent || {} }, this.secondaryContent), h("p", { key: 'ca2b96c02c9d8b073b0e0cff3e288d9eba7e3cd1', class: isLightTheme ? 'tertiaryContentLight' : 'tertiaryContentDark', style: styles.tertiaryContent || {} }, this.tertiaryContent)), this.buttonText && (h("button", { key: '9d728eb6dcc2cdc2d0b438e79286795835dbf9e6', onClick: this.handleButtonClick, style: styles.button || {}, type: 'button' }, this.buttonText))));
|
|
159
|
+
return (h("div", { key: '44c9677d5c3c75439b9d73d8e60e5744d2ee9be0', class: this.isInteractive
|
|
160
160
|
? isLightTheme
|
|
161
161
|
? 'interactiveResultContainerLight'
|
|
162
162
|
: 'interactiveResultContainerDark'
|
|
@@ -262,6 +262,15 @@ const SearchcraftBaseSearchResults = class {
|
|
|
262
262
|
};
|
|
263
263
|
SearchcraftBaseSearchResults.style = SearchcraftBaseSearchResultsStyle0;
|
|
264
264
|
|
|
265
|
+
const SearchcraftCheckIcon = class {
|
|
266
|
+
constructor(hostRef) {
|
|
267
|
+
registerInstance(this, hostRef);
|
|
268
|
+
}
|
|
269
|
+
render() {
|
|
270
|
+
return (h("svg", { key: '3db200942b79612a38293544a029c6854dfa4beb', width: '16', height: '16', viewBox: '0 0 16 16', fill: 'none' }, h("title", { key: 'b7b6af8651edb5cc0e054ed775b9029c6c93535e' }, "Checkbox Check"), h("path", { key: '7c74edc45f007245e4c6e4fd5d37dbc6dad20de0', d: 'M13.9999 2L5.74988 10L1.99988 6.36364', stroke: 'white', "stroke-width": '3', "stroke-linecap": 'round', "stroke-linejoin": 'round' })));
|
|
271
|
+
}
|
|
272
|
+
};
|
|
273
|
+
|
|
265
274
|
const SearchcraftClearIconSet = class {
|
|
266
275
|
constructor(hostRef) {
|
|
267
276
|
registerInstance(this, hostRef);
|
|
@@ -318,12 +327,12 @@ const SearchcraftErrorMessage = class {
|
|
|
318
327
|
}
|
|
319
328
|
render() {
|
|
320
329
|
const errorMessageStyle = this.theme === 'light' ? 'errorMessageLight' : 'errorMessageDark';
|
|
321
|
-
return (h("p", { key: '
|
|
330
|
+
return (h("p", { key: 'af47ef1acca6beb5ba557f55a6f911fad9184bb7', class: classNames(errorMessageStyle) }, this.errorMessage || 'Search term is required.'));
|
|
322
331
|
}
|
|
323
332
|
};
|
|
324
333
|
SearchcraftErrorMessage.style = SearchcraftErrorMessageStyle0;
|
|
325
334
|
|
|
326
|
-
const searchcraftFiltersListModuleCss = "
|
|
335
|
+
const searchcraftFiltersListModuleCss = ".filtersList{width:100%}.checkboxLabel{align-items:center;color:#292929;display:flex;font-family:\"Source Sans Pro\";font-size:14px;font-weight:600;gap:14px;position:relative;-webkit-font-smoothing:antialiased}.checkboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:#EDEDED;border:1px solid #D9D9D9;cursor:pointer;display:flex;height:24px;justify-content:center;width:24px}.checkboxLabel input[type=checkbox]:checked{background-color:#000;position:relative}.checkboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.remainingFilterListCheckbox{margin-left:16px}.childCheckboxLabel{align-items:center;color:#292929;display:flex;font-family:\"Source Sans Pro\";font-size:14px;font-weight:600;gap:12px;position:relative}.childCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:#EDEDED;border:1px solid #D9D9D9;cursor:pointer;display:flex;height:24px;justify-content:center;position:relative;width:24px;-webkit-font-smoothing:antialiased}.childCheckboxLabel input[type=checkbox]:checked{background-color:#000;position:relative}.childCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.checkContainer{display:none;height:16px;width:16px;position:absolute;top:10px;left:7px}";
|
|
327
336
|
const SearchcraftFiltersListStyle0 = searchcraftFiltersListModuleCss;
|
|
328
337
|
|
|
329
338
|
const SearchcraftFiltersList = class {
|
|
@@ -352,8 +361,7 @@ const SearchcraftFiltersList = class {
|
|
|
352
361
|
}
|
|
353
362
|
connectedCallback() {
|
|
354
363
|
var _a;
|
|
355
|
-
const state = this.searchStore;
|
|
356
|
-
// Initial population of facets if available
|
|
364
|
+
const state = this.searchStore;
|
|
357
365
|
if ((_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data.facets) {
|
|
358
366
|
this.populateFiltersFromFacets(state.searchResults.data.facets);
|
|
359
367
|
}
|
|
@@ -371,7 +379,6 @@ const SearchcraftFiltersList = class {
|
|
|
371
379
|
this.query = state.query || '';
|
|
372
380
|
this.isRequesting = state.isRequesting;
|
|
373
381
|
this.resultsCount = ((_c = (_b = (_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.hits) === null || _c === void 0 ? void 0 : _c.length) || 0;
|
|
374
|
-
// Populate filters when facets are updated
|
|
375
382
|
if ((_d = state.searchResults) === null || _d === void 0 ? void 0 : _d.data.facets) {
|
|
376
383
|
this.populateFiltersFromFacets(state.searchResults.data.facets);
|
|
377
384
|
}
|
|
@@ -386,6 +393,10 @@ const SearchcraftFiltersList = class {
|
|
|
386
393
|
var _a;
|
|
387
394
|
const newFilters = flattenFacets(((_a = facets[0]) === null || _a === void 0 ? void 0 : _a.section) || []);
|
|
388
395
|
const filtersMap = new Map();
|
|
396
|
+
this.dynamicFilters.forEach((filter) => {
|
|
397
|
+
const key = filter.value.split('/').pop() || '';
|
|
398
|
+
filtersMap.set(key, filter);
|
|
399
|
+
});
|
|
389
400
|
newFilters.forEach((filter) => {
|
|
390
401
|
const key = filter.value.split('/').pop() || '';
|
|
391
402
|
const existingFilter = filtersMap.get(key);
|
|
@@ -423,9 +434,9 @@ const SearchcraftFiltersList = class {
|
|
|
423
434
|
const isChecked = this.selectedFilters.has(filter.value);
|
|
424
435
|
const children = this.dynamicFilters.filter((child) => child.value.startsWith(`${filter.value}/`) &&
|
|
425
436
|
child.value !== filter.value);
|
|
426
|
-
return (h("div", { key: filter.value }, h("label", { class: 'checkboxLabel' }, h("input", { class: 'filterCheckbox', checked: isChecked, onChange: (event) => this.handleFilterChange(filter.value, event.target.checked), type: 'checkbox' }), this.formatLabel(filter.label)), children.map((child) => {
|
|
437
|
+
return (h("div", { key: filter.value }, h("label", { class: 'checkboxLabel' }, h("input", { class: 'filterCheckbox', checked: isChecked, onChange: (event) => this.handleFilterChange(filter.value, event.target.checked), type: 'checkbox' }), h("div", { class: 'checkContainer' }, h("searchcraft-check-icon", null)), this.formatLabel(filter.label)), children.map((child) => {
|
|
427
438
|
const isChildChecked = this.selectedFilters.has(child.value);
|
|
428
|
-
return (h("label", { class: 'childCheckboxLabel', key: child.value, style: { marginLeft: '20px' } }, h("input", { class: 'childFilterCheckbox', checked: isChildChecked, onChange: (event) => this.handleFilterChange(child.value, event.target.checked), type: 'checkbox' }), this.formatLabel(child.label.split('/').pop() || '')));
|
|
439
|
+
return (h("label", { class: 'childCheckboxLabel', key: child.value, style: { marginLeft: '20px' } }, h("input", { class: 'childFilterCheckbox', checked: isChildChecked, onChange: (event) => this.handleFilterChange(child.value, event.target.checked), type: 'checkbox' }), h("div", { class: 'checkContainer' }, h("searchcraft-check-icon", null)), this.formatLabel(child.label.split('/').pop() || '')));
|
|
429
440
|
})));
|
|
430
441
|
})));
|
|
431
442
|
}
|
|
@@ -486,7 +497,7 @@ const SearchcraftInput = class {
|
|
|
486
497
|
const placeholderStyle = {
|
|
487
498
|
fontSize: validatedCustomStyles.placeholderFontSize || '16px',
|
|
488
499
|
};
|
|
489
|
-
return (h("div", { key: '
|
|
500
|
+
return (h("div", { key: '3c655e3572de20f333b75f85e45cc957ac0bc006', class: classNames(containerClassName, this.formClassName, 'searchcraft-input-form') }, this.rightToLeftOrientation ? (h(Fragment, null, h("input", { autoComplete: 'off', class: classNames(inputClassName, 'searchcraft-input'), id: 'searchcraft-input-id', onChange: this.handleInputChange.bind(this), onKeyUp: this.handleInputKeyUp.bind(this), placeholder: this.placeholderValue, type: 'text', value: this.query, style: validatedCustomStyles }), h("style", null, `
|
|
490
501
|
#searchcraft-input-id::placeholder {
|
|
491
502
|
font-size: ${placeholderStyle.fontSize};
|
|
492
503
|
}
|
|
@@ -712,7 +723,7 @@ const SearchcraftSpinnerDark = class {
|
|
|
712
723
|
registerInstance(this, hostRef);
|
|
713
724
|
}
|
|
714
725
|
render() {
|
|
715
|
-
return (h("div", { key: '
|
|
726
|
+
return (h("div", { key: 'fbbd8b46026e1c1c83b59efd68a5cecdca7cad59', class: 'spinnerContainer' }, h("div", { key: '7fb274ca3ed3d9b69eef7faa77413b1e1fe68ef5', class: 'spinnerDark' })));
|
|
716
727
|
}
|
|
717
728
|
};
|
|
718
729
|
SearchcraftSpinnerDark.style = SearchcraftSpinnerDarkStyle0;
|
|
@@ -725,7 +736,7 @@ const SearchcraftSpinnerLight = class {
|
|
|
725
736
|
registerInstance(this, hostRef);
|
|
726
737
|
}
|
|
727
738
|
render() {
|
|
728
|
-
return (h("div", { key: '
|
|
739
|
+
return (h("div", { key: '5f8d9dbe616324b466436037581491efff818065', class: 'spinnerContainer' }, h("div", { key: '8152d98d48ac5a4a55c49048a385301238b54932', class: 'spinnerLight' })));
|
|
729
740
|
}
|
|
730
741
|
};
|
|
731
742
|
SearchcraftSpinnerLight.style = SearchcraftSpinnerLightStyle0;
|
|
@@ -784,6 +795,6 @@ const SearchcraftToggleButton = class {
|
|
|
784
795
|
};
|
|
785
796
|
SearchcraftToggleButton.style = SearchcraftToggleButtonStyle0;
|
|
786
797
|
|
|
787
|
-
export { SearchcraftAutoSearchForm as searchcraft_auto_search_form, SearchcraftBaseSearchResult as searchcraft_base_search_result, SearchcraftBaseSearchResults as searchcraft_base_search_results, SearchcraftClearIconSet as searchcraft_clear_icon_set, SearchcraftClearInputButton as searchcraft_clear_input_button, SearchcraftErrorMessage as searchcraft_error_message, SearchcraftFiltersList as searchcraft_filters_list, SearchcraftInput as searchcraft_input, SearchcraftInputCaption as searchcraft_input_caption, SearchcraftInputIcon as searchcraft_input_icon, SearchcraftInputLabel as searchcraft_input_label, SearchcraftResultsInfo as searchcraft_results_info, SearchcraftSearchIconSet as searchcraft_search_icon_set, SearchcraftSlider as searchcraft_slider, SearchcraftSpinnerDark as searchcraft_spinner_dark, SearchcraftSpinnerLight as searchcraft_spinner_light, SearchcraftToggleButton as searchcraft_toggle_button };
|
|
798
|
+
export { SearchcraftAutoSearchForm as searchcraft_auto_search_form, SearchcraftBaseSearchResult as searchcraft_base_search_result, SearchcraftBaseSearchResults as searchcraft_base_search_results, SearchcraftCheckIcon as searchcraft_check_icon, SearchcraftClearIconSet as searchcraft_clear_icon_set, SearchcraftClearInputButton as searchcraft_clear_input_button, SearchcraftErrorMessage as searchcraft_error_message, SearchcraftFiltersList as searchcraft_filters_list, SearchcraftInput as searchcraft_input, SearchcraftInputCaption as searchcraft_input_caption, SearchcraftInputIcon as searchcraft_input_icon, SearchcraftInputLabel as searchcraft_input_label, SearchcraftResultsInfo as searchcraft_results_info, SearchcraftSearchIconSet as searchcraft_search_icon_set, SearchcraftSlider as searchcraft_slider, SearchcraftSpinnerDark as searchcraft_spinner_dark, SearchcraftSpinnerLight as searchcraft_spinner_light, SearchcraftToggleButton as searchcraft_toggle_button };
|
|
788
799
|
|
|
789
|
-
//# sourceMappingURL=searchcraft-auto-search-
|
|
800
|
+
//# sourceMappingURL=searchcraft-auto-search-form_18.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"searchcraft-auto-search-form.searchcraft-base-search-result.searchcraft-base-search-results.searchcraft-check-icon.searchcraft-clear-icon-set.searchcraft-clear-input-button.searchcraft-error-message.searchcraft-filters-list.searchcraft-input.searchcraft-input-caption.searchcraft-input-icon.searchcraft-input-label.searchcraft-results-info.searchcraft-search-icon-set.searchcraft-slider.searchcraft-spinner-dark.searchcraft-spinner-light.searchcraft-toggle-button.entry.js","mappings":";;;;;AAAA,MAAM,kCAAkC,GAAG,uLAAuL,CAAC;AACnO,wCAAe,kCAAkC;;MCyBpC,yBAAyB;;;;;QAyB5B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AK,CAAC;gBAC5C,IAAI,CAAC,WAAW,CAAC,eAAe,CAAC;oBAC/B,IAAI;iBACL,CAAC,CAAC;aACJ;YAED,IAAI;gBACF,MAAM,IAAI,CAAC,WAAW,CAAC,MAAM,EAAE,CAAC;aACjC;YAAC,OAAO,KAAK,EAAE;gBACd,OAAO,CAAC,KAAK,CAAC,gBAAgB,EAAE,KAAK,CAAC,CAAC;aACxC;SACF,CAAC;oBA1C8B,MAAM;wBAElB,KAAK;qBACR,EAAE;4BACK,CAAC;;IAKzB,gBAAgB;QACd,IAAI,CAAC,WAAW,GAAG,mBAAmB,CAAC,SAAS,CAAC,CAAC,KAAK;;YACrD,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,KAAK,IAAI,EAAE,CAAC;YAC/B,IAAI,CAAC,YAAY,GAAG,CAAA,MAAA,MAAA,MAAA,KAAK,CAAC,aAAa,0CAAE,IAAI,0CAAE,IAAI,0CAAE,MAAM,KAAI,CAAC,CAAC;SAClE,CAAC,CAAC;KACJ;IAED,oBAAoB;QAClB,IAAI,IAAI,CAAC,WAAW,EAAE;YACpB,IAAI,CAAC,WAAW,EAAE,CAAC;SACpB;KACF;IAwBD,MAAM;QACJ,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,YAAY,KAAK,CAAC,EAAE;YAC1C,OAAO,IAAI,CAAC;SACb;QAED,QACE,cACE,KAAK,EAAE,kBAAkB,IAAI,CAAC,QAAQ,GAAG,QAAQ,GAAG,EAAE,EAAE,EACxD,OAAO,EAAE,IAAI,CAAC,YAAY,EAC1B,IAAI,EAAC,QAAQ,IAEb,WAAK,KAAK,EAAE,iBAAiB,IAAI,CAAC,QAAQ,GAAG,QAAQ,GAAG,EAAE,EAAE,GAAI,CACzD,EACT;KACH;;;;;;","names":["SearchcraftCore"],"sources":["src/components/searchcraft-auto-search-form/searchcraft-auto-search-form.module.scss?tag=searchcraft-auto-search-form&encapsulation=shadow","src/components/searchcraft-auto-search-form/searchcraft-auto-search-form.tsx","src/components/searchcraft-base-search-result/searchcraft-base-search-result.module.scss?tag=searchcraft-base-search-result&encapsulation=shadow","src/components/searchcraft-base-search-result/searchcraft-base-search-result.tsx","src/components/searchcraft-base-search-results/searchcraft-base-search-results.module.scss?tag=searchcraft-base-search-results&encapsulation=shadow","src/components/searchcraft-base-search-results/searchcraft-base-search-results.tsx","src/assets/searchcraft-check-icon.tsx","src/assets/searchcraft-clear-icon-set.tsx","src/components/searchcraft-clear-input-button/searchcraft-clear-input-button.module.scss?tag=searchcraft-clear-input-button&encapsulation=shadow","src/components/searchcraft-clear-input-button/searchcraft-clear-input-button.tsx","src/components/searchcraft-error-message/searchcraft-error-message.module.scss?tag=searchcraft-error-message&encapsulation=shadow","src/components/searchcraft-error-message/searchcraft-error-message.tsx","src/components/searchcraft-filters-list/searchcraft-filters-list.module.scss?tag=searchcraft-filters-list&encapsulation=shadow","src/components/searchcraft-filters-list/searchcraft-filters-list.tsx","src/components/searchcraft-input/searchcraft-input.module.scss?tag=searchcraft-input&encapsulation=shadow","src/components/searchcraft-input/searchcraft-input.tsx","src/components/searchcraft-input-caption/searchcraft-input-caption.module.scss?tag=searchcraft-input-caption&encapsulation=shadow","src/components/searchcraft-input-caption/searchcraft-input-caption.tsx","src/components/searchcraft-input-icon/searchcraft-input-icon.module.scss?tag=searchcraft-input-icon&encapsulation=shadow","src/components/searchcraft-input-icon/searchcraft-input-icon.tsx","src/components/searchcraft-input-label/searchcraft-input-label.module.scss?tag=searchcraft-input-label&encapsulation=shadow","src/components/searchcraft-input-label/searchcraft-input-label.tsx","src/components/searchcraft-results-info/searchcraft-results-info.module.scss?tag=searchcraft-results-info&encapsulation=shadow","src/components/searchcraft-results-info/searchcraft-results-info.tsx","src/assets/searchcraft-search-icon-set.tsx","src/components/searchcraft-slider/searchcraft-slider.module.scss?tag=searchcraft-slider&encapsulation=shadow","src/components/searchcraft-slider/searchcraft-slider.tsx","src/components/searchcraft-spinner-dark/searchcraft-spinner-dark.module.scss?tag=searchcraft-spinner-dark&encapsulation=shadow","src/components/searchcraft-spinner-dark/searchcraft-spinner-dark.tsx","src/components/searchcraft-spinner-light/searchcraft-spinner-light.module.scss?tag=searchcraft-spinner-light&encapsulation=shadow","src/components/searchcraft-spinner-light/searchcraft-spinner-light.tsx","src/components/searchcraft-toggle-button/searchcraft-toggle-button.module.scss?tag=searchcraft-toggle-button&encapsulation=shadow","src/components/searchcraft-toggle-button/searchcraft-toggle-button.tsx"],"sourcesContent":[":root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n.formLTR {\n font-family: var(--font-stack);\n text-align: left;\n width: 100%;\n}\n\n.formRTL {\n font-family: var(--font-stack);\n text-align: right;\n width: 100%;\n}","import {\n Component,\n Prop,\n State,\n Event,\n type EventEmitter,\n h,\n} from '@stencil/core';\n\nimport {\n type CoreConfigSDK,\n CoreSDK as SearchcraftCore,\n type SearchcraftResponse,\n} from '@searchcraft/core';\n\nimport { useSearchcraftStore } from '@provider/store';\n\nimport { parseCustomStyles } from '@utils/utils';\n\nimport type { ScInputCustomEvent } from '@components/searchcraft-input/searchcraft-input';\n\n@Component({\n tag: 'searchcraft-auto-search-form',\n styleUrl: 'searchcraft-auto-search-form.module.scss',\n shadow: true,\n})\nexport class SearchcraftAutoSearchForm {\n @Prop() autoSearchFormClass = '';\n @Prop() clearInput: () => void = () => {};\n @Prop() config: CoreConfigSDK = {\n apiKey: '',\n endpointURL: '',\n index: [],\n };\n @Prop() customStylesForInput: string | Record<string, string> = {};\n @Prop() inputCaptionValue = '';\n @Prop() inputIconHeight = 20;\n @Prop() inputIconWidth = 20;\n @Prop() labelForInput = '';\n @Prop() placeholderValue = 'Search here';\n @Prop() rightToLeftOrientation = false;\n @Prop() searchContainerClass = '';\n\n @Event() inputClearedOrNoResults: EventEmitter<void>;\n @Event() querySubmit: EventEmitter<string>;\n\n @State() error = false;\n @State() isRequesting = false;\n @State() query = '';\n @State() searchResults: SearchcraftResponse | null = null;\n\n private debounceTimeout: ReturnType<typeof setTimeout> | null = null;\n private debounceDelay = 0;\n private searchStore = useSearchcraftStore.getState();\n unsubscribe: () => void;\n\n componentDidLoad() {\n const searchcraft = new SearchcraftCore(this.config);\n this.searchStore.initialize(searchcraft, true);\n\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.isRequesting = state.isRequesting;\n this.searchResults = { ...state.searchResults };\n });\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n handleInputChange = (event: ScInputCustomEvent<string>) => {\n this.query = event.detail;\n this.searchStore.setQuery(this.query);\n this.querySubmit.emit(this.query);\n };\n\n handleInputKeyUp = (event: ScInputCustomEvent<string>) => {\n const target = event.detail;\n this.query = target;\n this.searchStore.setQuery(this.query);\n this.querySubmit.emit(this.query);\n\n if (this.debounceTimeout) {\n clearTimeout(this.debounceTimeout);\n }\n\n this.debounceTimeout = setTimeout(() => {\n this.query.trim() !== '' && this.runSearch();\n }, this.debounceDelay);\n };\n\n handleClearInput = () => {\n this.query = '';\n this.searchStore.setQuery('');\n\n if (typeof this.clearInput === 'function') {\n this.clearInput();\n }\n\n if (this.debounceTimeout) {\n clearTimeout(this.debounceTimeout);\n }\n\n this.error = false;\n this.inputClearedOrNoResults.emit();\n };\n\n private runSearch = async () => {\n if (this.query.trim() === '') {\n this.error = true;\n this.inputClearedOrNoResults.emit();\n } else {\n this.error = false;\n this.searchStore.setQuery(this.query);\n\n try {\n await this.searchStore.search();\n } catch (error) {\n this.error = true;\n this.inputClearedOrNoResults.emit();\n }\n }\n };\n\n handleFormSubmit = async (event: Event) => {\n event.preventDefault();\n await this.runSearch();\n };\n\n render() {\n const formClass = this.rightToLeftOrientation ? 'formRTL' : 'formLTR';\n const parsedCustomStyles = parseCustomStyles(this.customStylesForInput);\n if (this.query.length > 0 && this.searchResults?.data?.hits?.length === 0) {\n this.inputClearedOrNoResults.emit();\n }\n\n return (\n <form class={`${formClass}`} onSubmit={this.handleFormSubmit}>\n <searchcraft-input-label label={this.labelForInput} />\n <searchcraft-input\n customStyles={parsedCustomStyles}\n input-caption-value={this.inputCaptionValue}\n input-icon-height={this.inputIconHeight}\n input-icon-width={this.inputIconWidth}\n is-requesting={this.isRequesting}\n onClearInput={this.handleClearInput}\n onInputKeyUp={this.handleInputKeyUp}\n onSearchInputChange={this.handleInputChange}\n placeholder-value={this.placeholderValue}\n query={this.query}\n right-to-left-orientation={this.rightToLeftOrientation}\n />\n {this.error && (\n <searchcraft-error-message errorMessage='Please enter a search query.' />\n )}\n </form>\n );\n }\n}\n","@import '../../utils/theme';\n\n:root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n@mixin interactive-result-container-base {\n align-items: flex-start;\n border-radius: 16px;\n display: flex;\n flex-direction: column;\n gap: 16px;\n padding: 8px;\n position: relative;\n\n @media (min-width: 600px) {\n flex-direction: row;\n }\n}\n\n.interactiveResultContainerLight {\n @include interactive-result-container-base;\n background-color: $light-search-result-container-background;\n}\n\n.interactiveResultContainerDark {\n @include interactive-result-container-base;\n background-color: $dark-search-result-container-background;\n}\n\n.resultContainer {\n align-items: flex-start;\n display: flex;\n flex-direction: column;\n gap: 16px;\n\n @media (min-width: 600px) {\n flex-direction: row;\n }\n}\n\n.interactiveIconLarge {\n display: inline-block;\n position: absolute;\n right: 5px;\n top: 8px;\n\n\n @media (max-width: 600px) {\n display: none;\n }\n}\n\n.interactiveIconSmall {\n display: inline-block;\n position: absolute;\n right: 5px;\n top: -2px;\n\n\n @media (min-width: 600px) {\n display: none;\n }\n}\n\n.imageContainer {\n max-width: 100%;\n}\n\n.contentContainer {\n max-height: 100%;\n max-width: 100%;\n\n @media (min-width: 600px) {\n max-width: 50%;\n }\n}\n\n.secondaryContentContainer {\n display: flex;\n\n}\n\n@mixin image-base {\n border-radius: 8px;\n max-height: 100%;\n max-width: 100%;\n}\n\n.imageLight {\n @include image-base;\n border: 1px solid $light-search-result-image-border;\n}\n\n.imageDark {\n @include image-base;\n border: 1px solid $dark-search-result-image-border;\n}\n\n@mixin heading-base {\n font-family: var(--font-stack);\n font-size: 16px;\n font-weight: 700;\n line-height: 20px;\n margin-bottom: 4px;\n margin-top: 0;\n position: relative;\n -webkit-font-smoothing: antialiased;\n}\n\n.headingLight {\n @include heading-base;\n color: $light-search-result-heading-color;\n}\n\n.headingDark {\n @include heading-base;\n color: $dark-search-result-heading-color;\n}\n\n@mixin subheading-base {\n font-family: var(--font-stack);\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin-bottom: 4px;\n margin-top: 0px;\n -webkit-font-smoothing: antialiased;\n}\n\n.subheadingLight {\n @include subheading-base;\n color: $light-search-result-subheading-color;\n}\n\n.subheadingDark {\n @include subheading-base;\n color: $dark-search-result-subheading-color\n}\n\n@mixin body-content-base {\n font-family: var(--font-stack);\n font-size: 16px;\n font-weight: 400;\n line-height: 20px;\n margin-bottom: 4px;\n margin-top: 0px;\n -webkit-font-smoothing: antialiased;\n}\n\n.primaryContentLight {\n @include body-content-base;\n color: $light-search-result-body-content-color;\n}\n\n.primaryContentDark {\n @include body-content-base;\n color: $dark-search-result-body-content-color;\n}\n\n.secondaryContentLight {\n @include body-content-base;\n color: $light-search-result-body-content-color;\n}\n\n.secondaryContentLight::after {\n content: \"•\";\n color: $light-search-result-body-content-color;\n font-size: 1em;\n margin-left: 5px;\n margin-right: 5px;\n}\n\n.secondaryContentDark {\n @include body-content-base;\n color: $dark-search-result-body-content-color;\n}\n\n.tertiaryContentLight {\n @include body-content-base;\n color: $light-search-result-body-content-color;\n}\n\n.tertiaryContentDark {\n @include body-content-base;\n color: $dark-search-result-body-content-color;\n}","import { Component, Event, Fragment, h, Prop } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-base-search-result',\n styleUrl: 'searchcraft-base-search-result.module.scss',\n shadow: true,\n})\nexport class SearchcraftBaseSearchResult {\n @Prop() buttonText = ''; // Label for the button\n @Prop() customStyles = '{}'; // New string prop for serialized styles.\n @Prop() headingText = ''; // Text for the heading\n @Prop() imageDescription = ''; // Alternative text for the image\n @Prop() imageSource = ''; // Source URL for the image\n @Prop() isInteractive = false; // Determines if the result is interactive\n @Prop() primaryContent = ''; // Primary body content\n @Prop() secondaryContent = ''; // Secondary body content\n @Prop() subheadingText = ''; // Text for the subheading\n @Prop() tertiaryContent = ''; // Tertiary body content\n @Prop() themeMode: 'light' | 'dark' = 'light'; // Light or dark theme context\n @Prop() placeImageRight = false; // Determines the placement of the image container\n\n @Event() buttonCallback: () => void = () => {}; // Callback for button click\n @Event() keyDownCallback: () => void = () => {}; // Callback for key down event\n @Event() resultCallback: () => void = () => {}; // Callback for result container click\n\n private handleButtonClick = () => {\n this.buttonCallback();\n };\n\n private handleContainerClick = () => {\n if (this.isInteractive) {\n this.resultCallback();\n }\n };\n\n private parseStyles(): Record<string, { [key: string]: string }> {\n try {\n return JSON.parse(this.customStyles);\n } catch (error) {\n console.error('Error parsing custom styles:', error);\n return {};\n }\n }\n\n render() {\n const isLightTheme = this.themeMode === 'light';\n const styles = this.parseStyles();\n\n const imageContainer = this.imageSource && (\n <div class='imageContainer'>\n <img\n alt={this.imageDescription}\n class={isLightTheme ? 'imageLight' : 'imageDark'}\n src={this.imageSource}\n style={styles.image || {}}\n />\n </div>\n );\n\n const contentContainer = (\n <div class='contentContainer'>\n <h2\n class={isLightTheme ? 'headingLight' : 'headingDark'}\n style={styles.heading || {}}\n >\n {this.headingText}\n </h2>\n <h3\n class={isLightTheme ? 'subheadingLight' : 'subheadingDark'}\n style={styles.subheading || {}}\n >\n {this.subheadingText}\n </h3>\n <p\n class={isLightTheme ? 'primaryContentLight' : 'primaryContentDark'}\n style={styles.primaryContent || {}}\n >\n {this.primaryContent}\n </p>\n <div class='secondaryContentContainer'>\n <p\n class={\n isLightTheme ? 'secondaryContentLight' : 'secondaryContentDark'\n }\n style={styles.secondaryContent || {}}\n >\n {this.secondaryContent}\n </p>\n <p\n class={\n isLightTheme ? 'tertiaryContentLight' : 'tertiaryContentDark'\n }\n style={styles.tertiaryContent || {}}\n >\n {this.tertiaryContent}\n </p>\n </div>\n {this.buttonText && (\n <button\n onClick={this.handleButtonClick}\n style={styles.button || {}}\n type='button'\n >\n {this.buttonText}\n </button>\n )}\n </div>\n );\n\n return (\n <div\n class={\n this.isInteractive\n ? isLightTheme\n ? 'interactiveResultContainerLight'\n : 'interactiveResultContainerDark'\n : 'resultContainer'\n }\n onKeyDown={this.keyDownCallback}\n onClick={this.handleContainerClick}\n style={styles.container || {}}\n tabindex='0'\n >\n {this.placeImageRight ? (\n <Fragment>\n {contentContainer}\n {imageContainer}\n </Fragment>\n ) : (\n <Fragment>\n {imageContainer}\n {contentContainer}\n </Fragment>\n )}\n </div>\n );\n }\n}\n",":root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n.resultsContainer {\n display: flex;\n flex-direction: column;\n justify-content: center;\n margin: 16px 0;\n\n & > p {\n align-self: center;\n }\n\n & > div {\n margin-bottom: 20px;\n img {\n height: 300px;\n width: 200px;\n }\n }\n}\n\n.adSection {\n align-items: center;\n background-color: #F1F1F1;\n border: 1px solid #DCDDDE;\n border-radius: 16px;\n display: flex;\n flex-direction: column;\n font-size: 16px;\n justify-content: center;\n margin: auto;\n min-height: 150px;\n text-align: center;\n width: 100%;\n\n p {\n margin-top: 5px;\n }\n}\n\n.emptyState {\n text-align: center;\n width: 100%;\n}\n\n.errorMessageContainer {\n text-align: center;\n}\n","import { Component, h, Prop, State } from '@stencil/core';\n\nimport type { SearchcraftResponse } from '@searchcraft/core';\n\nimport { useSearchcraftStore } from '@provider/store';\n\nimport {\n extractDynamicProperties,\n getFormattedTimeFromNow,\n parseSearchKeys,\n serializeStyles,\n} from '@utils/utils';\n\n@Component({\n tag: 'searchcraft-base-search-results',\n styleUrl: 'searchcraft-base-search-results.module.scss',\n shadow: true,\n})\nexport class SearchcraftBaseSearchResults {\n @Prop() adInterval = 4;\n @Prop() customStylesForResults:\n | string\n | Record<string, Record<string, string>> = {};\n @Prop() documentAttributesForDisplay = '';\n @Prop() fallbackElement: HTMLElement | null = null;\n @Prop() formatTime = true;\n @Prop() placeAdAtEnd = false;\n @Prop() placeAdAtStart = true;\n @Prop() placeResultImageRight = false;\n\n @State() hasSearched = false;\n @State() query = '';\n @State() searchResults: SearchcraftResponse | null = null;\n\n private unsubscribe: () => void;\n\n componentDidLoad() {\n if (\n !this.documentAttributesForDisplay ||\n this.documentAttributesForDisplay.length === 0\n ) {\n console.warn('No document attributes provided; using empty keys array.');\n this.documentAttributesForDisplay = '';\n }\n\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query.length > 0) {\n this.hasSearched = true;\n } else {\n this.hasSearched = false;\n }\n this.searchResults = { ...state.searchResults };\n this.query = state.query;\n });\n\n const { searchResults, query } = useSearchcraftStore.getState();\n this.searchResults = searchResults;\n this.query = query;\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n render() {\n if (!this.hasSearched) {\n return (\n <div class='emptyState'>\n <slot name='empty-search' />\n </div>\n );\n }\n\n if (!this.searchResults?.data) {\n console.warn('No search results data available');\n return <div class='emptyState'>No results to display.</div>;\n }\n\n const parsedSearchKeys = parseSearchKeys(this.documentAttributesForDisplay);\n const serializedStyles =\n typeof this.customStylesForResults === 'string'\n ? this.customStylesForResults\n : serializeStyles(this.customStylesForResults);\n\n const resultsComponents = this.searchResults?.data?.hits?.map(\n (document, index) => {\n const { doc: result } = document;\n const dynamicProperties = extractDynamicProperties(\n result,\n parsedSearchKeys,\n );\n\n if (this.formatTime) {\n for (const key of parsedSearchKeys) {\n if (dynamicProperties[key]) {\n const value = dynamicProperties[key];\n // Check if the value is a valid ISO timestamp\n if (\n typeof value === 'string' &&\n !Number.isNaN(Date.parse(value))\n ) {\n dynamicProperties[key] = getFormattedTimeFromNow(value);\n }\n }\n }\n }\n\n return (\n <searchcraft-base-search-result\n button-callback={() => console.log('button callback')}\n custom-styles={serializedStyles}\n image-source={\n dynamicProperties[parsedSearchKeys[parsedSearchKeys.length - 1]]\n }\n is-interactive={true}\n key={`${document.document_id}-${index}`}\n keydown-callback={() => console.log('keydown')}\n heading-text={dynamicProperties[parsedSearchKeys[0]]}\n place-image-right={this.placeResultImageRight}\n primary-content={dynamicProperties[parsedSearchKeys[2]]}\n result-callback={() => console.log('interactive element')}\n secondary-content={dynamicProperties[parsedSearchKeys[3]]}\n subheading-text={dynamicProperties[parsedSearchKeys[1]]}\n tertiary-content={dynamicProperties[parsedSearchKeys[4]]}\n />\n );\n },\n );\n\n const finalComponents: JSX.Element[] = [];\n\n if (this.placeAdAtStart) {\n finalComponents.push(\n <div key='ad-section-start' class='adSection'>\n <span>##</span>\n <p> Ad Impressions</p>\n </div>,\n );\n }\n\n if (this.adInterval > 0) {\n resultsComponents.forEach((component, index) => {\n finalComponents.push(component);\n if ((index + 1) % this.adInterval === 0) {\n finalComponents.push(\n <div key={`ad-section-${index + 1}`} class='adSection'>\n <span>##</span>\n <p> Ad Impressions</p>\n </div>,\n );\n }\n });\n } else {\n finalComponents.push(...resultsComponents);\n }\n\n if (this.placeAdAtEnd) {\n finalComponents.push(\n <div key='ad-section-end' class='adSection'>\n <span>##</span>\n <p> Ad Impressions</p>\n </div>,\n );\n }\n\n return (\n <div class='resultsContainer'>\n {finalComponents}\n {this.query.length > 0 &&\n this.searchResults?.data?.hits?.length === 0 && (\n <div class='errorMessageContainer'>\n <searchcraft-error-message\n error-message={`No search results found for \"${this.query}\" query`}\n />\n </div>\n )}\n </div>\n );\n }\n}\n","import { Component, h } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-check-icon',\n shadow: true,\n})\nexport class SearchcraftCheckIcon {\n render() {\n return (\n <svg width='16' height='16' viewBox='0 0 16 16' fill='none'>\n <title>Checkbox Check</title>\n <path\n d='M13.9999 2L5.74988 10L1.99988 6.36364'\n stroke='white'\n stroke-width='3'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n }\n}\n","import { Component, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-clear-icon-set',\n shadow: true,\n})\nexport class SearchcraftClearIconSet {\n /**\n * Type of the icon to display.\n * Options: 'clear-light', 'clear-dark', 'arrow-light', 'arrow-dark'\n */\n @Prop() type: 'clear-light' | 'clear-dark' | 'arrow-light' | 'arrow-dark' =\n 'clear-light';\n\n render() {\n switch (this.type) {\n case 'clear-light':\n return (\n <svg\n width='22'\n height='22'\n viewBox='0 0 22 22'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='icon-title'\n >\n <title id='icon-title'>Searchcraft Clear Input Icon Light</title>\n <path\n d='M14 8L8 14M8 8L14 14M21 11C21 16.5228 16.5228 21 11 21C5.47715 21 1 16.5228 1 11C1 5.47715 5.47715 1 11 1C16.5228 1 21 5.47715 21 11Z'\n stroke='black'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'clear-dark':\n return (\n <svg\n width='22'\n height='22'\n viewBox='0 0 22 22'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='icon-title'\n >\n <title id='icon-title'>Searchcraft Clear Input Icon Dark</title>\n <path\n d='M14 8L8 14M8 8L14 14M21 11C21 16.5228 16.5228 21 11 21C5.47715 21 1 16.5228 1 11C1 5.47715 5.47715 1 11 1C16.5228 1 21 5.47715 21 11Z'\n stroke='white'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'arrow-light':\n return (\n <svg\n width='20'\n height='21'\n viewBox='0 0 20 21'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='icon-title'\n >\n <title id='icon-title'>Searchcraft Arrow Right Icon Light</title>\n <path\n d='M7.5 15.0444L12.5 10.0444L7.5 5.04443'\n stroke='#737373'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'arrow-dark':\n return (\n <svg\n width='8'\n height='12'\n viewBox='0 0 8 12'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='icon-title'\n >\n <title id='icon-title'>Searchcraft Arrow Right Icon Dark</title>\n <path\n d='M1.5 11L6.5 6L1.5 1'\n stroke='#BFBFBF'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n\n default:\n return null;\n }\n }\n}\n",":root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n.inputClearButtonLTR {\n align-items: center;\n background: none;\n border: none;\n display: flex;\n height: 20px;\n justify-content: center;\n padding: 0;\n position: absolute;\n right: 0;\n top: 50%;\n transform: translateY(-50%);\n width: 20px;\n}\n\n.inputClearButtonRTL {\n align-items: center;\n background: none;\n border: none;\n display: flex;\n height: 20px;\n justify-content: center;\n left: 0px;\n padding: 0;\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n width: 20px;\n}","import {\n Component,\n Event,\n type EventEmitter,\n Prop,\n h,\n State,\n} from '@stencil/core';\nimport classNames from 'classnames';\n\n@Component({\n tag: 'searchcraft-clear-input-button',\n styleUrl: 'searchcraft-clear-input-button.module.scss',\n shadow: true,\n})\nexport class SearchcraftClearInputButton {\n @Prop() isRequesting? = false;\n @Prop() rightToLeftOrientation = false;\n\n @Event() clearInput: EventEmitter<void>;\n\n @State() theme = 'light';\n\n private isLightTheme() {\n return this.theme === 'light';\n }\n\n private handleClearClick = (event: MouseEvent) => {\n event.preventDefault();\n this.clearInput.emit();\n };\n\n render() {\n return this.rightToLeftOrientation ? (\n <button\n class={classNames('inputClearButtonRTL', '.sc-clear-input-button-rtl')}\n onClick={this.handleClearClick}\n type='button'\n >\n {this.isRequesting ? (\n this.isLightTheme ? (\n <searchcraft-spinner-light />\n ) : (\n <searchcraft-spinner-dark />\n )\n ) : this.isLightTheme ? (\n <searchcraft-clear-icon-set type='clear-light' />\n ) : (\n <searchcraft-clear-icon-set type='clear-dark' />\n )}\n </button>\n ) : (\n <button\n class={classNames('inputClearButtonLTR', '.sc-clear-input-button-ltr')}\n onClick={this.handleClearClick}\n type='button'\n >\n {this.isRequesting ? (\n this.isLightTheme ? (\n <searchcraft-spinner-light />\n ) : (\n <searchcraft-spinner-dark />\n )\n ) : this.isLightTheme ? (\n <searchcraft-clear-icon-set type='clear-light' />\n ) : (\n <searchcraft-clear-icon-set type='clear-dark' />\n )}\n </button>\n );\n }\n}\n","@import '../../utils/theme';\n\n:root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n@mixin error-message-base {\n font-family: var(--font-stack);\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin-top: 4px;\n}\n\n.errorMessageLight {\n @include error-message-base;\n color: $light-input-caption-color-error;\n}\n\n.errorMessageDark {\n @include error-message-base;\n color: $dark-input-caption-color-error;\n}","import { Component, Prop, h } from '@stencil/core';\nimport classNames from 'classnames';\n\n@Component({\n tag: 'searchcraft-error-message',\n styleUrl: 'searchcraft-error-message.module.scss',\n shadow: true,\n})\nexport class SearchcraftErrorMessage {\n /**\n * The error message to display. Defaults to a standard message if not provided.\n */\n @Prop() errorMessage?: string;\n\n /**\n * The theme, which determines the style (light or dark).\n */\n @Prop() theme: 'light' | 'dark' = 'light';\n\n render() {\n const errorMessageStyle =\n this.theme === 'light' ? 'errorMessageLight' : 'errorMessageDark';\n\n return (\n <p class={classNames(errorMessageStyle)}>\n {this.errorMessage || 'Search term is required.'}\n </p>\n );\n }\n}\n",".filtersList {\n width: 100%;\n}\n\n.checkboxLabel {\n align-items: center;\n color: #292929;\n display: flex;\n font-family: 'Source Sans Pro';\n font-size: 14px;\n font-weight: 600;\n gap: 14px;\n position: relative;\n -webkit-font-smoothing: antialiased;\n}\n\n.checkboxLabel input[type=\"checkbox\"] {\n align-items: center;\n appearance: none;\n background-color: #EDEDED;\n border: 1px solid #D9D9D9;\n cursor: pointer;\n display: flex;\n height: 24px;\n justify-content: center;\n width: 24px;\n}\n\n.checkboxLabel input[type=\"checkbox\"]:checked {\n background-color: #000;\n position: relative;\n}\n\n.checkboxLabel input[type=\"checkbox\"]:checked + .checkContainer {\n display: block;\n}\n\n.remainingFilterListCheckbox {\n margin-left: 16px;\n}\n\n.childCheckboxLabel {\n align-items: center;\n color: #292929;\n display: flex;\n font-family: 'Source Sans Pro';\n font-size: 14px;\n font-weight: 600;\n gap: 12px;\n position: relative;\n}\n\n.childCheckboxLabel input[type=\"checkbox\"] {\n align-items: center;\n appearance: none;\n background-color: #EDEDED;\n border: 1px solid #D9D9D9;\n cursor: pointer;\n display: flex;\n height: 24px;\n justify-content: center;\n position: relative;\n width: 24px;\n -webkit-font-smoothing: antialiased;\n}\n\n.childCheckboxLabel input[type=\"checkbox\"]:checked {\n background-color: #000;\n position: relative;\n}\n\n.childCheckboxLabel input[type=\"checkbox\"]:checked + .checkContainer {\n display: block;\n}\n\n.checkContainer {\n display: none;\n height: 16px;\n width: 16px;\n position: absolute;\n top: 10px;\n left: 7px;\n}","import {\n Component,\n h,\n State,\n Prop,\n Event,\n type EventEmitter,\n} from '@stencil/core';\n\nimport type { Facets } from '@searchcraft/core';\n\nimport { useSearchcraftStore } from '@provider/store';\n\nimport { flattenFacets } from '@utils/utils';\n\n@Component({\n tag: 'searchcraft-filters-list',\n styleUrl: 'searchcraft-filters-list.module.scss',\n shadow: true,\n})\nexport class SearchcraftFiltersList {\n @Prop() filters: Array<{ label: string; value: string }> = [];\n\n @Event() filtersUpdated: EventEmitter<string[]>;\n\n @State() dynamicFilters: Array<{ label: string; value: string }> = [];\n @State() isRequesting = false;\n @State() query = '';\n @State() resultsCount = 0;\n @State() selectedFilters: Set<string> = new Set();\n\n private searchStore = useSearchcraftStore.getState();\n unsubscribe: () => void;\n\n connectedCallback() {\n const state = this.searchStore;\n\n if (state.searchResults?.data.facets) {\n this.populateFiltersFromFacets(state.searchResults.data.facets);\n }\n\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (!state.query || state.query.trim().length === 0) {\n if (this.selectedFilters.size > 0) {\n this.selectedFilters.clear();\n this.filtersUpdated.emit([]);\n if (this.searchStore.selectedFilters.length > 0) {\n this.searchStore.setSelectedFilters([]);\n }\n }\n }\n this.query = state.query || '';\n this.isRequesting = state.isRequesting;\n this.resultsCount = state.searchResults?.data?.hits?.length || 0;\n\n if (state.searchResults?.data.facets) {\n this.populateFiltersFromFacets(state.searchResults.data.facets);\n }\n });\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n populateFiltersFromFacets(facets: Facets) {\n const newFilters = flattenFacets(facets[0]?.section || []);\n const filtersMap = new Map<string, { label: string; value: string }>();\n\n this.dynamicFilters.forEach((filter) => {\n const key = filter.value.split('/').pop() || '';\n filtersMap.set(key, filter);\n });\n\n newFilters.forEach((filter) => {\n const key = filter.value.split('/').pop() || '';\n const existingFilter = filtersMap.get(key);\n\n if (\n !existingFilter ||\n filter.value.length < existingFilter.value.length\n ) {\n filtersMap.set(key, filter);\n }\n });\n\n this.dynamicFilters = Array.from(filtersMap.values());\n }\n\n handleFilterChange = (value: string, checked: boolean) => {\n if (checked) {\n this.selectedFilters.add(value);\n } else {\n this.selectedFilters.delete(value);\n }\n const deduplicatedFilters = this.deduplicatePaths(\n Array.from(this.selectedFilters),\n );\n\n this.filtersUpdated.emit(deduplicatedFilters);\n this.searchStore.setSelectedFilters(deduplicatedFilters);\n this.searchStore.search();\n };\n\n deduplicatePaths(filters: string[]): string[] {\n const pathMap = new Map<string, string>();\n\n filters.forEach((path) => {\n const key = path.split('/').pop() || '';\n const existingPath = pathMap.get(key);\n\n if (!existingPath || path.length < existingPath.length) {\n pathMap.set(key, path);\n }\n });\n\n return Array.from(pathMap.values());\n }\n\n formatLabel(label: string): string {\n return label\n .replace(/-/g, ' ')\n .split(' ')\n .map((word) => word.charAt(0).toUpperCase() + word.slice(1))\n .join(' ');\n }\n\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n\n const filtersToRender = this.dynamicFilters.filter(\n (filter) => !filter.value.includes('/', filter.value.indexOf('/') + 1),\n );\n\n return (\n <div class='filtersList'>\n {filtersToRender.map((filter) => {\n const isChecked = this.selectedFilters.has(filter.value);\n const children = this.dynamicFilters.filter(\n (child) =>\n child.value.startsWith(`${filter.value}/`) &&\n child.value !== filter.value,\n );\n\n return (\n <div key={filter.value}>\n <label class='checkboxLabel'>\n <input\n class='filterCheckbox'\n checked={isChecked}\n onChange={(event: Event) =>\n this.handleFilterChange(\n filter.value,\n (event.target as HTMLInputElement).checked,\n )\n }\n type='checkbox'\n />\n <div class='checkContainer'>\n <searchcraft-check-icon />\n </div>\n {this.formatLabel(filter.label)}\n </label>\n {children.map((child) => {\n const isChildChecked = this.selectedFilters.has(child.value);\n return (\n <label\n class='childCheckboxLabel'\n key={child.value}\n style={{ marginLeft: '20px' }}\n >\n <input\n class='childFilterCheckbox'\n checked={isChildChecked}\n onChange={(event: Event) =>\n this.handleFilterChange(\n child.value,\n (event.target as HTMLInputElement).checked,\n )\n }\n type='checkbox'\n />\n <div class='checkContainer'>\n <searchcraft-check-icon />\n </div>\n {this.formatLabel(child.label.split('/').pop() || '')}\n </label>\n );\n })}\n </div>\n );\n })}\n </div>\n );\n }\n}\n","@import '../../utils/theme';\n\n:root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n@mixin input-container-base {\n position: relative;\n width: 100%;\n}\n\n@mixin input-base {\n border: none;\n border-radius: 8px;\n font-family: var(--font-stack);\n outline: none;\n padding-bottom: 15px;\n padding-top: 15px;\n width: 100%;\n\n &::placeholder {\n font-family: var(--font-stack);\n font-size: 16px;\n }\n}\n\n@mixin input-base-light {\n @include input-base;\n background-color: $light-input-background-color;\n color: $light-input-label-color;\n\n &::placeholder {\n color: $light-input-placeholder-color;\n }\n\n &:focus {\n outline: 2px solid $light-input-outline-focus;\n }\n}\n\n@mixin input-base-dark {\n @include input-base;\n background-color: $dark-input-background-color;\n color: $dark-input-label-color;\n\n &::placeholder {\n color: $dark-input-placeholder-color;\n }\n\n &:focus {\n outline: 2px solid $dark-input-outline-focus;\n }\n}\n\n@mixin input-error-base-light {\n @include input-base-light;\n outline: 2px solid $light-input-error-outline;\n\n &:focus-visible {\n outline: 2px solid $light-input-error-outline,\n }\n}\n\n@mixin input-error-base-dark {\n @include input-base-dark;\n outline: 2px solid $dark-input-error-outline;\n\n &:focus-visible {\n outline: 2px solid $dark-input-error-outline;\n }\n}\n\n.inputContainerLTR {\n @include input-container-base;\n}\n\n.inputContainerRTL {\n @include input-container-base;\n margin-left: 8px;\n}\n\n@mixin align-LTR {\n margin-right: 8px;\n padding-left: 36px;\n padding-right: 16px;\n}\n\n.inputLightLTR {\n @include input-base-light;\n @include align-LTR;\n}\n\n.inputDarkLTR {\n @include input-base-dark;\n @include align-LTR;\n}\n\n.inputErrorLightLTR {\n @include input-error-base-light;\n @include align-LTR;\n}\n\n.inputErrorDarkLTR {\n @include input-error-base-dark;\n @include align-LTR;\n}\n\n@mixin align-RTL {\n margin-left: 8px;\n padding-left: 16px;\n padding-right: 36px;\n text-align: right;\n}\n\n.inputLightRTL {\n @include input-base-light;\n @include align-RTL;\n}\n\n.inputDarkRTL {\n @include input-base-dark;\n @include align-RTL;\n}\n\n.inputErrorLightRTL {\n @include input-error-base-light;\n @include align-RTL;\n}\n\n.inputErrorDarkRTL {\n @include input-error-base-dark;\n @include align-RTL;\n}\n\n.inputWrapper {\n align-items: center;\n display: flex;\n position: relative;\n width: 100%;\n}\n","import {\n Component,\n h,\n Prop,\n State,\n Event,\n Fragment,\n type EventEmitter,\n} from '@stencil/core';\nimport classNames from 'classnames';\n\nimport { parseCustomStyles } from '@utils/utils';\n\nexport interface ScInputCustomEvent<T> extends CustomEvent<T> {\n detail: T;\n target: HTMLSearchcraftInputElement;\n}\n\n@Component({\n tag: 'searchcraft-input',\n styleUrl: 'searchcraft-input.module.scss',\n shadow: true,\n})\nexport class SearchcraftInput {\n @Prop() customStyles: string | Record<string, string> = {};\n @Prop() error = false;\n @Prop() formClassName = '';\n @Prop() inputCaptionClassName = '';\n @Prop() inputCaptionValue = '';\n @Prop() inputClassName = '';\n @Prop() inputIconHeight = 20;\n @Prop() inputIconWidth = 20;\n @Prop() isRequesting = false;\n @Prop() placeholderValue = 'Enter Search';\n @Prop() rightToLeftOrientation = false;\n @Prop() query = '';\n\n @Event() clearInput: EventEmitter<void>;\n @Event() searchInputChange: EventEmitter<string>;\n @Event() inputKeyUp: EventEmitter<string>;\n\n @State() theme = 'light';\n\n private get isLightTheme() {\n return this.theme === 'light';\n }\n\n handleInputChange(event: Event) {\n const input = event.target as HTMLInputElement;\n this.searchInputChange.emit(input.value);\n }\n\n handleInputKeyUp(event: KeyboardEvent) {\n const input = event.target as HTMLInputElement;\n this.inputKeyUp.emit(input.value);\n }\n\n handleClearInput() {\n if (this.clearInput) {\n this.clearInput.emit();\n }\n }\n\n render() {\n const containerClassName = this.rightToLeftOrientation\n ? 'inputContainerRTL'\n : 'inputContainerLTR';\n\n const inputClassName = classNames(\n this.error\n ? this.isLightTheme\n ? 'inputErrorLightRTL'\n : 'inputErrorDarkRTL'\n : this.isLightTheme\n ? 'inputLightLTR'\n : 'inputDarkLTR',\n 'searchcraft-input',\n );\n\n const validatedCustomStyles = parseCustomStyles(this.customStyles);\n\n const placeholderStyle = {\n fontSize: validatedCustomStyles.placeholderFontSize || '16px',\n };\n return (\n <div\n class={classNames(\n containerClassName,\n this.formClassName,\n 'searchcraft-input-form',\n )}\n >\n {this.rightToLeftOrientation ? (\n <Fragment>\n <input\n autoComplete='off'\n class={classNames(inputClassName, 'searchcraft-input')}\n id='searchcraft-input-id'\n onChange={this.handleInputChange.bind(this)}\n onKeyUp={this.handleInputKeyUp.bind(this)}\n placeholder={this.placeholderValue}\n type='text'\n value={this.query}\n style={validatedCustomStyles}\n />\n <style>\n {`\n #searchcraft-input-id::placeholder {\n font-size: ${placeholderStyle.fontSize};\n }\n `}\n </style>\n {this.inputCaptionValue && (\n <searchcraft-input-caption\n inputCaptionClassName={this.inputCaptionClassName}\n inputCaptionValue={this.inputCaptionValue}\n rightToLeftOrientation={this.rightToLeftOrientation}\n />\n )}\n {this.query.length > 0 && (\n <searchcraft-clear-input-button\n isRequesting={this.isRequesting}\n onClearInput={this.handleClearInput}\n rightToLeftOrientation={this.rightToLeftOrientation}\n />\n )}\n <searchcraft-input-icon\n error={this.error}\n height={this.inputIconHeight}\n rightToLeftOrientation={this.rightToLeftOrientation}\n width={this.inputIconWidth}\n />\n </Fragment>\n ) : (\n <Fragment>\n <searchcraft-input-icon\n error={this.error}\n height={this.inputIconHeight}\n rightToLeftOrientation={this.rightToLeftOrientation}\n width={this.inputIconWidth}\n />\n <input\n autoComplete='off'\n class={classNames(inputClassName, 'searchcraft-input')}\n id='searchcraft-input-id'\n onChange={this.handleInputChange.bind(this)}\n onKeyUp={this.handleInputKeyUp.bind(this)}\n placeholder={this.placeholderValue}\n type='text'\n value={this.query}\n style={validatedCustomStyles}\n />\n <style>\n {`\n #searchcraft-input-id::placeholder {\n font-size: ${placeholderStyle.fontSize};\n }\n `}\n </style>\n {this.inputCaptionValue && (\n <searchcraft-input-caption\n inputCaptionClassName={this.inputCaptionClassName}\n inputCaptionValue={this.inputCaptionValue}\n rightToLeftOrientation={this.rightToLeftOrientation}\n />\n )}\n {this.query.length > 0 && (\n <searchcraft-clear-input-button\n isRequesting={this.isRequesting}\n onClearInput={this.handleClearInput}\n rightToLeftOrientation={this.rightToLeftOrientation}\n />\n )}\n </Fragment>\n )}\n </div>\n );\n }\n}\n","@import '../../utils/theme';\n\n:root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n@mixin input-caption-base {\n font-family: var(--font-stack);\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin-top: 4px;\n}\n\n@mixin input-caption-base-light {\n @include input-caption-base;\n color: $light-input-caption-color;\n}\n\n@mixin input-caption-base-dark {\n @include input-caption-base;\n color: $dark-input-caption-color;\n}\n\n.inputCaptionLightLTR {\n @include input-caption-base-light;\n}\n\n.inputCaptionDarkLTR {\n @include input-caption-base-dark;\n}\n\n.inputCaptionErrorLightLTR {\n @include input-caption-base;\n color: $light-input-caption-color-error;\n}\n\n.inputCaptionErrorDarkLTR {\n @include input-caption-base;\n color: $dark-input-caption-color-error;\n}\n\n.inputCaptionLightRTL {\n @include input-caption-base-light;\n text-align: right;\n}\n\n.inputCaptionDarkRTL {\n @include input-caption-base-dark;\n text-align: right;\n}\n\n.inputCaptionErrorLightRTL {\n @include input-caption-base;\n color: $light-input-caption-color-error;\n text-align: right;\n}\n\n.inputCaptionErrorDarkRTL {\n @include input-caption-base;\n color: $dark-input-caption-color-error;\n text-align: right;\n}","import { Component, Prop, h, State } from '@stencil/core';\nimport classNames from 'classnames';\n\n@Component({\n tag: 'searchcraft-input-caption',\n styleUrl: 'searchcraft-input-caption.module.scss',\n shadow: true,\n})\nexport class SearchcraftInputCaption {\n @Prop() error?: boolean;\n @Prop() inputCaptionClassName? = '';\n @Prop() inputCaptionValue = 'Enter Search';\n @Prop() rightToLeftOrientation = false;\n @State() theme = 'light';\n\n private isLightTheme() {\n return this.theme === 'light';\n }\n\n render() {\n return this.rightToLeftOrientation ? (\n <p\n class={classNames(\n this.error\n ? this.isLightTheme\n ? 'inputCaptionErrorLightRTL'\n : 'inputCaptionErrorDarkRTL'\n : this.isLightTheme\n ? 'inputCaptionLightRTL'\n : 'inputCaptionDarkRTL',\n this.inputCaptionClassName,\n '.searchcraft-input-caption',\n )}\n >\n {this.inputCaptionValue}\n </p>\n ) : (\n <p\n class={classNames(\n this.error\n ? this.isLightTheme\n ? 'inputCaptionErrorLightLTR'\n : 'inputCaptionErrorDarkLTR'\n : this.isLightTheme\n ? 'inputCaptionLightLTR'\n : 'inputCaptionDarkLTR',\n this.inputCaptionClassName,\n '.searchcraft-input-caption',\n )}\n >\n {this.inputCaptionValue}\n </p>\n );\n }\n}\n",":root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n.inputIconLTR {\n left: 15px;\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n}\n\n.inputIconRTL {\n position: absolute;\n right: 15px;\n top: 50%;\n transform: translateY(-50%);\n}","import { Component, Prop, h, State } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-input-icon',\n styleUrl: 'searchcraft-input-icon.module.scss',\n shadow: true,\n})\nexport class SearchcraftInputIcon {\n @Prop() error?: boolean;\n @Prop() height = 20;\n @Prop() rightToLeftOrientation = false;\n @Prop() width = 20;\n\n @State() theme = 'light';\n\n private isLightTheme() {\n return this.theme === 'light';\n }\n\n render() {\n return this.error ? (\n <div\n class={this.rightToLeftOrientation ? 'inputIconRTL' : 'inputIconLTR'}\n >\n {this.isLightTheme() ? (\n <searchcraft-search-icon-set\n height={this.height}\n type='error-light'\n width={this.width}\n />\n ) : (\n <searchcraft-search-icon-set\n height={this.height}\n type='error-dark'\n width={this.width}\n />\n )}\n </div>\n ) : (\n <div\n class={this.rightToLeftOrientation ? 'inputIconRTL' : 'inputIconLTR'}\n >\n {this.isLightTheme() ? (\n <searchcraft-search-icon-set\n height={this.height}\n type='search-light'\n width={this.width}\n />\n ) : (\n <searchcraft-search-icon-set\n height={this.height}\n type='search-dark'\n width={this.width}\n />\n )}\n </div>\n );\n }\n}\n","@import '../../utils/theme';\n\n:root {\n --font-stack: Helvetica, Arial, sans-serif;\n}\n\n@mixin input-label-base {\n font-family: var(--font-stack);\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin-top: 4px;\n}\n\n.labelLight {\n @include input-label-base;\n color: $light-input-label-color;\n}\n\n.labelDark {\n @include input-label-base;\n color: $dark-input-label-color;\n}","import { Component, Prop, h, State } from '@stencil/core';\nimport classNames from 'classnames';\n\n@Component({\n tag: 'searchcraft-input-label',\n styleUrl: 'searchcraft-input-label.module.scss',\n shadow: true,\n})\nexport class SearchcraftInputLabel {\n @Prop() inputLabelClassName? = '';\n @Prop() label?: string;\n @State() theme = 'light';\n\n private isLightTheme() {\n return this.theme === 'light';\n }\n\n render() {\n if (!this.label) {\n return null;\n }\n const labelStyle = this.isLightTheme() ? 'labelLight' : 'labelDark';\n return (\n <label\n class={classNames(labelStyle, this.inputLabelClassName)}\n htmlFor='searchcraft-input-id'\n >\n {this.label}\n </label>\n );\n }\n}\n",".container {\n border-bottom: 1px solid #D9D9D9;\n display: flex;\n justify-content: flex-start;\n width: 100%;\n}\n\n.resultsInfo {\n color: #292929;\n font-size: 18px;\n font-weight: 600;\n line-height: 20px;\n margin: 0;\n margin-bottom: 8px;\n}","import { Component, h, State } from '@stencil/core';\nimport { useSearchcraftStore } from '@provider/store';\n\n@Component({\n tag: 'searchcraft-results-info',\n styleUrl: 'searchcraft-results-info.module.scss',\n shadow: true,\n})\nexport class SearchcraftResultsInfo {\n @State() isRequesting = false;\n @State() resultsCount = 0;\n @State() responseTime = '';\n @State() query = ''; // Track the query\n\n unsubscribe: () => void;\n\n connectedCallback() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.isRequesting = state.isRequesting;\n this.resultsCount = state.searchResults?.data?.count || 0;\n this.responseTime = (\n (state.searchResults?.data?.time_taken || 0) * 1000\n ).toFixed(2);\n this.query = state.query || ''; // Update query from store\n });\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n\n return (\n <div class='container'>\n <p class='resultsInfo'>\n {this.resultsCount} results found in {this.responseTime}ms\n </p>\n </div>\n );\n }\n}\n","import { Component, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-search-icon-set',\n shadow: true,\n})\nexport class SearchcraftSearchIconSet {\n /**\n * Type of the icon to display.\n * Options: 'search-light', 'search-dark', 'error-light', 'error-dark'\n */\n @Prop() type: 'search-light' | 'search-dark' | 'error-light' | 'error-dark' =\n 'search-dark';\n @Prop() width = 20;\n @Prop() height = 20;\n\n render() {\n const { width, height } = this;\n switch (this.type) {\n case 'search-light':\n return (\n <svg\n width={width}\n height={height}\n viewBox='0 0 20 20'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='searchcraft-title'\n >\n <title id='searchcraft-title'>Searchcraft Search Icon Light</title>\n <path\n d='M17.5 17.5L13.875 13.875M15.8333 9.16667C15.8333 12.8486 12.8486 15.8333 9.16667 15.8333C5.48477 15.8333 2.5 12.8486 2.5 9.16667C2.5 5.48477 5.48477 2.5 9.16667 2.5C12.8486 2.5 15.8333 5.48477 15.8333 9.16667Z'\n stroke='#404040'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'search-dark':\n return (\n <svg\n width={width}\n height={height}\n viewBox='0 0 18 18'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='searchcraft-title'\n >\n <title id='searchcraft-title'>Searchcraft Search Icon Dark</title>\n <path\n d='M16.5 16.5L12.875 12.875M14.8333 8.16667C14.8333 11.8486 11.8486 14.8333 8.16667 14.8333C4.48477 14.8333 1.5 11.8486 1.5 8.16667C1.5 4.48477 4.48477 1.5 8.16667 1.5C11.8486 1.5 14.8333 4.48477 14.8333 8.16667Z'\n stroke='#E6E6E6'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'error-light':\n return (\n <svg\n width={width}\n height={height}\n viewBox='0 0 20 20'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='searchcraft-title'\n >\n <title id='searchcraft-title'>\n Searchcraft Error Search Icon Light\n </title>\n <path\n d='M17.5 17.5L13.875 13.875M15.8333 9.16667C15.8333 12.8486 12.8486 15.8333 9.16667 15.8333C5.48477 15.8333 2.5 12.8486 2.5 9.16667C2.5 5.48477 5.48477 2.5 9.16667 2.5C12.8486 2.5 15.8333 5.48477 15.8333 9.16667Z'\n stroke='#737373'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n case 'error-dark':\n return (\n <svg\n width={width}\n height={height}\n viewBox='0 0 18 18'\n fill='none'\n xmlns='http://www.w3.org/2000/svg'\n aria-labelledby='searchcraft-title'\n >\n <title id='searchcraft-title'>\n Searchcraft Error Search Icon Dark\n </title>\n <path\n d='M16.5 16.5L12.875 12.875M14.8333 8.16667C14.8333 11.8486 11.8486 14.8333 8.16667 14.8333C4.48477 14.8333 1.5 11.8486 1.5 8.16667C1.5 4.48477 4.48477 1.5 8.16667 1.5C11.8486 1.5 14.8333 4.48477 14.8333 8.16667Z'\n stroke='#BFBFBF'\n stroke-width='1.5'\n stroke-linecap='round'\n stroke-linejoin='round'\n />\n </svg>\n );\n default:\n return null;\n }\n }\n}\n",".sliderContainer {\n display: flex;\n flex-direction: column;\n gap: 10px;\n font-family: Arial, sans-serif;\n align-items: center;\n width: 100%;\n}\n\n.rangeContainer {\n display: flex;\n position: relative;\n width: 100%;\n align-items: center;\n\n .activeRange {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n height: 4px;\n background: #007DB3;\n z-index: 0;\n border-radius: 2px;\n }\n\n .rangeSlider {\n width: 100%;\n height: 4px;\n background: transparent;\n border-radius: 2px;\n outline: none;\n -webkit-appearance: none;\n appearance: none;\n position: absolute;\n margin: 0;\n\n &::-webkit-slider-thumb {\n -webkit-appearance: none;\n width: 20px;\n height: 20px;\n background-color: #FFF;\n border-radius: 50%;\n border: 2px solid #e6e6e6;\n cursor: pointer;\n }\n\n &::-moz-range-thumb {\n width: 20px;\n height: 20px;\n background-color: #FFF;\n border-radius: 50%;\n border: 2px solid #e6e6e6;\n cursor: pointer;\n }\n }\n}\n\n.yearLabels {\n display: flex;\n justify-content: space-between;\n width: 100%;\n margin-top: 10px;\n font-size: 15px;\n font-weight: 600;\n font-family: 'Source Sans Pro', sans-serif;\n color: #666;\n}\n\n.yearLabel {\n min-width: 30px;\n text-align: center;\n}","import { Component, h, State, Prop } from '@stencil/core';\nimport { useSearchcraftStore } from '@provider/store';\n\n@Component({\n tag: 'searchcraft-slider',\n styleUrl: 'searchcraft-slider.module.scss',\n shadow: true,\n})\nexport class SearchcraftSlider {\n @Prop() maxYear = new Date().getFullYear();\n @Prop() minYear = 2014;\n\n @State() endYear = this.maxYear;\n @State() hasSearched = false;\n @State() query = '';\n @State() resultsCount = 0;\n @State() startYear = this.minYear;\n\n private searchStore = useSearchcraftStore.getState();\n\n unsubscribe: () => void;\n\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query.length > 0) {\n this.hasSearched = true;\n this.resultsCount = state.searchResults?.data?.hits?.length || 0;\n }\n this.query = state.query;\n });\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n private updateYears = async () => {\n this.searchStore.setYearsRange([this.startYear, this.endYear]);\n\n try {\n if (typeof this.query === 'string' && this.query.trim() !== '') {\n await this.searchStore.search();\n } else {\n console.warn('Query is missing or empty, skipping search request.');\n }\n } catch (error) {\n console.error('Search failed:', error);\n }\n };\n\n private handleStartYearChange = (event: InputEvent) => {\n const value = Number.parseInt((event.target as HTMLInputElement).value, 10);\n this.startYear = Math.min(value, this.endYear);\n this.updateYears();\n };\n\n private handleEndYearChange = (event: InputEvent) => {\n const value = Number.parseInt((event.target as HTMLInputElement).value, 10);\n this.endYear = Math.max(value, this.startYear);\n this.updateYears();\n };\n\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n\n const rangeMin = this.minYear;\n const rangeMax = this.maxYear;\n const startPercent =\n ((this.startYear - rangeMin) / (rangeMax - rangeMin)) * 100;\n const endPercent =\n ((this.endYear - rangeMin) / (rangeMax - rangeMin)) * 100;\n\n return (\n <div class='sliderContainer'>\n <div class='rangeContainer'>\n <div\n class='activeRange'\n style={{\n left: `${startPercent}%`,\n width: `${endPercent - startPercent}%`,\n }}\n />\n <input\n class='rangeSlider'\n max={this.maxYear}\n min={this.minYear}\n onInput={this.handleStartYearChange}\n step='1'\n type='range'\n value={this.startYear}\n />\n <input\n class='rangeSlider'\n max={this.maxYear}\n min={this.minYear}\n onInput={this.handleEndYearChange}\n step='1'\n type='range'\n value={this.endYear}\n />\n </div>\n <div class='yearLabels'>\n <span class='yearLabel'>{this.startYear}</span>\n <span class='yearLabel'>{this.endYear}</span>\n </div>\n </div>\n );\n }\n}\n","$spinner-size: 20px;\n\n.spinnerContainer {\n background-color: transparent;\n height: $spinner-size;\n width: $spinner-size;\n}\n\n.spinnerDark {\n animation: spinning 1s linear infinite;\n background: conic-gradient(#000 50%, #FFFFFF);\n clip-path: circle(50%);\n height: 100%;\n mask-image: radial-gradient(circle at center, rgba(0,0,0,0) calc($spinner-size/3), rgba(0,0,0,1) calc($spinner-size/3));\n width: 100%;\n}\n\n.spinnerLight {\n animation: spinning 1s linear infinite;\n background: conic-gradient(#737373 50%, #FFFFFF);\n clip-path: circle(50%);\n height: 100%;\n mask-image: radial-gradient(circle at center, rgba(0,0,0,0) calc($spinner-size/3), rgba(0,0,0,1) calc($spinner-size/3));\n width: 100%;\n}\n\n@keyframes spinning {\n 0% { transform: rotate(0deg); }\n 50% {transform: rotate(180deg);}\n 100% { transform: rotate(360deg); }\n}","import { Component, h } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-spinner-dark',\n styleUrl: 'searchcraft-spinner-dark.module.scss',\n shadow: true,\n})\nexport class SearchcraftSpinnerDark {\n render() {\n return (\n <div class='spinnerContainer'>\n <div class='spinnerDark' />\n </div>\n );\n }\n}\n","$spinner-size: 20px;\n\n.spinnerContainer {\n background-color: transparent;\n height: $spinner-size;\n width: $spinner-size;\n}\n\n.spinnerLight {\n animation: spinning 1s linear infinite;\n background: conic-gradient(#737373 50%, #FFFFFF);\n clip-path: circle(50%);\n height: 100%;\n mask-image: radial-gradient(circle at center, rgba(0,0,0,0) calc($spinner-size/3), rgba(0,0,0,1) calc($spinner-size/3));\n width: 100%;\n}\n\n@keyframes spinning {\n 0% { transform: rotate(0deg); }\n 50% {transform: rotate(180deg);}\n 100% { transform: rotate(360deg); }\n}","import { Component, h } from '@stencil/core';\n\n@Component({\n tag: 'searchcraft-spinner-light',\n styleUrl: 'searchcraft-spinner-light.module.scss',\n shadow: true,\n})\nexport class SearchcraftSpinnerLight {\n render() {\n return (\n <div class='spinnerContainer'>\n <div class='spinnerLight' />\n </div>\n );\n }\n}\n",".toggle-wrapper {\n background: #ddd;\n border: none;\n border-radius: 16px;\n box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.05);\n cursor: pointer;\n height: 26px;\n margin-left: 10px;\n position: relative;\n width: 44px;\n}\n\n.toggle-wrapper.active {\n background: #007DB3;\n box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.05);\n}\n\n.toggle-wrapper .toggle-switch {\n background: #fff;\n border-radius: 50%;\n height: 18px;\n left: 4px;\n position: absolute;\n top: calc(50% - 18px/2);\n transition: transform 0.3s ease;\n width: 18px;\n}\n\n.toggle-wrapper .toggle-switch.active {\n transform: translateX(16px);\n}\n","import { Component, h, Prop, State } from '@stencil/core';\nimport { useSearchcraftStore } from '@provider/store';\n\n@Component({\n tag: 'searchcraft-toggle-button',\n styleUrl: 'searchcraft-toggle-button.module.scss',\n shadow: true,\n})\nexport class SearchcraftToggleButton {\n /**\n * Type of the toggle - determines what it controls\n * 'mode': toggles between 'fuzzy' and 'normal'\n * 'sort': toggles between 'asc' and 'desc'\n */\n @Prop() type: 'mode' | 'sort' = 'mode';\n\n @State() isActive = false;\n @State() query = ''; // Track the query\n @State() resultsCount = 0; // Track the count of search results\n\n private unsubscribe: () => void;\n private searchStore = useSearchcraftStore.getState();\n\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.query = state.query || '';\n this.resultsCount = state.searchResults?.data?.hits?.length || 0;\n });\n }\n\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n\n private handleToggle = async () => {\n this.isActive = !this.isActive;\n\n if (this.type === 'mode') {\n const mode = this.isActive ? 'normal' : 'fuzzy';\n this.searchStore.setSearchParams({\n mode,\n });\n } else if (this.type === 'sort') {\n const sort = this.isActive ? 'desc' : 'asc';\n this.searchStore.setSearchParams({\n sort,\n });\n }\n\n try {\n await this.searchStore.search();\n } catch (error) {\n console.error('Search failed:', error);\n }\n };\n\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n\n return (\n <button\n class={`toggle-wrapper ${this.isActive ? 'active' : ''}`}\n onClick={this.handleToggle}\n type='button'\n >\n <div class={`toggle-switch ${this.isActive ? 'active' : ''}`} />\n </button>\n );\n }\n}\n"],"version":3}
|
|
@@ -50,7 +50,7 @@ const SearchcraftBaseSearchForm = class {
|
|
|
50
50
|
this.searchResults = null;
|
|
51
51
|
}
|
|
52
52
|
render() {
|
|
53
|
-
return (h("form", { key: '
|
|
53
|
+
return (h("form", { key: 'b7ec4a78fdb2fef83b7734cd3f3304726066f597', class: this.rightToLeftOrientation ? 'formRTL' : 'formLTR', onSubmit: this.handleFormSubmit }, h("searchcraft-input-label", { key: 'faf932837b0edf4c9c263558ed365c22ef82e71e', label: this.labelForInput }), h("div", { key: 'aa5c9d107d86d79bc37da1fa3f5e5fd9da3526a7', class: 'searchContainer' }, this.rightToLeftOrientation && h("searchcraft-button", { key: 'b8937b05ea7cfdb83a5f65f5dd6c7fd0ce46c49e' }), h("searchcraft-input", { key: '6d60cfa669d20323167e8c5930a56f56730e793c', onClearInput: this.handleClearInput, onSearchInputChange: this.handleSearchInputChange, query: this.query, rightToLeftOrientation: this.rightToLeftOrientation }), !this.rightToLeftOrientation && (h("searchcraft-button", { key: '622523c13da7f7f928c62a3d3c8d8bd2109c117f', onButtonClick: this.handleFormSubmit }))), this.error && (h("searchcraft-error-message", { key: 'c7fb8c7aa73f201b19cc86653cd685d159e34bfb', errorMessage: this.errorMessage }))));
|
|
54
54
|
}
|
|
55
55
|
};
|
|
56
56
|
SearchcraftBaseSearchForm.style = SearchcraftBaseSearchFormStyle0;
|
|
@@ -23,7 +23,7 @@ const SearchcraftButton = class {
|
|
|
23
23
|
}
|
|
24
24
|
render() {
|
|
25
25
|
const buttonStyle = this.getButtonStyle();
|
|
26
|
-
return (h(Fragment, { key: '
|
|
26
|
+
return (h(Fragment, { key: 'eb540b00f175ade3604c050f31bb0cfcc7e67d7e' }, this.iconOnly ? (h("button", { class: classNames(buttonStyle, 'searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.isRequesting ? (h("searchcraft-spinner-dark", null)) : (this.iconElement))) : (h("button", { class: classNames(buttonStyle, 'searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.iconPosition === 'left' && this.isRequesting ? (h("div", { class: 'spinner-margin-right' }, h("searchcraft-spinner-dark", null))) : (this.iconElement), h("span", { class: classNames(this.isRequesting && 'button-label', 'searchcraft-button-label') }, this.label)))));
|
|
27
27
|
}
|
|
28
28
|
};
|
|
29
29
|
SearchcraftButton.style = SearchcraftButtonStyle0;
|
|
@@ -16,7 +16,7 @@ var patchBrowser = () => {
|
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(async (options) => {
|
|
18
18
|
await globalScripts();
|
|
19
|
-
return bootstrapLazy([["searchcraft-auto-search-
|
|
19
|
+
return bootstrapLazy([["searchcraft-auto-search-form_18",[[1,"searchcraft-auto-search-form",{"autoSearchFormClass":[1,"auto-search-form-class"],"clearInput":[16],"config":[16],"customStylesForInput":[1,"custom-styles-for-input"],"inputCaptionValue":[1,"input-caption-value"],"inputIconHeight":[2,"input-icon-height"],"inputIconWidth":[2,"input-icon-width"],"labelForInput":[1,"label-for-input"],"placeholderValue":[1,"placeholder-value"],"rightToLeftOrientation":[4,"right-to-left-orientation"],"searchContainerClass":[1,"search-container-class"],"error":[32],"isRequesting":[32],"query":[32],"searchResults":[32]}],[1,"searchcraft-base-search-results",{"adInterval":[2,"ad-interval"],"customStylesForResults":[1,"custom-styles-for-results"],"documentAttributesForDisplay":[1,"document-attributes-for-display"],"fallbackElement":[16],"formatTime":[4,"format-time"],"placeAdAtEnd":[4,"place-ad-at-end"],"placeAdAtStart":[4,"place-ad-at-start"],"placeResultImageRight":[4,"place-result-image-right"],"hasSearched":[32],"query":[32],"searchResults":[32]}],[1,"searchcraft-filters-list",{"filters":[16],"dynamicFilters":[32],"isRequesting":[32],"query":[32],"resultsCount":[32],"selectedFilters":[32]}],[1,"searchcraft-results-info",{"isRequesting":[32],"resultsCount":[32],"responseTime":[32],"query":[32]}],[1,"searchcraft-slider",{"maxYear":[2,"max-year"],"minYear":[2,"min-year"],"endYear":[32],"hasSearched":[32],"query":[32],"resultsCount":[32],"startYear":[32]}],[1,"searchcraft-toggle-button",{"type":[1],"isActive":[32],"query":[32],"resultsCount":[32]}],[1,"searchcraft-base-search-result",{"buttonText":[1,"button-text"],"customStyles":[1,"custom-styles"],"headingText":[1,"heading-text"],"imageDescription":[1,"image-description"],"imageSource":[1,"image-source"],"isInteractive":[4,"is-interactive"],"primaryContent":[1,"primary-content"],"secondaryContent":[1,"secondary-content"],"subheadingText":[1,"subheading-text"],"tertiaryContent":[1,"tertiary-content"],"themeMode":[1,"theme-mode"],"placeImageRight":[4,"place-image-right"]}],[1,"searchcraft-check-icon"],[1,"searchcraft-input",{"customStyles":[1,"custom-styles"],"error":[4],"formClassName":[1,"form-class-name"],"inputCaptionClassName":[1,"input-caption-class-name"],"inputCaptionValue":[1,"input-caption-value"],"inputClassName":[1,"input-class-name"],"inputIconHeight":[2,"input-icon-height"],"inputIconWidth":[2,"input-icon-width"],"isRequesting":[4,"is-requesting"],"placeholderValue":[1,"placeholder-value"],"rightToLeftOrientation":[4,"right-to-left-orientation"],"query":[1],"theme":[32]}],[1,"searchcraft-input-label",{"inputLabelClassName":[1,"input-label-class-name"],"label":[1],"theme":[32]}],[1,"searchcraft-clear-input-button",{"isRequesting":[4,"is-requesting"],"rightToLeftOrientation":[4,"right-to-left-orientation"],"theme":[32]}],[1,"searchcraft-input-icon",{"error":[4],"height":[2],"rightToLeftOrientation":[4,"right-to-left-orientation"],"width":[2],"theme":[32]}],[1,"searchcraft-error-message",{"errorMessage":[1,"error-message"],"theme":[1]}],[1,"searchcraft-input-caption",{"error":[4],"inputCaptionClassName":[1,"input-caption-class-name"],"inputCaptionValue":[1,"input-caption-value"],"rightToLeftOrientation":[4,"right-to-left-orientation"],"theme":[32]}],[1,"searchcraft-clear-icon-set",{"type":[1]}],[1,"searchcraft-search-icon-set",{"type":[1],"width":[2],"height":[2]}],[1,"searchcraft-spinner-light"],[1,"searchcraft-spinner-dark"]]],["searchcraft-base-search-form",[[1,"searchcraft-base-search-form",{"config":[16],"errorMessage":[1,"error-message"],"labelForInput":[1,"label-for-input"],"rightToLeftOrientation":[4,"right-to-left-orientation"],"error":[32],"query":[32],"searchResults":[32]}]]],["searchcraft-button-icon",[[1,"searchcraft-button-icon"]]],["searchcraft-button",[[1,"searchcraft-button",{"iconElement":[16],"iconOnly":[4,"icon-only"],"iconPosition":[1,"icon-position"],"label":[1],"isRequesting":[32],"theme":[32]}]]]], options);
|
|
20
20
|
});
|
|
21
21
|
|
|
22
22
|
//# sourceMappingURL=searchcraft-javascript-sdk.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,c as i,h as o,F as r}from"./p-0880cfbb.js";import{c as s}from"./p-5cdc6210.js";const n=":root{--font-stack:Helvetica, Arial, sans-serif}.buttonLight{border-radius:8px;display:flex;font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;padding:11px 20px;position:relative;background-color:#000;border:1px solid #E6E6E6;color:#FFF}.buttonLight:hover{cursor:pointer}.buttonLight:hover{background-color:#2E2E2E}.buttonLight:focus{outline:2px solid #000000}.buttonDark{border-radius:8px;display:flex;font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;padding:11px 20px;position:relative;background-color:#FFF;border:1px solid #404040;color:#292929}.buttonDark:hover{cursor:pointer}.buttonDark:hover{background-color:#FAFAFA}.buttonDark:focus{outline:2px solid #404040}.spinnerMarginRight{left:4px;margin-right:4px;position:absolute}.spinnerMarginLeft{left:4px;margin-left:4px;position:absolute}.buttonLabel{animation:right-and-back 0.2s;margin-left:4px;position:relative}@keyframes right-and-back{0%{right:-6px}50%{right:-12px}75%{right:-6px}100%{right:0px}}";const a=n;const e=class{constructor(o){t(this,o);this.buttonClick=i(this,"buttonClick",7);this.handleClick=()=>{this.buttonClick.emit()};this.iconElement=undefined;this.iconOnly=false;this.iconPosition="left";this.label="Search";this.isRequesting=false;this.theme="light"}getButtonStyle(){return this.theme==="light"?"buttonLight":"buttonDark"}render(){const t=this.getButtonStyle();return o(r,{key:"
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,c as i,h as o,F as r}from"./p-0880cfbb.js";import{c as s}from"./p-5cdc6210.js";const n=":root{--font-stack:Helvetica, Arial, sans-serif}.buttonLight{border-radius:8px;display:flex;font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;padding:11px 20px;position:relative;background-color:#000;border:1px solid #E6E6E6;color:#FFF}.buttonLight:hover{cursor:pointer}.buttonLight:hover{background-color:#2E2E2E}.buttonLight:focus{outline:2px solid #000000}.buttonDark{border-radius:8px;display:flex;font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;padding:11px 20px;position:relative;background-color:#FFF;border:1px solid #404040;color:#292929}.buttonDark:hover{cursor:pointer}.buttonDark:hover{background-color:#FAFAFA}.buttonDark:focus{outline:2px solid #404040}.spinnerMarginRight{left:4px;margin-right:4px;position:absolute}.spinnerMarginLeft{left:4px;margin-left:4px;position:absolute}.buttonLabel{animation:right-and-back 0.2s;margin-left:4px;position:relative}@keyframes right-and-back{0%{right:-6px}50%{right:-12px}75%{right:-6px}100%{right:0px}}";const a=n;const e=class{constructor(o){t(this,o);this.buttonClick=i(this,"buttonClick",7);this.handleClick=()=>{this.buttonClick.emit()};this.iconElement=undefined;this.iconOnly=false;this.iconPosition="left";this.label="Search";this.isRequesting=false;this.theme="light"}getButtonStyle(){return this.theme==="light"?"buttonLight":"buttonDark"}render(){const t=this.getButtonStyle();return o(r,{key:"eb540b00f175ade3604c050f31bb0cfcc7e67d7e"},this.iconOnly?o("button",{class:s(t,"searchcraft-button"),onClick:this.handleClick,type:"submit"},this.isRequesting?o("searchcraft-spinner-dark",null):this.iconElement):o("button",{class:s(t,"searchcraft-button"),onClick:this.handleClick,type:"submit"},this.iconPosition==="left"&&this.isRequesting?o("div",{class:"spinner-margin-right"},o("searchcraft-spinner-dark",null)):this.iconElement,o("span",{class:s(this.isRequesting&&"button-label","searchcraft-button-label")},this.label)))}};e.style=a;export{e as searchcraft_button};
|
|
2
|
+
//# sourceMappingURL=p-66f38e89.entry.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as t,c as i,h as e,F as n}from"./p-0880cfbb.js";import{u as s,g as r}from"./p-901fee50.js";import{p as a,a as o,s as h,e as c,g as l,f as p}from"./p-2bda632c.js";import{c as d}from"./p-5cdc6210.js";const f=":root{--font-stack:Helvetica, Arial, sans-serif}.formLTR{font-family:var(--font-stack);text-align:left;width:100%}.formRTL{font-family:var(--font-stack);text-align:right;width:100%}";const g=f;const u=class{constructor(e){t(this,e);this.inputClearedOrNoResults=i(this,"inputClearedOrNoResults",7);this.querySubmit=i(this,"querySubmit",7);this.debounceTimeout=null;this.debounceDelay=0;this.searchStore=s.getState();this.handleInputChange=t=>{this.query=t.detail;this.searchStore.setQuery(this.query);this.querySubmit.emit(this.query)};this.handleInputKeyUp=t=>{const i=t.detail;this.query=i;this.searchStore.setQuery(this.query);this.querySubmit.emit(this.query);if(this.debounceTimeout){clearTimeout(this.debounceTimeout)}this.debounceTimeout=setTimeout((()=>{this.query.trim()!==""&&this.runSearch()}),this.debounceDelay)};this.handleClearInput=()=>{this.query="";this.searchStore.setQuery("");if(typeof this.clearInput==="function"){this.clearInput()}if(this.debounceTimeout){clearTimeout(this.debounceTimeout)}this.error=false;this.inputClearedOrNoResults.emit()};this.runSearch=async()=>{if(this.query.trim()===""){this.error=true;this.inputClearedOrNoResults.emit()}else{this.error=false;this.searchStore.setQuery(this.query);try{await this.searchStore.search()}catch(t){this.error=true;this.inputClearedOrNoResults.emit()}}};this.handleFormSubmit=async t=>{t.preventDefault();await this.runSearch()};this.autoSearchFormClass="";this.clearInput=()=>{};this.config={apiKey:"",endpointURL:"",index:[]};this.customStylesForInput={};this.inputCaptionValue="";this.inputIconHeight=20;this.inputIconWidth=20;this.labelForInput="";this.placeholderValue="Search here";this.rightToLeftOrientation=false;this.searchContainerClass="";this.error=false;this.isRequesting=false;this.query="";this.searchResults=null}componentDidLoad(){const t=new r(this.config);this.searchStore.initialize(t,true);this.unsubscribe=s.subscribe((t=>{this.isRequesting=t.isRequesting;this.searchResults=Object.assign({},t.searchResults)}))}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}render(){var t,i,n;const s=this.rightToLeftOrientation?"formRTL":"formLTR";const r=a(this.customStylesForInput);if(this.query.length>0&&((n=(i=(t=this.searchResults)===null||t===void 0?void 0:t.data)===null||i===void 0?void 0:i.hits)===null||n===void 0?void 0:n.length)===0){this.inputClearedOrNoResults.emit()}return e("form",{key:"cfc0e29f0f35598c13f5d87720f38d74cba292fb",class:`${s}`,onSubmit:this.handleFormSubmit},e("searchcraft-input-label",{key:"fd5635505ee5f863f128912377960752d4dccd2d",label:this.labelForInput}),e("searchcraft-input",{key:"84c3a6da7ed48e835aa74f87ad862672d38876c7",customStyles:r,"input-caption-value":this.inputCaptionValue,"input-icon-height":this.inputIconHeight,"input-icon-width":this.inputIconWidth,"is-requesting":this.isRequesting,onClearInput:this.handleClearInput,onInputKeyUp:this.handleInputKeyUp,onSearchInputChange:this.handleInputChange,"placeholder-value":this.placeholderValue,query:this.query,"right-to-left-orientation":this.rightToLeftOrientation}),this.error&&e("searchcraft-error-message",{key:"bcb99f333d73ed811c7d7a6d85736ba94fb7fa56",errorMessage:"Please enter a search query."}))}};u.style=g;const x='@charset "UTF-8";:root{--font-stack:Helvetica, Arial, sans-serif}.interactiveResultContainerLight{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#FAFAFA}@media (min-width: 600px){.interactiveResultContainerLight{flex-direction:row}}.interactiveResultContainerDark{align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;position:relative;background-color:#2E2E2E}@media (min-width: 600px){.interactiveResultContainerDark{flex-direction:row}}.resultContainer{align-items:flex-start;display:flex;flex-direction:column;gap:16px}@media (min-width: 600px){.resultContainer{flex-direction:row}}.interactiveIconLarge{display:inline-block;position:absolute;right:5px;top:8px}@media (max-width: 600px){.interactiveIconLarge{display:none}}.interactiveIconSmall{display:inline-block;position:absolute;right:5px;top:-2px}@media (min-width: 600px){.interactiveIconSmall{display:none}}.imageContainer{max-width:100%}.contentContainer{max-height:100%;max-width:100%}@media (min-width: 600px){.contentContainer{max-width:50%}}.secondaryContentContainer{display:flex}.imageLight{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #D9D9D9}.imageDark{border-radius:8px;max-height:100%;max-width:100%;border:1px solid #333}.headingLight{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;-webkit-font-smoothing:antialiased;color:#292929}.headingDark{font-family:var(--font-stack);font-size:16px;font-weight:700;line-height:20px;margin-bottom:4px;margin-top:0;position:relative;-webkit-font-smoothing:antialiased;color:#FFF}.subheadingLight{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#737373}.subheadingDark{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#BFBFBF}.primaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.primaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}.secondaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.secondaryContentLight::after{content:"•";color:#404040;font-size:1em;margin-left:5px;margin-right:5px}.secondaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}.tertiaryContentLight{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#404040}.tertiaryContentDark{font-family:var(--font-stack);font-size:16px;font-weight:400;line-height:20px;margin-bottom:4px;margin-top:0px;-webkit-font-smoothing:antialiased;color:#E6E6E6}';const b=x;const k=class{constructor(e){t(this,e);this.buttonCallback=i(this,"buttonCallback",7);this.keyDownCallback=i(this,"keyDownCallback",7);this.resultCallback=i(this,"resultCallback",7);this.buttonCallback=()=>{};this.keyDownCallback=()=>{};this.resultCallback=()=>{};this.handleButtonClick=()=>{this.buttonCallback()};this.handleContainerClick=()=>{if(this.isInteractive){this.resultCallback()}};this.buttonText="";this.customStyles="{}";this.headingText="";this.imageDescription="";this.imageSource="";this.isInteractive=false;this.primaryContent="";this.secondaryContent="";this.subheadingText="";this.tertiaryContent="";this.themeMode="light";this.placeImageRight=false}parseStyles(){try{return JSON.parse(this.customStyles)}catch(t){console.error("Error parsing custom styles:",t);return{}}}render(){const t=this.themeMode==="light";const i=this.parseStyles();const s=this.imageSource&&e("div",{key:"bc2c9e7e6fdfdd7a159adeaae93ee295f3871bb1",class:"imageContainer"},e("img",{key:"403cf6f083a0fab8c0d84f858e6f799bb5e39856",alt:this.imageDescription,class:t?"imageLight":"imageDark",src:this.imageSource,style:i.image||{}}));const r=e("div",{key:"ec56243d676a5dfbdc7d9dc5be9f2e078ab3e599",class:"contentContainer"},e("h2",{key:"e2d73b3c6c18753fee3e3a2a8526a68c62a0a2f5",class:t?"headingLight":"headingDark",style:i.heading||{}},this.headingText),e("h3",{key:"fccf35b5a06c09c96150568d4cd71bacea1fe15d",class:t?"subheadingLight":"subheadingDark",style:i.subheading||{}},this.subheadingText),e("p",{key:"95b64831fd0248f69773cafa6357133f9758748c",class:t?"primaryContentLight":"primaryContentDark",style:i.primaryContent||{}},this.primaryContent),e("div",{key:"f1e597968aab316067762bca3e39bccb50f3b34a",class:"secondaryContentContainer"},e("p",{key:"05ccdbb2854cd538fa2fd9e3a6efe8fa8ea46003",class:t?"secondaryContentLight":"secondaryContentDark",style:i.secondaryContent||{}},this.secondaryContent),e("p",{key:"ca2b96c02c9d8b073b0e0cff3e288d9eba7e3cd1",class:t?"tertiaryContentLight":"tertiaryContentDark",style:i.tertiaryContent||{}},this.tertiaryContent)),this.buttonText&&e("button",{key:"9d728eb6dcc2cdc2d0b438e79286795835dbf9e6",onClick:this.handleButtonClick,style:i.button||{},type:"button"},this.buttonText));return e("div",{key:"44c9677d5c3c75439b9d73d8e60e5744d2ee9be0",class:this.isInteractive?t?"interactiveResultContainerLight":"interactiveResultContainerDark":"resultContainer",onKeyDown:this.keyDownCallback,onClick:this.handleContainerClick,style:i.container||{},tabindex:"0"},this.placeImageRight?e(n,null,r,s):e(n,null,s,r))}};k.style=b;const m=":root{--font-stack:Helvetica, Arial, sans-serif}.resultsContainer{display:flex;flex-direction:column;justify-content:center;margin:16px 0}.resultsContainer>p{align-self:center}.resultsContainer>div{margin-bottom:20px}.resultsContainer>div img{height:300px;width:200px}.adSection{align-items:center;background-color:#F1F1F1;border:1px solid #DCDDDE;border-radius:16px;display:flex;flex-direction:column;font-size:16px;justify-content:center;margin:auto;min-height:150px;text-align:center;width:100%}.adSection p{margin-top:5px}.emptyState{text-align:center;width:100%}.errorMessageContainer{text-align:center}";const y=m;const v=class{constructor(i){t(this,i);this.adInterval=4;this.customStylesForResults={};this.documentAttributesForDisplay="";this.fallbackElement=null;this.formatTime=true;this.placeAdAtEnd=false;this.placeAdAtStart=true;this.placeResultImageRight=false;this.hasSearched=false;this.query="";this.searchResults=null}componentDidLoad(){if(!this.documentAttributesForDisplay||this.documentAttributesForDisplay.length===0){console.warn("No document attributes provided; using empty keys array.");this.documentAttributesForDisplay=""}this.unsubscribe=s.subscribe((t=>{if(t.query.length>0){this.hasSearched=true}else{this.hasSearched=false}this.searchResults=Object.assign({},t.searchResults);this.query=t.query}));const{searchResults:t,query:i}=s.getState();this.searchResults=t;this.query=i}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}render(){var t,i,n,s,r,a,p;if(!this.hasSearched){return e("div",{class:"emptyState"},e("slot",{name:"empty-search"}))}if(!((t=this.searchResults)===null||t===void 0?void 0:t.data)){console.warn("No search results data available");return e("div",{class:"emptyState"},"No results to display.")}const d=o(this.documentAttributesForDisplay);const f=typeof this.customStylesForResults==="string"?this.customStylesForResults:h(this.customStylesForResults);const g=(s=(n=(i=this.searchResults)===null||i===void 0?void 0:i.data)===null||n===void 0?void 0:n.hits)===null||s===void 0?void 0:s.map(((t,i)=>{const{doc:n}=t;const s=c(n,d);if(this.formatTime){for(const t of d){if(s[t]){const i=s[t];if(typeof i==="string"&&!Number.isNaN(Date.parse(i))){s[t]=l(i)}}}}return e("searchcraft-base-search-result",{"button-callback":()=>console.log("button callback"),"custom-styles":f,"image-source":s[d[d.length-1]],"is-interactive":true,key:`${t.document_id}-${i}`,"keydown-callback":()=>console.log("keydown"),"heading-text":s[d[0]],"place-image-right":this.placeResultImageRight,"primary-content":s[d[2]],"result-callback":()=>console.log("interactive element"),"secondary-content":s[d[3]],"subheading-text":s[d[1]],"tertiary-content":s[d[4]]})}));const u=[];if(this.placeAdAtStart){u.push(e("div",{key:"ad-section-start",class:"adSection"},e("span",null,"##"),e("p",null," Ad Impressions")))}if(this.adInterval>0){g.forEach(((t,i)=>{u.push(t);if((i+1)%this.adInterval===0){u.push(e("div",{key:`ad-section-${i+1}`,class:"adSection"},e("span",null,"##"),e("p",null," Ad Impressions")))}}))}else{u.push(...g)}if(this.placeAdAtEnd){u.push(e("div",{key:"ad-section-end",class:"adSection"},e("span",null,"##"),e("p",null," Ad Impressions")))}return e("div",{class:"resultsContainer"},u,this.query.length>0&&((p=(a=(r=this.searchResults)===null||r===void 0?void 0:r.data)===null||a===void 0?void 0:a.hits)===null||p===void 0?void 0:p.length)===0&&e("div",{class:"errorMessageContainer"},e("searchcraft-error-message",{"error-message":`No search results found for "${this.query}" query`})))}};v.style=y;const w=class{constructor(i){t(this,i)}render(){return e("svg",{key:"3db200942b79612a38293544a029c6854dfa4beb",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},e("title",{key:"b7b6af8651edb5cc0e054ed775b9029c6c93535e"},"Checkbox Check"),e("path",{key:"7c74edc45f007245e4c6e4fd5d37dbc6dad20de0",d:"M13.9999 2L5.74988 10L1.99988 6.36364",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"}))}};const L=class{constructor(i){t(this,i);this.type="clear-light"}render(){switch(this.type){case"clear-light":return e("svg",{width:"22",height:"22",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},e("title",{id:"icon-title"},"Searchcraft Clear Input Icon Light"),e("path",{d:"M14 8L8 14M8 8L14 14M21 11C21 16.5228 16.5228 21 11 21C5.47715 21 1 16.5228 1 11C1 5.47715 5.47715 1 11 1C16.5228 1 21 5.47715 21 11Z",stroke:"black","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"clear-dark":return e("svg",{width:"22",height:"22",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},e("title",{id:"icon-title"},"Searchcraft Clear Input Icon Dark"),e("path",{d:"M14 8L8 14M8 8L14 14M21 11C21 16.5228 16.5228 21 11 21C5.47715 21 1 16.5228 1 11C1 5.47715 5.47715 1 11 1C16.5228 1 21 5.47715 21 11Z",stroke:"white","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"arrow-light":return e("svg",{width:"20",height:"21",viewBox:"0 0 20 21",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},e("title",{id:"icon-title"},"Searchcraft Arrow Right Icon Light"),e("path",{d:"M7.5 15.0444L12.5 10.0444L7.5 5.04443",stroke:"#737373","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"arrow-dark":return e("svg",{width:"8",height:"12",viewBox:"0 0 8 12",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},e("title",{id:"icon-title"},"Searchcraft Arrow Right Icon Dark"),e("path",{d:"M1.5 11L6.5 6L1.5 1",stroke:"#BFBFBF","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));default:return null}}};const C=":root{--font-stack:Helvetica, Arial, sans-serif}.inputClearButtonLTR{align-items:center;background:none;border:none;display:flex;height:20px;justify-content:center;padding:0;position:absolute;right:0;top:50%;transform:translateY(-50%);width:20px}.inputClearButtonRTL{align-items:center;background:none;border:none;display:flex;height:20px;justify-content:center;left:0px;padding:0;position:absolute;top:50%;transform:translateY(-50%);width:20px}";const F=C;const D=class{constructor(e){t(this,e);this.clearInput=i(this,"clearInput",7);this.handleClearClick=t=>{t.preventDefault();this.clearInput.emit()};this.isRequesting=false;this.rightToLeftOrientation=false;this.theme="light"}isLightTheme(){return this.theme==="light"}render(){return this.rightToLeftOrientation?e("button",{class:d("inputClearButtonRTL",".sc-clear-input-button-rtl"),onClick:this.handleClearClick,type:"button"},this.isRequesting?this.isLightTheme?e("searchcraft-spinner-light",null):e("searchcraft-spinner-dark",null):this.isLightTheme?e("searchcraft-clear-icon-set",{type:"clear-light"}):e("searchcraft-clear-icon-set",{type:"clear-dark"})):e("button",{class:d("inputClearButtonLTR",".sc-clear-input-button-ltr"),onClick:this.handleClearClick,type:"button"},this.isRequesting?this.isLightTheme?e("searchcraft-spinner-light",null):e("searchcraft-spinner-dark",null):this.isLightTheme?e("searchcraft-clear-icon-set",{type:"clear-light"}):e("searchcraft-clear-icon-set",{type:"clear-dark"}))}};D.style=F;const R=":root{--font-stack:Helvetica, Arial, sans-serif}.errorMessageLight{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#990000}.errorMessageDark{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#FFB3B3}";const T=R;const E=class{constructor(i){t(this,i);this.errorMessage=undefined;this.theme="light"}render(){const t=this.theme==="light"?"errorMessageLight":"errorMessageDark";return e("p",{key:"af47ef1acca6beb5ba557f55a6f911fad9184bb7",class:d(t)},this.errorMessage||"Search term is required.")}};E.style=T;const B='.filtersList{width:100%}.checkboxLabel{align-items:center;color:#292929;display:flex;font-family:"Source Sans Pro";font-size:14px;font-weight:600;gap:14px;position:relative;-webkit-font-smoothing:antialiased}.checkboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:#EDEDED;border:1px solid #D9D9D9;cursor:pointer;display:flex;height:24px;justify-content:center;width:24px}.checkboxLabel input[type=checkbox]:checked{background-color:#000;position:relative}.checkboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.remainingFilterListCheckbox{margin-left:16px}.childCheckboxLabel{align-items:center;color:#292929;display:flex;font-family:"Source Sans Pro";font-size:14px;font-weight:600;gap:12px;position:relative}.childCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:#EDEDED;border:1px solid #D9D9D9;cursor:pointer;display:flex;height:24px;justify-content:center;position:relative;width:24px;-webkit-font-smoothing:antialiased}.childCheckboxLabel input[type=checkbox]:checked{background-color:#000;position:relative}.childCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.checkContainer{display:none;height:16px;width:16px;position:absolute;top:10px;left:7px}';const S=B;const z=class{constructor(e){t(this,e);this.filtersUpdated=i(this,"filtersUpdated",7);this.searchStore=s.getState();this.handleFilterChange=(t,i)=>{if(i){this.selectedFilters.add(t)}else{this.selectedFilters.delete(t)}const e=this.deduplicatePaths(Array.from(this.selectedFilters));this.filtersUpdated.emit(e);this.searchStore.setSelectedFilters(e);this.searchStore.search()};this.filters=[];this.dynamicFilters=[];this.isRequesting=false;this.query="";this.resultsCount=0;this.selectedFilters=new Set}connectedCallback(){var t;const i=this.searchStore;if((t=i.searchResults)===null||t===void 0?void 0:t.data.facets){this.populateFiltersFromFacets(i.searchResults.data.facets)}this.unsubscribe=s.subscribe((t=>{var i,e,n,s;if(!t.query||t.query.trim().length===0){if(this.selectedFilters.size>0){this.selectedFilters.clear();this.filtersUpdated.emit([]);if(this.searchStore.selectedFilters.length>0){this.searchStore.setSelectedFilters([])}}}this.query=t.query||"";this.isRequesting=t.isRequesting;this.resultsCount=((n=(e=(i=t.searchResults)===null||i===void 0?void 0:i.data)===null||e===void 0?void 0:e.hits)===null||n===void 0?void 0:n.length)||0;if((s=t.searchResults)===null||s===void 0?void 0:s.data.facets){this.populateFiltersFromFacets(t.searchResults.data.facets)}}))}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}populateFiltersFromFacets(t){var i;const e=p(((i=t[0])===null||i===void 0?void 0:i.section)||[]);const n=new Map;this.dynamicFilters.forEach((t=>{const i=t.value.split("/").pop()||"";n.set(i,t)}));e.forEach((t=>{const i=t.value.split("/").pop()||"";const e=n.get(i);if(!e||t.value.length<e.value.length){n.set(i,t)}}));this.dynamicFilters=Array.from(n.values())}deduplicatePaths(t){const i=new Map;t.forEach((t=>{const e=t.split("/").pop()||"";const n=i.get(e);if(!n||t.length<n.length){i.set(e,t)}}));return Array.from(i.values())}formatLabel(t){return t.replace(/-/g," ").split(" ").map((t=>t.charAt(0).toUpperCase()+t.slice(1))).join(" ")}render(){if(!this.query||this.resultsCount===0){return null}const t=this.dynamicFilters.filter((t=>!t.value.includes("/",t.value.indexOf("/")+1)));return e("div",{class:"filtersList"},t.map((t=>{const i=this.selectedFilters.has(t.value);const n=this.dynamicFilters.filter((i=>i.value.startsWith(`${t.value}/`)&&i.value!==t.value));return e("div",{key:t.value},e("label",{class:"checkboxLabel"},e("input",{class:"filterCheckbox",checked:i,onChange:i=>this.handleFilterChange(t.value,i.target.checked),type:"checkbox"}),e("div",{class:"checkContainer"},e("searchcraft-check-icon",null)),this.formatLabel(t.label)),n.map((t=>{const i=this.selectedFilters.has(t.value);return e("label",{class:"childCheckboxLabel",key:t.value,style:{marginLeft:"20px"}},e("input",{class:"childFilterCheckbox",checked:i,onChange:i=>this.handleFilterChange(t.value,i.target.checked),type:"checkbox"}),e("div",{class:"checkContainer"},e("searchcraft-check-icon",null)),this.formatLabel(t.label.split("/").pop()||""))})))})))}};z.style=S;const _=":root{--font-stack:Helvetica, Arial, sans-serif}.inputContainerLTR{position:relative;width:100%}.inputContainerRTL{position:relative;width:100%;margin-left:8px}.inputLightLTR{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#EDEDED;color:#292929;margin-right:8px;padding-left:36px;padding-right:16px}.inputLightLTR::placeholder{font-family:var(--font-stack);font-size:16px}.inputLightLTR::placeholder{color:#737373}.inputLightLTR:focus{outline:2px solid #000}.inputDarkLTR{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#1A1A1A;color:#FFF;margin-right:8px;padding-left:36px;padding-right:16px}.inputDarkLTR::placeholder{font-family:var(--font-stack);font-size:16px}.inputDarkLTR::placeholder{color:#BFBFBF}.inputDarkLTR:focus{outline:2px solid #FFF}.inputErrorLightLTR{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#EDEDED;color:#292929;outline:2px solid #c00;margin-right:8px;padding-left:36px;padding-right:16px}.inputErrorLightLTR::placeholder{font-family:var(--font-stack);font-size:16px}.inputErrorLightLTR::placeholder{color:#737373}.inputErrorLightLTR:focus{outline:2px solid #000}.inputErrorLightLTR:focus-visible{outline:2px solid #c00}.inputErrorDarkLTR{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#1A1A1A;color:#FFF;outline:2px solid #FFB3B3;margin-right:8px;padding-left:36px;padding-right:16px}.inputErrorDarkLTR::placeholder{font-family:var(--font-stack);font-size:16px}.inputErrorDarkLTR::placeholder{color:#BFBFBF}.inputErrorDarkLTR:focus{outline:2px solid #FFF}.inputErrorDarkLTR:focus-visible{outline:2px solid #FFB3B3}.inputLightRTL{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#EDEDED;color:#292929;margin-left:8px;padding-left:16px;padding-right:36px;text-align:right}.inputLightRTL::placeholder{font-family:var(--font-stack);font-size:16px}.inputLightRTL::placeholder{color:#737373}.inputLightRTL:focus{outline:2px solid #000}.inputDarkRTL{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#1A1A1A;color:#FFF;margin-left:8px;padding-left:16px;padding-right:36px;text-align:right}.inputDarkRTL::placeholder{font-family:var(--font-stack);font-size:16px}.inputDarkRTL::placeholder{color:#BFBFBF}.inputDarkRTL:focus{outline:2px solid #FFF}.inputErrorLightRTL{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#EDEDED;color:#292929;outline:2px solid #c00;margin-left:8px;padding-left:16px;padding-right:36px;text-align:right}.inputErrorLightRTL::placeholder{font-family:var(--font-stack);font-size:16px}.inputErrorLightRTL::placeholder{color:#737373}.inputErrorLightRTL:focus{outline:2px solid #000}.inputErrorLightRTL:focus-visible{outline:2px solid #c00}.inputErrorDarkRTL{border:none;border-radius:8px;font-family:var(--font-stack);outline:none;padding-bottom:15px;padding-top:15px;width:100%;background-color:#1A1A1A;color:#FFF;outline:2px solid #FFB3B3;margin-left:8px;padding-left:16px;padding-right:36px;text-align:right}.inputErrorDarkRTL::placeholder{font-family:var(--font-stack);font-size:16px}.inputErrorDarkRTL::placeholder{color:#BFBFBF}.inputErrorDarkRTL:focus{outline:2px solid #FFF}.inputErrorDarkRTL:focus-visible{outline:2px solid #FFB3B3}.inputWrapper{align-items:center;display:flex;position:relative;width:100%}";const I=_;const A=class{constructor(e){t(this,e);this.clearInput=i(this,"clearInput",7);this.searchInputChange=i(this,"searchInputChange",7);this.inputKeyUp=i(this,"inputKeyUp",7);this.customStyles={};this.error=false;this.formClassName="";this.inputCaptionClassName="";this.inputCaptionValue="";this.inputClassName="";this.inputIconHeight=20;this.inputIconWidth=20;this.isRequesting=false;this.placeholderValue="Enter Search";this.rightToLeftOrientation=false;this.query="";this.theme="light"}get isLightTheme(){return this.theme==="light"}handleInputChange(t){const i=t.target;this.searchInputChange.emit(i.value)}handleInputKeyUp(t){const i=t.target;this.inputKeyUp.emit(i.value)}handleClearInput(){if(this.clearInput){this.clearInput.emit()}}render(){const t=this.rightToLeftOrientation?"inputContainerRTL":"inputContainerLTR";const i=d(this.error?this.isLightTheme?"inputErrorLightRTL":"inputErrorDarkRTL":this.isLightTheme?"inputLightLTR":"inputDarkLTR","searchcraft-input");const s=a(this.customStyles);const r={fontSize:s.placeholderFontSize||"16px"};return e("div",{key:"3c655e3572de20f333b75f85e45cc957ac0bc006",class:d(t,this.formClassName,"searchcraft-input-form")},this.rightToLeftOrientation?e(n,null,e("input",{autoComplete:"off",class:d(i,"searchcraft-input"),id:"searchcraft-input-id",onChange:this.handleInputChange.bind(this),onKeyUp:this.handleInputKeyUp.bind(this),placeholder:this.placeholderValue,type:"text",value:this.query,style:s}),e("style",null,`\n #searchcraft-input-id::placeholder {\n font-size: ${r.fontSize};\n }\n `),this.inputCaptionValue&&e("searchcraft-input-caption",{inputCaptionClassName:this.inputCaptionClassName,inputCaptionValue:this.inputCaptionValue,rightToLeftOrientation:this.rightToLeftOrientation}),this.query.length>0&&e("searchcraft-clear-input-button",{isRequesting:this.isRequesting,onClearInput:this.handleClearInput,rightToLeftOrientation:this.rightToLeftOrientation}),e("searchcraft-input-icon",{error:this.error,height:this.inputIconHeight,rightToLeftOrientation:this.rightToLeftOrientation,width:this.inputIconWidth})):e(n,null,e("searchcraft-input-icon",{error:this.error,height:this.inputIconHeight,rightToLeftOrientation:this.rightToLeftOrientation,width:this.inputIconWidth}),e("input",{autoComplete:"off",class:d(i,"searchcraft-input"),id:"searchcraft-input-id",onChange:this.handleInputChange.bind(this),onKeyUp:this.handleInputKeyUp.bind(this),placeholder:this.placeholderValue,type:"text",value:this.query,style:s}),e("style",null,`\n #searchcraft-input-id::placeholder {\n font-size: ${r.fontSize};\n }\n `),this.inputCaptionValue&&e("searchcraft-input-caption",{inputCaptionClassName:this.inputCaptionClassName,inputCaptionValue:this.inputCaptionValue,rightToLeftOrientation:this.rightToLeftOrientation}),this.query.length>0&&e("searchcraft-clear-input-button",{isRequesting:this.isRequesting,onClearInput:this.handleClearInput,rightToLeftOrientation:this.rightToLeftOrientation})))}};A.style=I;const M=":root{--font-stack:Helvetica, Arial, sans-serif}.inputCaptionLightLTR{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#404040}.inputCaptionDarkLTR{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#E6E6E6}.inputCaptionErrorLightLTR{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#990000}.inputCaptionErrorDarkLTR{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#FFB3B3}.inputCaptionLightRTL{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#404040;text-align:right}.inputCaptionDarkRTL{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#E6E6E6;text-align:right}.inputCaptionErrorLightRTL{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#990000;text-align:right}.inputCaptionErrorDarkRTL{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#FFB3B3;text-align:right}";const j=M;const $=class{constructor(i){t(this,i);this.error=undefined;this.inputCaptionClassName="";this.inputCaptionValue="Enter Search";this.rightToLeftOrientation=false;this.theme="light"}isLightTheme(){return this.theme==="light"}render(){return this.rightToLeftOrientation?e("p",{class:d(this.error?this.isLightTheme?"inputCaptionErrorLightRTL":"inputCaptionErrorDarkRTL":this.isLightTheme?"inputCaptionLightRTL":"inputCaptionDarkRTL",this.inputCaptionClassName,".searchcraft-input-caption")},this.inputCaptionValue):e("p",{class:d(this.error?this.isLightTheme?"inputCaptionErrorLightLTR":"inputCaptionErrorDarkLTR":this.isLightTheme?"inputCaptionLightLTR":"inputCaptionDarkLTR",this.inputCaptionClassName,".searchcraft-input-caption")},this.inputCaptionValue)}};$.style=j;const N=":root{--font-stack:Helvetica, Arial, sans-serif}.inputIconLTR{left:15px;position:absolute;top:50%;transform:translateY(-50%)}.inputIconRTL{position:absolute;right:15px;top:50%;transform:translateY(-50%)}";const q=N;const O=class{constructor(i){t(this,i);this.error=undefined;this.height=20;this.rightToLeftOrientation=false;this.width=20;this.theme="light"}isLightTheme(){return this.theme==="light"}render(){return this.error?e("div",{class:this.rightToLeftOrientation?"inputIconRTL":"inputIconLTR"},this.isLightTheme()?e("searchcraft-search-icon-set",{height:this.height,type:"error-light",width:this.width}):e("searchcraft-search-icon-set",{height:this.height,type:"error-dark",width:this.width})):e("div",{class:this.rightToLeftOrientation?"inputIconRTL":"inputIconLTR"},this.isLightTheme()?e("searchcraft-search-icon-set",{height:this.height,type:"search-light",width:this.width}):e("searchcraft-search-icon-set",{height:this.height,type:"search-dark",width:this.width}))}};O.style=q;const H=":root{--font-stack:Helvetica, Arial, sans-serif}.labelLight{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#292929}.labelDark{font-family:var(--font-stack);font-size:12px;font-weight:400;line-height:16px;margin-top:4px;color:#FFF}";const U=H;const K=class{constructor(i){t(this,i);this.inputLabelClassName="";this.label=undefined;this.theme="light"}isLightTheme(){return this.theme==="light"}render(){if(!this.label){return null}const t=this.isLightTheme()?"labelLight":"labelDark";return e("label",{class:d(t,this.inputLabelClassName),htmlFor:"searchcraft-input-id"},this.label)}};K.style=U;const Z=".container{border-bottom:1px solid #D9D9D9;display:flex;justify-content:flex-start;width:100%}.resultsInfo{color:#292929;font-size:18px;font-weight:600;line-height:20px;margin:0;margin-bottom:8px}";const P=Z;const Y=class{constructor(i){t(this,i);this.isRequesting=false;this.resultsCount=0;this.responseTime="";this.query=""}connectedCallback(){this.unsubscribe=s.subscribe((t=>{var i,e,n,s;this.isRequesting=t.isRequesting;this.resultsCount=((e=(i=t.searchResults)===null||i===void 0?void 0:i.data)===null||e===void 0?void 0:e.count)||0;this.responseTime=((((s=(n=t.searchResults)===null||n===void 0?void 0:n.data)===null||s===void 0?void 0:s.time_taken)||0)*1e3).toFixed(2);this.query=t.query||""}))}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}render(){if(!this.query||this.resultsCount===0){return null}return e("div",{class:"container"},e("p",{class:"resultsInfo"},this.resultsCount," results found in ",this.responseTime,"ms"))}};Y.style=P;const V=class{constructor(i){t(this,i);this.type="search-dark";this.width=20;this.height=20}render(){const{width:t,height:i}=this;switch(this.type){case"search-light":return e("svg",{width:t,height:i,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},e("title",{id:"searchcraft-title"},"Searchcraft Search Icon Light"),e("path",{d:"M17.5 17.5L13.875 13.875M15.8333 9.16667C15.8333 12.8486 12.8486 15.8333 9.16667 15.8333C5.48477 15.8333 2.5 12.8486 2.5 9.16667C2.5 5.48477 5.48477 2.5 9.16667 2.5C12.8486 2.5 15.8333 5.48477 15.8333 9.16667Z",stroke:"#404040","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"search-dark":return e("svg",{width:t,height:i,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},e("title",{id:"searchcraft-title"},"Searchcraft Search Icon Dark"),e("path",{d:"M16.5 16.5L12.875 12.875M14.8333 8.16667C14.8333 11.8486 11.8486 14.8333 8.16667 14.8333C4.48477 14.8333 1.5 11.8486 1.5 8.16667C1.5 4.48477 4.48477 1.5 8.16667 1.5C11.8486 1.5 14.8333 4.48477 14.8333 8.16667Z",stroke:"#E6E6E6","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"error-light":return e("svg",{width:t,height:i,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},e("title",{id:"searchcraft-title"},"Searchcraft Error Search Icon Light"),e("path",{d:"M17.5 17.5L13.875 13.875M15.8333 9.16667C15.8333 12.8486 12.8486 15.8333 9.16667 15.8333C5.48477 15.8333 2.5 12.8486 2.5 9.16667C2.5 5.48477 5.48477 2.5 9.16667 2.5C12.8486 2.5 15.8333 5.48477 15.8333 9.16667Z",stroke:"#737373","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));case"error-dark":return e("svg",{width:t,height:i,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},e("title",{id:"searchcraft-title"},"Searchcraft Error Search Icon Dark"),e("path",{d:"M16.5 16.5L12.875 12.875M14.8333 8.16667C14.8333 11.8486 11.8486 14.8333 8.16667 14.8333C4.48477 14.8333 1.5 11.8486 1.5 8.16667C1.5 4.48477 4.48477 1.5 8.16667 1.5C11.8486 1.5 14.8333 4.48477 14.8333 8.16667Z",stroke:"#BFBFBF","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}));default:return null}}};const J='.sliderContainer{display:flex;flex-direction:column;gap:10px;font-family:Arial, sans-serif;align-items:center;width:100%}.rangeContainer{display:flex;position:relative;width:100%;align-items:center}.rangeContainer .activeRange{position:absolute;top:50%;transform:translateY(-50%);height:4px;background:#007DB3;z-index:0;border-radius:2px}.rangeContainer .rangeSlider{width:100%;height:4px;background:transparent;border-radius:2px;outline:none;-webkit-appearance:none;appearance:none;position:absolute;margin:0}.rangeContainer .rangeSlider::-webkit-slider-thumb{-webkit-appearance:none;width:20px;height:20px;background-color:#FFF;border-radius:50%;border:2px solid #e6e6e6;cursor:pointer}.rangeContainer .rangeSlider::-moz-range-thumb{width:20px;height:20px;background-color:#FFF;border-radius:50%;border:2px solid #e6e6e6;cursor:pointer}.yearLabels{display:flex;justify-content:space-between;width:100%;margin-top:10px;font-size:15px;font-weight:600;font-family:"Source Sans Pro", sans-serif;color:#666}.yearLabel{min-width:30px;text-align:center}';const Q=J;const W=class{constructor(i){t(this,i);this.searchStore=s.getState();this.updateYears=async()=>{this.searchStore.setYearsRange([this.startYear,this.endYear]);try{if(typeof this.query==="string"&&this.query.trim()!==""){await this.searchStore.search()}else{console.warn("Query is missing or empty, skipping search request.")}}catch(t){console.error("Search failed:",t)}};this.handleStartYearChange=t=>{const i=Number.parseInt(t.target.value,10);this.startYear=Math.min(i,this.endYear);this.updateYears()};this.handleEndYearChange=t=>{const i=Number.parseInt(t.target.value,10);this.endYear=Math.max(i,this.startYear);this.updateYears()};this.maxYear=(new Date).getFullYear();this.minYear=2014;this.endYear=this.maxYear;this.hasSearched=false;this.query="";this.resultsCount=0;this.startYear=this.minYear}componentDidLoad(){this.unsubscribe=s.subscribe((t=>{var i,e,n;if(t.query.length>0){this.hasSearched=true;this.resultsCount=((n=(e=(i=t.searchResults)===null||i===void 0?void 0:i.data)===null||e===void 0?void 0:e.hits)===null||n===void 0?void 0:n.length)||0}this.query=t.query}))}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}render(){if(!this.query||this.resultsCount===0){return null}const t=this.minYear;const i=this.maxYear;const n=(this.startYear-t)/(i-t)*100;const s=(this.endYear-t)/(i-t)*100;return e("div",{class:"sliderContainer"},e("div",{class:"rangeContainer"},e("div",{class:"activeRange",style:{left:`${n}%`,width:`${s-n}%`}}),e("input",{class:"rangeSlider",max:this.maxYear,min:this.minYear,onInput:this.handleStartYearChange,step:"1",type:"range",value:this.startYear}),e("input",{class:"rangeSlider",max:this.maxYear,min:this.minYear,onInput:this.handleEndYearChange,step:"1",type:"range",value:this.endYear})),e("div",{class:"yearLabels"},e("span",{class:"yearLabel"},this.startYear),e("span",{class:"yearLabel"},this.endYear)))}};W.style=Q;const X=".spinnerContainer{background-color:transparent;height:20px;width:20px}.spinnerDark{animation:spinning 1s linear infinite;background:conic-gradient(#000 50%, #FFFFFF);clip-path:circle(50%);height:100%;mask-image:radial-gradient(circle at center, rgba(0, 0, 0, 0) 6.6666666667px, rgb(0, 0, 0) 6.6666666667px);width:100%}.spinnerLight{animation:spinning 1s linear infinite;background:conic-gradient(#737373 50%, #FFFFFF);clip-path:circle(50%);height:100%;mask-image:radial-gradient(circle at center, rgba(0, 0, 0, 0) 6.6666666667px, rgb(0, 0, 0) 6.6666666667px);width:100%}@keyframes spinning{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}100%{transform:rotate(360deg)}}";const G=X;const tt=class{constructor(i){t(this,i)}render(){return e("div",{key:"fbbd8b46026e1c1c83b59efd68a5cecdca7cad59",class:"spinnerContainer"},e("div",{key:"7fb274ca3ed3d9b69eef7faa77413b1e1fe68ef5",class:"spinnerDark"}))}};tt.style=G;const it=".spinnerContainer{background-color:transparent;height:20px;width:20px}.spinnerLight{animation:spinning 1s linear infinite;background:conic-gradient(#737373 50%, #FFFFFF);clip-path:circle(50%);height:100%;mask-image:radial-gradient(circle at center, rgba(0, 0, 0, 0) 6.6666666667px, rgb(0, 0, 0) 6.6666666667px);width:100%}@keyframes spinning{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}100%{transform:rotate(360deg)}}";const et=it;const nt=class{constructor(i){t(this,i)}render(){return e("div",{key:"5f8d9dbe616324b466436037581491efff818065",class:"spinnerContainer"},e("div",{key:"8152d98d48ac5a4a55c49048a385301238b54932",class:"spinnerLight"}))}};nt.style=et;const st=".toggle-wrapper{background:#ddd;border:none;border-radius:16px;box-shadow:0px 0px 0px 1px rgba(0, 0, 0, 0.05);cursor:pointer;height:26px;margin-left:10px;position:relative;width:44px}.toggle-wrapper.active{background:#007DB3;box-shadow:0px 0px 0px 1px rgba(0, 0, 0, 0.05)}.toggle-wrapper .toggle-switch{background:#fff;border-radius:50%;height:18px;left:4px;position:absolute;top:calc(50% - 9px);transition:transform 0.3s ease;width:18px}.toggle-wrapper .toggle-switch.active{transform:translateX(16px)}";const rt=st;const at=class{constructor(i){t(this,i);this.searchStore=s.getState();this.handleToggle=async()=>{this.isActive=!this.isActive;if(this.type==="mode"){const t=this.isActive?"normal":"fuzzy";this.searchStore.setSearchParams({mode:t})}else if(this.type==="sort"){const t=this.isActive?"desc":"asc";this.searchStore.setSearchParams({sort:t})}try{await this.searchStore.search()}catch(t){console.error("Search failed:",t)}};this.type="mode";this.isActive=false;this.query="";this.resultsCount=0}componentDidLoad(){this.unsubscribe=s.subscribe((t=>{var i,e,n;this.query=t.query||"";this.resultsCount=((n=(e=(i=t.searchResults)===null||i===void 0?void 0:i.data)===null||e===void 0?void 0:e.hits)===null||n===void 0?void 0:n.length)||0}))}disconnectedCallback(){if(this.unsubscribe){this.unsubscribe()}}render(){if(!this.query||this.resultsCount===0){return null}return e("button",{class:`toggle-wrapper ${this.isActive?"active":""}`,onClick:this.handleToggle,type:"button"},e("div",{class:`toggle-switch ${this.isActive?"active":""}`}))}};at.style=rt;export{u as searchcraft_auto_search_form,k as searchcraft_base_search_result,v as searchcraft_base_search_results,w as searchcraft_check_icon,L as searchcraft_clear_icon_set,D as searchcraft_clear_input_button,E as searchcraft_error_message,z as searchcraft_filters_list,A as searchcraft_input,$ as searchcraft_input_caption,O as searchcraft_input_icon,K as searchcraft_input_label,Y as searchcraft_results_info,V as searchcraft_search_icon_set,W as searchcraft_slider,tt as searchcraft_spinner_dark,nt as searchcraft_spinner_light,at as searchcraft_toggle_button};
|
|
2
|
+
//# sourceMappingURL=p-67cc5ccb.entry.js.map
|