@searchcraft/react-sdk 0.5.3 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/index.d.ts +10 -0
- package/dist/index.js +1624 -1119
- package/dist/index.js.map +1 -1
- package/package.json +10 -5
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../javascript-sdk/dist/components/p-e4846fa2.js","../../javascript-sdk/dist/components/p-ad4ebde0.js","../../javascript-sdk/dist/components/p-cbdcf6df.js","../../javascript-sdk/dist/components/searchcraft-base-search-result.js","../../javascript-sdk/dist/components/p-f308d05d.js","../../javascript-sdk/dist/components/p-16983367.js","../../javascript-sdk/dist/components/searchcraft-base-search-results.js","../../javascript-sdk/dist/components/p-5cdc6210.js","../../javascript-sdk/dist/components/p-9cb3d38b.js","../../javascript-sdk/dist/components/searchcraft-button.js","../../javascript-sdk/dist/components/searchcraft-error-message.js","../../javascript-sdk/dist/components/p-42bfef5f.js","../../javascript-sdk/dist/components/searchcraft-facet-list.js","../../javascript-sdk/dist/components/p-5380505b.js","../../javascript-sdk/dist/components/p-a23d2994.js","../../javascript-sdk/dist/components/searchcraft-filter-panel.js","../../javascript-sdk/dist/components/p-bd5fede3.js","../../javascript-sdk/dist/components/searchcraft-input-form.js","../../javascript-sdk/dist/components/searchcraft-input-label.js","../../javascript-sdk/dist/components/searchcraft-results-info.js","../../javascript-sdk/dist/components/searchcraft-slider.js","../../javascript-sdk/dist/components/searchcraft-toggle-button.js","../../../node_modules/@lit/react/create-component.js","../../../node_modules/@stencil/react-output-target/dist/react.js","../src/stencil-web-components/components.ts","../src/components/SearchcraftBaseSearchResult.tsx","../src/components/SearchcraftBaseSearchResults.tsx","../src/components/SearchcraftButton.tsx","../src/components/SearchcraftErrorMessage.tsx","../src/components/SearchcraftFacetList.tsx","../src/components/SearchcraftFilterPanel.tsx","../src/components/SearchcraftInputForm.tsx","../src/components/SearchcraftInputLabel.tsx","../src/components/SearchcraftResultsInfo.tsx","../src/components/SearchcraftSlider.tsx","../src/components/SearchcraftToggleButton.tsx"],"sourcesContent":["const NAMESPACE = 'searchcraft-javascript-sdk';\nconst BUILD = /* searchcraft-javascript-sdk */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: \"hydrated\", invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: false, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: false, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: false, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: true, taskQueue: true, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: true, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };\n\n/*\n Stencil Client Platform v4.22.3 | MIT Licensed | https://stenciljs.com\n */\nvar __defProp = Object.defineProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar hostRefs = /* @__PURE__ */ new WeakMap();\nvar getHostRef = (ref) => hostRefs.get(ref);\nvar registerHost = (hostElement, cmpMeta) => {\n const hostRef = {\n $flags$: 0,\n $hostElement$: hostElement,\n $cmpMeta$: cmpMeta,\n $instanceValues$: /* @__PURE__ */ new Map()\n };\n {\n hostRef.$onReadyPromise$ = new Promise((r) => hostRef.$onReadyResolve$ = r);\n hostElement[\"s-p\"] = [];\n hostElement[\"s-rc\"] = [];\n }\n return hostRefs.set(hostElement, hostRef);\n};\nvar isMemberInElement = (elm, memberName) => memberName in elm;\nvar consoleError = (e, el) => (0, console.error)(e, el);\n\n// src/client/client-style.ts\nvar styles = /* @__PURE__ */ new Map();\nvar SLOT_FB_CSS = \"slot-fb{display:contents}slot-fb[hidden]{display:none}\";\nvar win = typeof window !== \"undefined\" ? window : {};\nvar doc = win.document || { head: {} };\nvar H = win.HTMLElement || class {\n};\nvar plt = {\n $flags$: 0,\n $resourcesUrl$: \"\",\n jmp: (h2) => h2(),\n raf: (h2) => requestAnimationFrame(h2),\n ael: (el, eventName, listener, opts) => el.addEventListener(eventName, listener, opts),\n rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),\n ce: (eventName, opts) => new CustomEvent(eventName, opts)\n};\nvar supportsShadow = BUILD.shadowDom;\nvar promiseResolve = (v) => Promise.resolve(v);\nvar supportsConstructableStylesheets = /* @__PURE__ */ (() => {\n try {\n new CSSStyleSheet();\n return typeof new CSSStyleSheet().replaceSync === \"function\";\n } catch (e) {\n }\n return false;\n})() ;\nvar queuePending = false;\nvar queueDomReads = [];\nvar queueDomWrites = [];\nvar queueTask = (queue, write) => (cb) => {\n queue.push(cb);\n if (!queuePending) {\n queuePending = true;\n if (write && plt.$flags$ & 4 /* queueSync */) {\n nextTick(flush);\n } else {\n plt.raf(flush);\n }\n }\n};\nvar consume = (queue) => {\n for (let i2 = 0; i2 < queue.length; i2++) {\n try {\n queue[i2](performance.now());\n } catch (e) {\n consoleError(e);\n }\n }\n queue.length = 0;\n};\nvar flush = () => {\n consume(queueDomReads);\n {\n consume(queueDomWrites);\n if (queuePending = queueDomReads.length > 0) {\n plt.raf(flush);\n }\n }\n};\nvar nextTick = (cb) => promiseResolve().then(cb);\nvar writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);\n\n// src/runtime/asset-path.ts\nvar getAssetPath = (path) => {\n const assetUrl = new URL(path, plt.$resourcesUrl$);\n return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;\n};\nvar setAssetPath = (path) => plt.$resourcesUrl$ = path;\n\n// src/utils/constants.ts\nvar EMPTY_OBJ = {};\nvar SVG_NS = \"http://www.w3.org/2000/svg\";\nvar HTML_NS = \"http://www.w3.org/1999/xhtml\";\n\n// src/utils/helpers.ts\nvar isDef = (v) => v != null;\nvar isComplexType = (o) => {\n o = typeof o;\n return o === \"object\" || o === \"function\";\n};\n\n// src/utils/query-nonce-meta-tag-content.ts\nfunction queryNonceMetaTagContent(doc2) {\n var _a, _b, _c;\n return (_c = (_b = (_a = doc2.head) == null ? void 0 : _a.querySelector('meta[name=\"csp-nonce\"]')) == null ? void 0 : _b.getAttribute(\"content\")) != null ? _c : void 0;\n}\n\n// src/utils/result.ts\nvar result_exports = {};\n__export(result_exports, {\n err: () => err,\n map: () => map,\n ok: () => ok,\n unwrap: () => unwrap,\n unwrapErr: () => unwrapErr\n});\nvar ok = (value) => ({\n isOk: true,\n isErr: false,\n value\n});\nvar err = (value) => ({\n isOk: false,\n isErr: true,\n value\n});\nfunction map(result, fn) {\n if (result.isOk) {\n const val = fn(result.value);\n if (val instanceof Promise) {\n return val.then((newVal) => ok(newVal));\n } else {\n return ok(val);\n }\n }\n if (result.isErr) {\n const value = result.value;\n return err(value);\n }\n throw \"should never get here\";\n}\nvar unwrap = (result) => {\n if (result.isOk) {\n return result.value;\n } else {\n throw result.value;\n }\n};\nvar unwrapErr = (result) => {\n if (result.isErr) {\n return result.value;\n } else {\n throw result.value;\n }\n};\nvar createTime = (fnName, tagName = \"\") => {\n {\n return () => {\n return;\n };\n }\n};\nvar h = (nodeName, vnodeData, ...children) => {\n let child = null;\n let key = null;\n let slotName = null;\n let simple = false;\n let lastSimple = false;\n const vNodeChildren = [];\n const walk = (c) => {\n for (let i2 = 0; i2 < c.length; i2++) {\n child = c[i2];\n if (Array.isArray(child)) {\n walk(child);\n } else if (child != null && typeof child !== \"boolean\") {\n if (simple = typeof nodeName !== \"function\" && !isComplexType(child)) {\n child = String(child);\n }\n if (simple && lastSimple) {\n vNodeChildren[vNodeChildren.length - 1].$text$ += child;\n } else {\n vNodeChildren.push(simple ? newVNode(null, child) : child);\n }\n lastSimple = simple;\n }\n }\n };\n walk(children);\n if (vnodeData) {\n if (vnodeData.key) {\n key = vnodeData.key;\n }\n if (vnodeData.name) {\n slotName = vnodeData.name;\n }\n {\n const classData = vnodeData.className || vnodeData.class;\n if (classData) {\n vnodeData.class = typeof classData !== \"object\" ? classData : Object.keys(classData).filter((k) => classData[k]).join(\" \");\n }\n }\n }\n if (typeof nodeName === \"function\") {\n return nodeName(\n vnodeData === null ? {} : vnodeData,\n vNodeChildren,\n vdomFnUtils\n );\n }\n const vnode = newVNode(nodeName, null);\n vnode.$attrs$ = vnodeData;\n if (vNodeChildren.length > 0) {\n vnode.$children$ = vNodeChildren;\n }\n {\n vnode.$key$ = key;\n }\n {\n vnode.$name$ = slotName;\n }\n return vnode;\n};\nvar newVNode = (tag, text) => {\n const vnode = {\n $flags$: 0,\n $tag$: tag,\n $text$: text,\n $elm$: null,\n $children$: null\n };\n {\n vnode.$attrs$ = null;\n }\n {\n vnode.$key$ = null;\n }\n {\n vnode.$name$ = null;\n }\n return vnode;\n};\nvar Host = {};\nvar isHost = (node) => node && node.$tag$ === Host;\nvar vdomFnUtils = {\n forEach: (children, cb) => children.map(convertToPublic).forEach(cb),\n map: (children, cb) => children.map(convertToPublic).map(cb).map(convertToPrivate)\n};\nvar convertToPublic = (node) => ({\n vattrs: node.$attrs$,\n vchildren: node.$children$,\n vkey: node.$key$,\n vname: node.$name$,\n vtag: node.$tag$,\n vtext: node.$text$\n});\nvar convertToPrivate = (node) => {\n if (typeof node.vtag === \"function\") {\n const vnodeData = { ...node.vattrs };\n if (node.vkey) {\n vnodeData.key = node.vkey;\n }\n if (node.vname) {\n vnodeData.name = node.vname;\n }\n return h(node.vtag, vnodeData, ...node.vchildren || []);\n }\n const vnode = newVNode(node.vtag, node.vtext);\n vnode.$attrs$ = node.vattrs;\n vnode.$children$ = node.vchildren;\n vnode.$key$ = node.vkey;\n vnode.$name$ = node.vname;\n return vnode;\n};\nvar parsePropertyValue = (propValue, propType) => {\n if (propValue != null && !isComplexType(propValue)) {\n if (propType & 4 /* Boolean */) {\n return propValue === \"false\" ? false : propValue === \"\" || !!propValue;\n }\n if (propType & 2 /* Number */) {\n return parseFloat(propValue);\n }\n if (propType & 1 /* String */) {\n return String(propValue);\n }\n return propValue;\n }\n return propValue;\n};\nvar getElement = (ref) => ref;\n\n// src/runtime/event-emitter.ts\nvar createEvent = (ref, name, flags) => {\n const elm = getElement(ref);\n return {\n emit: (detail) => {\n return emitEvent(elm, name, {\n bubbles: !!(flags & 4 /* Bubbles */),\n composed: !!(flags & 2 /* Composed */),\n cancelable: !!(flags & 1 /* Cancellable */),\n detail\n });\n }\n };\n};\nvar emitEvent = (elm, name, opts) => {\n const ev = plt.ce(name, opts);\n elm.dispatchEvent(ev);\n return ev;\n};\nvar rootAppliedStyles = /* @__PURE__ */ new WeakMap();\nvar registerStyle = (scopeId2, cssText, allowCS) => {\n let style = styles.get(scopeId2);\n if (supportsConstructableStylesheets && allowCS) {\n style = style || new CSSStyleSheet();\n if (typeof style === \"string\") {\n style = cssText;\n } else {\n style.replaceSync(cssText);\n }\n } else {\n style = cssText;\n }\n styles.set(scopeId2, style);\n};\nvar addStyle = (styleContainerNode, cmpMeta, mode) => {\n var _a;\n const scopeId2 = getScopeId(cmpMeta);\n const style = styles.get(scopeId2);\n styleContainerNode = styleContainerNode.nodeType === 11 /* DocumentFragment */ ? styleContainerNode : doc;\n if (style) {\n if (typeof style === \"string\") {\n styleContainerNode = styleContainerNode.head || styleContainerNode;\n let appliedStyles = rootAppliedStyles.get(styleContainerNode);\n let styleElm;\n if (!appliedStyles) {\n rootAppliedStyles.set(styleContainerNode, appliedStyles = /* @__PURE__ */ new Set());\n }\n if (!appliedStyles.has(scopeId2)) {\n {\n styleElm = doc.createElement(\"style\");\n styleElm.innerHTML = style;\n const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);\n if (nonce != null) {\n styleElm.setAttribute(\"nonce\", nonce);\n }\n if (!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */)) {\n if (styleContainerNode.nodeName === \"HEAD\") {\n const preconnectLinks = styleContainerNode.querySelectorAll(\"link[rel=preconnect]\");\n const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector(\"style\");\n styleContainerNode.insertBefore(styleElm, referenceNode2);\n } else if (\"host\" in styleContainerNode) {\n if (supportsConstructableStylesheets) {\n const stylesheet = new CSSStyleSheet();\n stylesheet.replaceSync(style);\n styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];\n } else {\n const existingStyleContainer = styleContainerNode.querySelector(\"style\");\n if (existingStyleContainer) {\n existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;\n } else {\n styleContainerNode.prepend(styleElm);\n }\n }\n } else {\n styleContainerNode.append(styleElm);\n }\n }\n if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */ && styleContainerNode.nodeName !== \"HEAD\") {\n styleContainerNode.insertBefore(styleElm, null);\n }\n }\n if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {\n styleElm.innerHTML += SLOT_FB_CSS;\n }\n if (appliedStyles) {\n appliedStyles.add(scopeId2);\n }\n }\n } else if (!styleContainerNode.adoptedStyleSheets.includes(style)) {\n styleContainerNode.adoptedStyleSheets = [...styleContainerNode.adoptedStyleSheets, style];\n }\n }\n return scopeId2;\n};\nvar attachStyles = (hostRef) => {\n const cmpMeta = hostRef.$cmpMeta$;\n const elm = hostRef.$hostElement$;\n const endAttachStyles = createTime(\"attachStyles\", cmpMeta.$tagName$);\n addStyle(\n elm.getRootNode(),\n cmpMeta);\n endAttachStyles();\n};\nvar getScopeId = (cmp, mode) => \"sc-\" + (cmp.$tagName$);\nvar setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {\n if (oldValue !== newValue) {\n let isProp = isMemberInElement(elm, memberName);\n let ln = memberName.toLowerCase();\n if (memberName === \"class\") {\n const classList = elm.classList;\n const oldClasses = parseClassList(oldValue);\n const newClasses = parseClassList(newValue);\n classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));\n classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));\n } else if (memberName === \"style\") {\n {\n for (const prop in oldValue) {\n if (!newValue || newValue[prop] == null) {\n if (prop.includes(\"-\")) {\n elm.style.removeProperty(prop);\n } else {\n elm.style[prop] = \"\";\n }\n }\n }\n }\n for (const prop in newValue) {\n if (!oldValue || newValue[prop] !== oldValue[prop]) {\n if (prop.includes(\"-\")) {\n elm.style.setProperty(prop, newValue[prop]);\n } else {\n elm.style[prop] = newValue[prop];\n }\n }\n }\n } else if (memberName === \"key\") ; else if ((!elm.__lookupSetter__(memberName)) && memberName[0] === \"o\" && memberName[1] === \"n\") {\n if (memberName[2] === \"-\") {\n memberName = memberName.slice(3);\n } else if (isMemberInElement(win, ln)) {\n memberName = ln.slice(2);\n } else {\n memberName = ln[2] + memberName.slice(3);\n }\n if (oldValue || newValue) {\n const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);\n memberName = memberName.replace(CAPTURE_EVENT_REGEX, \"\");\n if (oldValue) {\n plt.rel(elm, memberName, oldValue, capture);\n }\n if (newValue) {\n plt.ael(elm, memberName, newValue, capture);\n }\n }\n } else {\n const isComplex = isComplexType(newValue);\n if ((isProp || isComplex && newValue !== null) && !isSvg) {\n try {\n if (!elm.tagName.includes(\"-\")) {\n const n = newValue == null ? \"\" : newValue;\n if (memberName === \"list\") {\n isProp = false;\n } else if (oldValue == null || elm[memberName] != n) {\n if (typeof elm.__lookupSetter__(memberName) === \"function\") {\n elm[memberName] = n;\n } else {\n elm.setAttribute(memberName, n);\n }\n }\n } else {\n elm[memberName] = newValue;\n }\n } catch (e) {\n }\n }\n if (newValue == null || newValue === false) {\n if (newValue !== false || elm.getAttribute(memberName) === \"\") {\n {\n elm.removeAttribute(memberName);\n }\n }\n } else if ((!isProp || flags & 4 /* isHost */ || isSvg) && !isComplex) {\n newValue = newValue === true ? \"\" : newValue;\n {\n elm.setAttribute(memberName, newValue);\n }\n }\n }\n }\n};\nvar parseClassListRegex = /\\s/;\nvar parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);\nvar CAPTURE_EVENT_SUFFIX = \"Capture\";\nvar CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + \"$\");\n\n// src/runtime/vdom/update-element.ts\nvar updateElement = (oldVnode, newVnode, isSvgMode2) => {\n const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;\n const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;\n const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;\n {\n for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {\n if (!(memberName in newVnodeAttrs)) {\n setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);\n }\n }\n }\n for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {\n setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);\n }\n};\nfunction sortedAttrNames(attrNames) {\n return attrNames.includes(\"ref\") ? (\n // we need to sort these to ensure that `'ref'` is the last attr\n [...attrNames.filter((attr) => attr !== \"ref\"), \"ref\"]\n ) : (\n // no need to sort, return the original array\n attrNames\n );\n}\n\n// src/runtime/vdom/vdom-render.ts\nvar scopeId;\nvar contentRef;\nvar hostTagName;\nvar useNativeShadowDom = false;\nvar checkSlotFallbackVisibility = false;\nvar checkSlotRelocate = false;\nvar isSvgMode = false;\nvar createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {\n var _a;\n const newVNode2 = newParentVNode.$children$[childIndex];\n let i2 = 0;\n let elm;\n let childNode;\n let oldVNode;\n if (!useNativeShadowDom) {\n checkSlotRelocate = true;\n if (newVNode2.$tag$ === \"slot\") {\n newVNode2.$flags$ |= newVNode2.$children$ ? (\n // slot element has fallback content\n // still create an element that \"mocks\" the slot element\n 2 /* isSlotFallback */\n ) : (\n // slot element does not have fallback content\n // create an html comment we'll use to always reference\n // where actual slot content should sit next to\n 1 /* isSlotReference */\n );\n }\n }\n if (newVNode2.$text$ !== null) {\n elm = newVNode2.$elm$ = doc.createTextNode(newVNode2.$text$);\n } else if (newVNode2.$flags$ & 1 /* isSlotReference */) {\n elm = newVNode2.$elm$ = doc.createTextNode(\"\");\n } else {\n if (!isSvgMode) {\n isSvgMode = newVNode2.$tag$ === \"svg\";\n }\n elm = newVNode2.$elm$ = doc.createElementNS(\n isSvgMode ? SVG_NS : HTML_NS,\n !useNativeShadowDom && BUILD.slotRelocation && newVNode2.$flags$ & 2 /* isSlotFallback */ ? \"slot-fb\" : newVNode2.$tag$\n ) ;\n if (isSvgMode && newVNode2.$tag$ === \"foreignObject\") {\n isSvgMode = false;\n }\n {\n updateElement(null, newVNode2, isSvgMode);\n }\n const rootNode = elm.getRootNode();\n const isElementWithinShadowRoot = !rootNode.querySelector(\"body\");\n if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm[\"s-si\"] !== scopeId) {\n elm.classList.add(elm[\"s-si\"] = scopeId);\n }\n if (newVNode2.$children$) {\n for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {\n childNode = createElm(oldParentVNode, newVNode2, i2);\n if (childNode) {\n elm.appendChild(childNode);\n }\n }\n }\n {\n if (newVNode2.$tag$ === \"svg\") {\n isSvgMode = false;\n } else if (elm.tagName === \"foreignObject\") {\n isSvgMode = true;\n }\n }\n }\n elm[\"s-hn\"] = hostTagName;\n {\n if (newVNode2.$flags$ & (2 /* isSlotFallback */ | 1 /* isSlotReference */)) {\n elm[\"s-sr\"] = true;\n elm[\"s-cr\"] = contentRef;\n elm[\"s-sn\"] = newVNode2.$name$ || \"\";\n elm[\"s-rf\"] = (_a = newVNode2.$attrs$) == null ? void 0 : _a.ref;\n oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];\n if (oldVNode && oldVNode.$tag$ === newVNode2.$tag$ && oldParentVNode.$elm$) {\n {\n putBackInOriginalLocation(oldParentVNode.$elm$, false);\n }\n }\n }\n }\n return elm;\n};\nvar putBackInOriginalLocation = (parentElm, recursive) => {\n plt.$flags$ |= 1 /* isTmpDisconnected */;\n const oldSlotChildNodes = Array.from(parentElm.childNodes);\n if (parentElm[\"s-sr\"] && BUILD.experimentalSlotFixes) {\n let node = parentElm;\n while (node = node.nextSibling) {\n if (node && node[\"s-sn\"] === parentElm[\"s-sn\"] && node[\"s-sh\"] === hostTagName) {\n oldSlotChildNodes.push(node);\n }\n }\n }\n for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {\n const childNode = oldSlotChildNodes[i2];\n if (childNode[\"s-hn\"] !== hostTagName && childNode[\"s-ol\"]) {\n insertBefore(parentReferenceNode(childNode), childNode, referenceNode(childNode));\n childNode[\"s-ol\"].remove();\n childNode[\"s-ol\"] = void 0;\n childNode[\"s-sh\"] = void 0;\n checkSlotRelocate = true;\n }\n if (recursive) {\n putBackInOriginalLocation(childNode, recursive);\n }\n }\n plt.$flags$ &= ~1 /* isTmpDisconnected */;\n};\nvar addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {\n let containerElm = parentElm[\"s-cr\"] && parentElm[\"s-cr\"].parentNode || parentElm;\n let childNode;\n for (; startIdx <= endIdx; ++startIdx) {\n if (vnodes[startIdx]) {\n childNode = createElm(null, parentVNode, startIdx);\n if (childNode) {\n vnodes[startIdx].$elm$ = childNode;\n insertBefore(containerElm, childNode, referenceNode(before) );\n }\n }\n }\n};\nvar removeVnodes = (vnodes, startIdx, endIdx) => {\n for (let index = startIdx; index <= endIdx; ++index) {\n const vnode = vnodes[index];\n if (vnode) {\n const elm = vnode.$elm$;\n if (elm) {\n {\n checkSlotFallbackVisibility = true;\n if (elm[\"s-ol\"]) {\n elm[\"s-ol\"].remove();\n } else {\n putBackInOriginalLocation(elm, true);\n }\n }\n elm.remove();\n }\n }\n }\n};\nvar updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = false) => {\n let oldStartIdx = 0;\n let newStartIdx = 0;\n let idxInOld = 0;\n let i2 = 0;\n let oldEndIdx = oldCh.length - 1;\n let oldStartVnode = oldCh[0];\n let oldEndVnode = oldCh[oldEndIdx];\n let newEndIdx = newCh.length - 1;\n let newStartVnode = newCh[0];\n let newEndVnode = newCh[newEndIdx];\n let node;\n let elmToMove;\n while (oldStartIdx <= oldEndIdx && newStartIdx <= newEndIdx) {\n if (oldStartVnode == null) {\n oldStartVnode = oldCh[++oldStartIdx];\n } else if (oldEndVnode == null) {\n oldEndVnode = oldCh[--oldEndIdx];\n } else if (newStartVnode == null) {\n newStartVnode = newCh[++newStartIdx];\n } else if (newEndVnode == null) {\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldStartVnode, newStartVnode, isInitialRender)) {\n patch(oldStartVnode, newStartVnode, isInitialRender);\n oldStartVnode = oldCh[++oldStartIdx];\n newStartVnode = newCh[++newStartIdx];\n } else if (isSameVnode(oldEndVnode, newEndVnode, isInitialRender)) {\n patch(oldEndVnode, newEndVnode, isInitialRender);\n oldEndVnode = oldCh[--oldEndIdx];\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldStartVnode, newEndVnode, isInitialRender)) {\n if ((oldStartVnode.$tag$ === \"slot\" || newEndVnode.$tag$ === \"slot\")) {\n putBackInOriginalLocation(oldStartVnode.$elm$.parentNode, false);\n }\n patch(oldStartVnode, newEndVnode, isInitialRender);\n insertBefore(parentElm, oldStartVnode.$elm$, oldEndVnode.$elm$.nextSibling);\n oldStartVnode = oldCh[++oldStartIdx];\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldEndVnode, newStartVnode, isInitialRender)) {\n if ((oldStartVnode.$tag$ === \"slot\" || newEndVnode.$tag$ === \"slot\")) {\n putBackInOriginalLocation(oldEndVnode.$elm$.parentNode, false);\n }\n patch(oldEndVnode, newStartVnode, isInitialRender);\n insertBefore(parentElm, oldEndVnode.$elm$, oldStartVnode.$elm$);\n oldEndVnode = oldCh[--oldEndIdx];\n newStartVnode = newCh[++newStartIdx];\n } else {\n idxInOld = -1;\n {\n for (i2 = oldStartIdx; i2 <= oldEndIdx; ++i2) {\n if (oldCh[i2] && oldCh[i2].$key$ !== null && oldCh[i2].$key$ === newStartVnode.$key$) {\n idxInOld = i2;\n break;\n }\n }\n }\n if (idxInOld >= 0) {\n elmToMove = oldCh[idxInOld];\n if (elmToMove.$tag$ !== newStartVnode.$tag$) {\n node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);\n } else {\n patch(elmToMove, newStartVnode, isInitialRender);\n oldCh[idxInOld] = void 0;\n node = elmToMove.$elm$;\n }\n newStartVnode = newCh[++newStartIdx];\n } else {\n node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);\n newStartVnode = newCh[++newStartIdx];\n }\n if (node) {\n {\n insertBefore(parentReferenceNode(oldStartVnode.$elm$), node, referenceNode(oldStartVnode.$elm$));\n }\n }\n }\n }\n if (oldStartIdx > oldEndIdx) {\n addVnodes(\n parentElm,\n newCh[newEndIdx + 1] == null ? null : newCh[newEndIdx + 1].$elm$,\n newVNode2,\n newCh,\n newStartIdx,\n newEndIdx\n );\n } else if (newStartIdx > newEndIdx) {\n removeVnodes(oldCh, oldStartIdx, oldEndIdx);\n }\n};\nvar isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {\n if (leftVNode.$tag$ === rightVNode.$tag$) {\n if (leftVNode.$tag$ === \"slot\") {\n if (\n // The component gets hydrated and no VDOM has been initialized.\n // Here the comparison can't happen as $name$ property is not set for `leftNode`.\n \"$nodeId$\" in leftVNode && isInitialRender && // `leftNode` is not from type HTMLComment which would cause many\n // hydration comments to be removed\n leftVNode.$elm$.nodeType !== 8\n ) {\n return false;\n }\n return leftVNode.$name$ === rightVNode.$name$;\n }\n if (!isInitialRender) {\n return leftVNode.$key$ === rightVNode.$key$;\n }\n return true;\n }\n return false;\n};\nvar referenceNode = (node) => {\n return node && node[\"s-ol\"] || node;\n};\nvar parentReferenceNode = (node) => (node[\"s-ol\"] ? node[\"s-ol\"] : node).parentNode;\nvar patch = (oldVNode, newVNode2, isInitialRender = false) => {\n const elm = newVNode2.$elm$ = oldVNode.$elm$;\n const oldChildren = oldVNode.$children$;\n const newChildren = newVNode2.$children$;\n const tag = newVNode2.$tag$;\n const text = newVNode2.$text$;\n let defaultHolder;\n if (text === null) {\n {\n isSvgMode = tag === \"svg\" ? true : tag === \"foreignObject\" ? false : isSvgMode;\n }\n {\n if (tag === \"slot\" && !useNativeShadowDom) ; else {\n updateElement(oldVNode, newVNode2, isSvgMode);\n }\n }\n if (oldChildren !== null && newChildren !== null) {\n updateChildren(elm, oldChildren, newVNode2, newChildren, isInitialRender);\n } else if (newChildren !== null) {\n if (oldVNode.$text$ !== null) {\n elm.textContent = \"\";\n }\n addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);\n } else if (\n // don't do this on initial render as it can cause non-hydrated content to be removed\n !isInitialRender && BUILD.updatable && oldChildren !== null\n ) {\n removeVnodes(oldChildren, 0, oldChildren.length - 1);\n }\n if (isSvgMode && tag === \"svg\") {\n isSvgMode = false;\n }\n } else if ((defaultHolder = elm[\"s-cr\"])) {\n defaultHolder.parentNode.textContent = text;\n } else if (oldVNode.$text$ !== text) {\n elm.data = text;\n }\n};\nvar updateFallbackSlotVisibility = (elm) => {\n const childNodes = elm.childNodes;\n for (const childNode of childNodes) {\n if (childNode.nodeType === 1 /* ElementNode */) {\n if (childNode[\"s-sr\"]) {\n const slotName = childNode[\"s-sn\"];\n childNode.hidden = false;\n for (const siblingNode of childNodes) {\n if (siblingNode !== childNode) {\n if (siblingNode[\"s-hn\"] !== childNode[\"s-hn\"] || slotName !== \"\") {\n if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute(\"slot\") || slotName === siblingNode[\"s-sn\"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode[\"s-sn\"]) {\n childNode.hidden = true;\n break;\n }\n } else {\n if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== \"\") {\n childNode.hidden = true;\n break;\n }\n }\n }\n }\n }\n updateFallbackSlotVisibility(childNode);\n }\n }\n};\nvar relocateNodes = [];\nvar markSlotContentForRelocation = (elm) => {\n let node;\n let hostContentNodes;\n let j;\n for (const childNode of elm.childNodes) {\n if (childNode[\"s-sr\"] && (node = childNode[\"s-cr\"]) && node.parentNode) {\n hostContentNodes = node.parentNode.childNodes;\n const slotName = childNode[\"s-sn\"];\n for (j = hostContentNodes.length - 1; j >= 0; j--) {\n node = hostContentNodes[j];\n if (!node[\"s-cn\"] && !node[\"s-nr\"] && node[\"s-hn\"] !== childNode[\"s-hn\"] && (!BUILD.experimentalSlotFixes )) {\n if (isNodeLocatedInSlot(node, slotName)) {\n let relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);\n checkSlotFallbackVisibility = true;\n node[\"s-sn\"] = node[\"s-sn\"] || slotName;\n if (relocateNodeData) {\n relocateNodeData.$nodeToRelocate$[\"s-sh\"] = childNode[\"s-hn\"];\n relocateNodeData.$slotRefNode$ = childNode;\n } else {\n node[\"s-sh\"] = childNode[\"s-hn\"];\n relocateNodes.push({\n $slotRefNode$: childNode,\n $nodeToRelocate$: node\n });\n }\n if (node[\"s-sr\"]) {\n relocateNodes.map((relocateNode) => {\n if (isNodeLocatedInSlot(relocateNode.$nodeToRelocate$, node[\"s-sn\"])) {\n relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);\n if (relocateNodeData && !relocateNode.$slotRefNode$) {\n relocateNode.$slotRefNode$ = relocateNodeData.$slotRefNode$;\n }\n }\n });\n }\n } else if (!relocateNodes.some((r) => r.$nodeToRelocate$ === node)) {\n relocateNodes.push({\n $nodeToRelocate$: node\n });\n }\n }\n }\n }\n if (childNode.nodeType === 1 /* ElementNode */) {\n markSlotContentForRelocation(childNode);\n }\n }\n};\nvar isNodeLocatedInSlot = (nodeToRelocate, slotName) => {\n if (nodeToRelocate.nodeType === 1 /* ElementNode */) {\n if (nodeToRelocate.getAttribute(\"slot\") === null && slotName === \"\") {\n return true;\n }\n if (nodeToRelocate.getAttribute(\"slot\") === slotName) {\n return true;\n }\n return false;\n }\n if (nodeToRelocate[\"s-sn\"] === slotName) {\n return true;\n }\n return slotName === \"\";\n};\nvar insertBefore = (parent, newNode, reference) => {\n const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);\n return inserted;\n};\nvar renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {\n var _a, _b, _c, _d;\n const hostElm = hostRef.$hostElement$;\n const oldVNode = hostRef.$vnode$ || newVNode(null, null);\n const rootVnode = isHost(renderFnResults) ? renderFnResults : h(null, null, renderFnResults);\n hostTagName = hostElm.tagName;\n if (isInitialLoad && rootVnode.$attrs$) {\n for (const key of Object.keys(rootVnode.$attrs$)) {\n if (hostElm.hasAttribute(key) && ![\"key\", \"ref\", \"style\", \"class\"].includes(key)) {\n rootVnode.$attrs$[key] = hostElm[key];\n }\n }\n }\n rootVnode.$tag$ = null;\n rootVnode.$flags$ |= 4 /* isHost */;\n hostRef.$vnode$ = rootVnode;\n rootVnode.$elm$ = oldVNode.$elm$ = hostElm;\n useNativeShadowDom = supportsShadow ;\n {\n contentRef = hostElm[\"s-cr\"];\n checkSlotFallbackVisibility = false;\n }\n patch(oldVNode, rootVnode, isInitialLoad);\n {\n plt.$flags$ |= 1 /* isTmpDisconnected */;\n if (checkSlotRelocate) {\n markSlotContentForRelocation(rootVnode.$elm$);\n for (const relocateData of relocateNodes) {\n const nodeToRelocate = relocateData.$nodeToRelocate$;\n if (!nodeToRelocate[\"s-ol\"]) {\n const orgLocationNode = doc.createTextNode(\"\");\n orgLocationNode[\"s-nr\"] = nodeToRelocate;\n insertBefore(nodeToRelocate.parentNode, nodeToRelocate[\"s-ol\"] = orgLocationNode, nodeToRelocate);\n }\n }\n for (const relocateData of relocateNodes) {\n const nodeToRelocate = relocateData.$nodeToRelocate$;\n const slotRefNode = relocateData.$slotRefNode$;\n if (slotRefNode) {\n const parentNodeRef = slotRefNode.parentNode;\n let insertBeforeNode = slotRefNode.nextSibling;\n {\n let orgLocationNode = (_a = nodeToRelocate[\"s-ol\"]) == null ? void 0 : _a.previousSibling;\n while (orgLocationNode) {\n let refNode = (_b = orgLocationNode[\"s-nr\"]) != null ? _b : null;\n if (refNode && refNode[\"s-sn\"] === nodeToRelocate[\"s-sn\"] && parentNodeRef === refNode.parentNode) {\n refNode = refNode.nextSibling;\n while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode[\"s-sr\"])) {\n refNode = refNode == null ? void 0 : refNode.nextSibling;\n }\n if (!refNode || !refNode[\"s-nr\"]) {\n insertBeforeNode = refNode;\n break;\n }\n }\n orgLocationNode = orgLocationNode.previousSibling;\n }\n }\n if (!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode || nodeToRelocate.nextSibling !== insertBeforeNode) {\n if (nodeToRelocate !== insertBeforeNode) {\n if (!nodeToRelocate[\"s-hn\"] && nodeToRelocate[\"s-ol\"]) {\n nodeToRelocate[\"s-hn\"] = nodeToRelocate[\"s-ol\"].parentNode.nodeName;\n }\n insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);\n if (nodeToRelocate.nodeType === 1 /* ElementNode */) {\n nodeToRelocate.hidden = (_c = nodeToRelocate[\"s-ih\"]) != null ? _c : false;\n }\n }\n }\n nodeToRelocate && typeof slotRefNode[\"s-rf\"] === \"function\" && slotRefNode[\"s-rf\"](nodeToRelocate);\n } else {\n if (nodeToRelocate.nodeType === 1 /* ElementNode */) {\n if (isInitialLoad) {\n nodeToRelocate[\"s-ih\"] = (_d = nodeToRelocate.hidden) != null ? _d : false;\n }\n nodeToRelocate.hidden = true;\n }\n }\n }\n }\n if (checkSlotFallbackVisibility) {\n updateFallbackSlotVisibility(rootVnode.$elm$);\n }\n plt.$flags$ &= ~1 /* isTmpDisconnected */;\n relocateNodes.length = 0;\n }\n contentRef = void 0;\n};\n\n// src/runtime/update-component.ts\nvar attachToAncestor = (hostRef, ancestorComponent) => {\n if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent[\"s-p\"]) {\n ancestorComponent[\"s-p\"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));\n }\n};\nvar scheduleUpdate = (hostRef, isInitialLoad) => {\n {\n hostRef.$flags$ |= 16 /* isQueuedForUpdate */;\n }\n if (hostRef.$flags$ & 4 /* isWaitingForChildren */) {\n hostRef.$flags$ |= 512 /* needsRerender */;\n return;\n }\n attachToAncestor(hostRef, hostRef.$ancestorComponent$);\n const dispatch = () => dispatchHooks(hostRef, isInitialLoad);\n return writeTask(dispatch) ;\n};\nvar dispatchHooks = (hostRef, isInitialLoad) => {\n const elm = hostRef.$hostElement$;\n const endSchedule = createTime(\"scheduleUpdate\", hostRef.$cmpMeta$.$tagName$);\n const instance = elm;\n if (!instance) {\n throw new Error(\n `Can't render component <${elm.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \\`externalRuntime: true\\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`\n );\n }\n let maybePromise;\n endSchedule();\n return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));\n};\nvar enqueue = (maybePromise, fn) => isPromisey(maybePromise) ? maybePromise.then(fn).catch((err2) => {\n console.error(err2);\n fn();\n}) : fn();\nvar isPromisey = (maybePromise) => maybePromise instanceof Promise || maybePromise && maybePromise.then && typeof maybePromise.then === \"function\";\nvar updateComponent = async (hostRef, instance, isInitialLoad) => {\n var _a;\n const elm = hostRef.$hostElement$;\n const endUpdate = createTime(\"update\", hostRef.$cmpMeta$.$tagName$);\n const rc = elm[\"s-rc\"];\n if (isInitialLoad) {\n attachStyles(hostRef);\n }\n const endRender = createTime(\"render\", hostRef.$cmpMeta$.$tagName$);\n {\n callRender(hostRef, instance, elm, isInitialLoad);\n }\n if (rc) {\n rc.map((cb) => cb());\n elm[\"s-rc\"] = void 0;\n }\n endRender();\n endUpdate();\n {\n const childrenPromises = (_a = elm[\"s-p\"]) != null ? _a : [];\n const postUpdate = () => postUpdateComponent(hostRef);\n if (childrenPromises.length === 0) {\n postUpdate();\n } else {\n Promise.all(childrenPromises).then(postUpdate);\n hostRef.$flags$ |= 4 /* isWaitingForChildren */;\n childrenPromises.length = 0;\n }\n }\n};\nvar callRender = (hostRef, instance, elm, isInitialLoad) => {\n try {\n instance = instance.render() ;\n {\n hostRef.$flags$ &= ~16 /* isQueuedForUpdate */;\n }\n {\n hostRef.$flags$ |= 2 /* hasRendered */;\n }\n {\n {\n {\n renderVdom(hostRef, instance, isInitialLoad);\n }\n }\n }\n } catch (e) {\n consoleError(e, hostRef.$hostElement$);\n }\n return null;\n};\nvar postUpdateComponent = (hostRef) => {\n const tagName = hostRef.$cmpMeta$.$tagName$;\n const elm = hostRef.$hostElement$;\n const endPostUpdate = createTime(\"postUpdate\", tagName);\n const instance = elm;\n const ancestorComponent = hostRef.$ancestorComponent$;\n if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {\n hostRef.$flags$ |= 64 /* hasLoadedComponent */;\n {\n addHydratedFlag(elm);\n }\n {\n safeCall(instance, \"componentDidLoad\");\n }\n endPostUpdate();\n {\n hostRef.$onReadyResolve$(elm);\n if (!ancestorComponent) {\n appDidLoad();\n }\n }\n } else {\n endPostUpdate();\n }\n {\n if (hostRef.$onRenderResolve$) {\n hostRef.$onRenderResolve$();\n hostRef.$onRenderResolve$ = void 0;\n }\n if (hostRef.$flags$ & 512 /* needsRerender */) {\n nextTick(() => scheduleUpdate(hostRef, false));\n }\n hostRef.$flags$ &= ~(4 /* isWaitingForChildren */ | 512 /* needsRerender */);\n }\n};\nvar appDidLoad = (who) => {\n {\n addHydratedFlag(doc.documentElement);\n }\n nextTick(() => emitEvent(win, \"appload\", { detail: { namespace: NAMESPACE } }));\n};\nvar safeCall = (instance, method, arg) => {\n if (instance && instance[method]) {\n try {\n return instance[method](arg);\n } catch (e) {\n consoleError(e);\n }\n }\n return void 0;\n};\nvar addHydratedFlag = (elm) => {\n var _a;\n return elm.classList.add((_a = BUILD.hydratedSelectorName) != null ? _a : \"hydrated\") ;\n};\n\n// src/runtime/set-value.ts\nvar getValue = (ref, propName) => getHostRef(ref).$instanceValues$.get(propName);\nvar setValue = (ref, propName, newVal, cmpMeta) => {\n const hostRef = getHostRef(ref);\n const elm = ref;\n const oldVal = hostRef.$instanceValues$.get(propName);\n const flags = hostRef.$flags$;\n const instance = elm;\n newVal = parsePropertyValue(newVal, cmpMeta.$members$[propName][0]);\n const areBothNaN = Number.isNaN(oldVal) && Number.isNaN(newVal);\n const didValueChange = newVal !== oldVal && !areBothNaN;\n if (didValueChange) {\n hostRef.$instanceValues$.set(propName, newVal);\n {\n if (cmpMeta.$watchers$ && flags & 128 /* isWatchReady */) {\n const watchMethods = cmpMeta.$watchers$[propName];\n if (watchMethods) {\n watchMethods.map((watchMethodName) => {\n try {\n instance[watchMethodName](newVal, oldVal, propName);\n } catch (e) {\n consoleError(e, elm);\n }\n });\n }\n }\n if ((flags & (2 /* hasRendered */ | 16 /* isQueuedForUpdate */)) === 2 /* hasRendered */) {\n scheduleUpdate(hostRef, false);\n }\n }\n }\n};\n\n// src/runtime/proxy-component.ts\nvar proxyComponent = (Cstr, cmpMeta, flags) => {\n var _a, _b;\n const prototype = Cstr.prototype;\n if (cmpMeta.$members$ || (cmpMeta.$watchers$ || Cstr.watchers)) {\n if (Cstr.watchers && !cmpMeta.$watchers$) {\n cmpMeta.$watchers$ = Cstr.watchers;\n }\n const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});\n members.map(([memberName, [memberFlags]]) => {\n if ((memberFlags & 31 /* Prop */ || memberFlags & 32 /* State */)) {\n Object.defineProperty(prototype, memberName, {\n get() {\n return getValue(this, memberName);\n },\n set(newValue) {\n setValue(this, memberName, newValue, cmpMeta);\n },\n configurable: true,\n enumerable: true\n });\n }\n });\n {\n const attrNameToPropName = /* @__PURE__ */ new Map();\n prototype.attributeChangedCallback = function(attrName, oldValue, newValue) {\n plt.jmp(() => {\n var _a2;\n const propName = attrNameToPropName.get(attrName);\n if (this.hasOwnProperty(propName)) {\n newValue = this[propName];\n delete this[propName];\n } else if (prototype.hasOwnProperty(propName) && typeof this[propName] === \"number\" && // cast type to number to avoid TS compiler issues\n this[propName] == newValue) {\n return;\n } else if (propName == null) {\n const hostRef = getHostRef(this);\n const flags2 = hostRef == null ? void 0 : hostRef.$flags$;\n if (flags2 && !(flags2 & 8 /* isConstructingInstance */) && flags2 & 128 /* isWatchReady */ && newValue !== oldValue) {\n const elm = this;\n const instance = elm;\n const entry = (_a2 = cmpMeta.$watchers$) == null ? void 0 : _a2[attrName];\n entry == null ? void 0 : entry.forEach((callbackName) => {\n if (instance[callbackName] != null) {\n instance[callbackName].call(instance, newValue, oldValue, attrName);\n }\n });\n }\n return;\n }\n this[propName] = newValue === null && typeof this[propName] === \"boolean\" ? false : newValue;\n });\n };\n Cstr.observedAttributes = Array.from(\n /* @__PURE__ */ new Set([\n ...Object.keys((_b = cmpMeta.$watchers$) != null ? _b : {}),\n ...members.filter(([_, m]) => m[0] & 15 /* HasAttribute */).map(([propName, m]) => {\n const attrName = m[1] || propName;\n attrNameToPropName.set(attrName, propName);\n return attrName;\n })\n ])\n );\n }\n }\n return Cstr;\n};\n\n// src/runtime/initialize-component.ts\nvar initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {\n let Cstr;\n if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {\n hostRef.$flags$ |= 32 /* hasInitializedComponent */;\n {\n Cstr = elm.constructor;\n const cmpTag = elm.localName;\n customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);\n }\n if (Cstr && Cstr.style) {\n let style;\n if (typeof Cstr.style === \"string\") {\n style = Cstr.style;\n }\n const scopeId2 = getScopeId(cmpMeta);\n if (!styles.has(scopeId2)) {\n const endRegisterStyles = createTime(\"registerStyles\", cmpMeta.$tagName$);\n registerStyle(scopeId2, style, !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */));\n endRegisterStyles();\n }\n }\n }\n const ancestorComponent = hostRef.$ancestorComponent$;\n const schedule = () => scheduleUpdate(hostRef, true);\n if (ancestorComponent && ancestorComponent[\"s-rc\"]) {\n ancestorComponent[\"s-rc\"].push(schedule);\n } else {\n schedule();\n }\n};\nvar fireConnectedCallback = (instance) => {\n};\n\n// src/runtime/connected-callback.ts\nvar connectedCallback = (elm) => {\n if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {\n const hostRef = getHostRef(elm);\n const cmpMeta = hostRef.$cmpMeta$;\n const endConnected = createTime(\"connectedCallback\", cmpMeta.$tagName$);\n if (!(hostRef.$flags$ & 1 /* hasConnected */)) {\n hostRef.$flags$ |= 1 /* hasConnected */;\n {\n if (// TODO(STENCIL-854): Remove code related to legacy shadowDomShim field\n cmpMeta.$flags$ & (4 /* hasSlotRelocation */ | 8 /* needsShadowDomShim */)) {\n setContentReference(elm);\n }\n }\n {\n let ancestorComponent = elm;\n while (ancestorComponent = ancestorComponent.parentNode || ancestorComponent.host) {\n if (ancestorComponent[\"s-p\"]) {\n attachToAncestor(hostRef, hostRef.$ancestorComponent$ = ancestorComponent);\n break;\n }\n }\n }\n if (cmpMeta.$members$) {\n Object.entries(cmpMeta.$members$).map(([memberName, [memberFlags]]) => {\n if (memberFlags & 31 /* Prop */ && elm.hasOwnProperty(memberName)) {\n const value = elm[memberName];\n delete elm[memberName];\n elm[memberName] = value;\n }\n });\n }\n {\n initializeComponent(elm, hostRef, cmpMeta);\n }\n } else {\n if (hostRef == null ? void 0 : hostRef.$lazyInstance$) ; else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {\n hostRef.$onReadyPromise$.then(() => fireConnectedCallback());\n }\n }\n endConnected();\n }\n};\nvar setContentReference = (elm) => {\n const contentRefElm = elm[\"s-cr\"] = doc.createComment(\n \"\"\n );\n contentRefElm[\"s-cn\"] = true;\n insertBefore(elm, contentRefElm, elm.firstChild);\n};\nvar disconnectedCallback = async (elm) => {\n if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {\n getHostRef(elm);\n }\n};\nvar proxyCustomElement = (Cstr, compactMeta) => {\n const cmpMeta = {\n $flags$: compactMeta[0],\n $tagName$: compactMeta[1]\n };\n {\n cmpMeta.$members$ = compactMeta[2];\n }\n {\n cmpMeta.$watchers$ = Cstr.$watchers$;\n }\n const originalConnectedCallback = Cstr.prototype.connectedCallback;\n const originalDisconnectedCallback = Cstr.prototype.disconnectedCallback;\n let hasHostListenerAttached = false;\n Object.assign(Cstr.prototype, {\n __registerHost() {\n registerHost(this, cmpMeta);\n },\n connectedCallback() {\n if (!hasHostListenerAttached) {\n getHostRef(this);\n hasHostListenerAttached = true;\n }\n connectedCallback(this);\n if (originalConnectedCallback) {\n originalConnectedCallback.call(this);\n }\n },\n disconnectedCallback() {\n disconnectedCallback(this);\n if (originalDisconnectedCallback) {\n originalDisconnectedCallback.call(this);\n }\n },\n __attachShadow() {\n {\n this.shadowRoot = this;\n }\n }\n });\n Cstr.is = cmpMeta.$tagName$;\n return proxyComponent(Cstr, cmpMeta);\n};\n\n// src/runtime/fragment.ts\nvar Fragment = (_, children) => children;\n\n// src/runtime/nonce.ts\nvar setNonce = (nonce) => plt.$nonce$ = nonce;\n\n// src/runtime/platform-options.ts\nvar setPlatformOptions = (opts) => Object.assign(plt, opts);\n\nexport { Fragment as F, H, setNonce as a, setPlatformOptions as b, createEvent as c, getAssetPath as g, h, proxyCustomElement as p, setAssetPath as s };\n\n//# sourceMappingURL=p-e4846fa2.js.map","var zustand = {};\n\nvar vanilla$1 = {};\n\nconst createStoreImpl = (createState) => {\n let state;\n const listeners = /* @__PURE__ */ new Set();\n const setState = (partial, replace) => {\n const nextState = typeof partial === \"function\" ? partial(state) : partial;\n if (!Object.is(nextState, state)) {\n const previousState = state;\n state = (replace != null ? replace : typeof nextState !== \"object\" || nextState === null) ? nextState : Object.assign({}, state, nextState);\n listeners.forEach((listener) => listener(state, previousState));\n }\n };\n const getState = () => state;\n const getInitialState = () => initialState;\n const subscribe = (listener) => {\n listeners.add(listener);\n return () => listeners.delete(listener);\n };\n const api = { setState, getState, getInitialState, subscribe };\n const initialState = state = createState(setState, getState, api);\n return api;\n};\nconst createStore = (createState) => createState ? createStoreImpl(createState) : createStoreImpl;\n\nvanilla$1.createStore = createStore;\n\nvar react$1 = {};\n\nvar react = {exports: {}};\n\nvar react_production_min = {};\n\n/**\n * @license React\n * react.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nvar l$1=Symbol.for(\"react.element\"),n=Symbol.for(\"react.portal\"),p$1=Symbol.for(\"react.fragment\"),q$1=Symbol.for(\"react.strict_mode\"),r=Symbol.for(\"react.profiler\"),t=Symbol.for(\"react.provider\"),u=Symbol.for(\"react.context\"),v$1=Symbol.for(\"react.forward_ref\"),w$1=Symbol.for(\"react.suspense\"),x=Symbol.for(\"react.memo\"),y$1=Symbol.for(\"react.lazy\"),z$1=Symbol.iterator;function A$1(a){if(null===a||\"object\"!==typeof a)return null;a=z$1&&a[z$1]||a[\"@@iterator\"];return \"function\"===typeof a?a:null}\nvar B$1={isMounted:function(){return !1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},C$1=Object.assign,D$1={};function E$1(a,b,e){this.props=a;this.context=b;this.refs=D$1;this.updater=e||B$1;}E$1.prototype.isReactComponent={};\nE$1.prototype.setState=function(a,b){if(\"object\"!==typeof a&&\"function\"!==typeof a&&null!=a)throw Error(\"setState(...): takes an object of state variables to update or a function which returns an object of state variables.\");this.updater.enqueueSetState(this,a,b,\"setState\");};E$1.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,\"forceUpdate\");};function F$1(){}F$1.prototype=E$1.prototype;function G$1(a,b,e){this.props=a;this.context=b;this.refs=D$1;this.updater=e||B$1;}var H$1=G$1.prototype=new F$1;\nH$1.constructor=G$1;C$1(H$1,E$1.prototype);H$1.isPureReactComponent=!0;var I$1=Array.isArray,J$1=Object.prototype.hasOwnProperty,K$1={current:null},L$1={key:!0,ref:!0,__self:!0,__source:!0};\nfunction M$1(a,b,e){var d,c={},k=null,h=null;if(null!=b)for(d in void 0!==b.ref&&(h=b.ref),void 0!==b.key&&(k=\"\"+b.key),b)J$1.call(b,d)&&!L$1.hasOwnProperty(d)&&(c[d]=b[d]);var g=arguments.length-2;if(1===g)c.children=e;else if(1<g){for(var f=Array(g),m=0;m<g;m++)f[m]=arguments[m+2];c.children=f;}if(a&&a.defaultProps)for(d in g=a.defaultProps,g)void 0===c[d]&&(c[d]=g[d]);return {$$typeof:l$1,type:a,key:k,ref:h,props:c,_owner:K$1.current}}\nfunction N$1(a,b){return {$$typeof:l$1,type:a.type,key:b,ref:a.ref,props:a.props,_owner:a._owner}}function O$1(a){return \"object\"===typeof a&&null!==a&&a.$$typeof===l$1}function escape(a){var b={\"=\":\"=0\",\":\":\"=2\"};return \"$\"+a.replace(/[=:]/g,function(a){return b[a]})}var P$1=/\\/+/g;function Q$1(a,b){return \"object\"===typeof a&&null!==a&&null!=a.key?escape(\"\"+a.key):b.toString(36)}\nfunction R(a,b,e,d,c){var k=typeof a;if(\"undefined\"===k||\"boolean\"===k)a=null;var h=!1;if(null===a)h=!0;else switch(k){case \"string\":case \"number\":h=!0;break;case \"object\":switch(a.$$typeof){case l$1:case n:h=!0;}}if(h)return h=a,c=c(h),a=\"\"===d?\".\"+Q$1(h,0):d,I$1(c)?(e=\"\",null!=a&&(e=a.replace(P$1,\"$&/\")+\"/\"),R(c,b,e,\"\",function(a){return a})):null!=c&&(O$1(c)&&(c=N$1(c,e+(!c.key||h&&h.key===c.key?\"\":(\"\"+c.key).replace(P$1,\"$&/\")+\"/\")+a)),b.push(c)),1;h=0;d=\"\"===d?\".\":d+\":\";if(I$1(a))for(var g=0;g<a.length;g++){k=\na[g];var f=d+Q$1(k,g);h+=R(k,b,e,f,c);}else if(f=A$1(a),\"function\"===typeof f)for(a=f.call(a),g=0;!(k=a.next()).done;)k=k.value,f=d+Q$1(k,g++),h+=R(k,b,e,f,c);else if(\"object\"===k)throw b=String(a),Error(\"Objects are not valid as a React child (found: \"+(\"[object Object]\"===b?\"object with keys {\"+Object.keys(a).join(\", \")+\"}\":b)+\"). If you meant to render a collection of children, use an array instead.\");return h}\nfunction S$1(a,b,e){if(null==a)return a;var d=[],c=0;R(a,d,\"\",\"\",function(a){return b.call(e,a,c++)});return d}function T$1(a){if(-1===a._status){var b=a._result;b=b();b.then(function(b){if(0===a._status||-1===a._status)a._status=1,a._result=b;},function(b){if(0===a._status||-1===a._status)a._status=2,a._result=b;});-1===a._status&&(a._status=0,a._result=b);}if(1===a._status)return a._result.default;throw a._result;}\nvar U={current:null},V$1={transition:null},W$1={ReactCurrentDispatcher:U,ReactCurrentBatchConfig:V$1,ReactCurrentOwner:K$1};function X$1(){throw Error(\"act(...) is not supported in production builds of React.\");}\nreact_production_min.Children={map:S$1,forEach:function(a,b,e){S$1(a,function(){b.apply(this,arguments);},e);},count:function(a){var b=0;S$1(a,function(){b++;});return b},toArray:function(a){return S$1(a,function(a){return a})||[]},only:function(a){if(!O$1(a))throw Error(\"React.Children.only expected to receive a single React element child.\");return a}};react_production_min.Component=E$1;react_production_min.Fragment=p$1;react_production_min.Profiler=r;react_production_min.PureComponent=G$1;react_production_min.StrictMode=q$1;react_production_min.Suspense=w$1;\nreact_production_min.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=W$1;react_production_min.act=X$1;\nreact_production_min.cloneElement=function(a,b,e){if(null===a||void 0===a)throw Error(\"React.cloneElement(...): The argument must be a React element, but you passed \"+a+\".\");var d=C$1({},a.props),c=a.key,k=a.ref,h=a._owner;if(null!=b){void 0!==b.ref&&(k=b.ref,h=K$1.current);void 0!==b.key&&(c=\"\"+b.key);if(a.type&&a.type.defaultProps)var g=a.type.defaultProps;for(f in b)J$1.call(b,f)&&!L$1.hasOwnProperty(f)&&(d[f]=void 0===b[f]&&void 0!==g?g[f]:b[f]);}var f=arguments.length-2;if(1===f)d.children=e;else if(1<f){g=Array(f);\nfor(var m=0;m<f;m++)g[m]=arguments[m+2];d.children=g;}return {$$typeof:l$1,type:a.type,key:c,ref:k,props:d,_owner:h}};react_production_min.createContext=function(a){a={$$typeof:u,_currentValue:a,_currentValue2:a,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null};a.Provider={$$typeof:t,_context:a};return a.Consumer=a};react_production_min.createElement=M$1;react_production_min.createFactory=function(a){var b=M$1.bind(null,a);b.type=a;return b};react_production_min.createRef=function(){return {current:null}};\nreact_production_min.forwardRef=function(a){return {$$typeof:v$1,render:a}};react_production_min.isValidElement=O$1;react_production_min.lazy=function(a){return {$$typeof:y$1,_payload:{_status:-1,_result:a},_init:T$1}};react_production_min.memo=function(a,b){return {$$typeof:x,type:a,compare:void 0===b?null:b}};react_production_min.startTransition=function(a){var b=V$1.transition;V$1.transition={};try{a();}finally{V$1.transition=b;}};react_production_min.unstable_act=X$1;react_production_min.useCallback=function(a,b){return U.current.useCallback(a,b)};react_production_min.useContext=function(a){return U.current.useContext(a)};\nreact_production_min.useDebugValue=function(){};react_production_min.useDeferredValue=function(a){return U.current.useDeferredValue(a)};react_production_min.useEffect=function(a,b){return U.current.useEffect(a,b)};react_production_min.useId=function(){return U.current.useId()};react_production_min.useImperativeHandle=function(a,b,e){return U.current.useImperativeHandle(a,b,e)};react_production_min.useInsertionEffect=function(a,b){return U.current.useInsertionEffect(a,b)};react_production_min.useLayoutEffect=function(a,b){return U.current.useLayoutEffect(a,b)};\nreact_production_min.useMemo=function(a,b){return U.current.useMemo(a,b)};react_production_min.useReducer=function(a,b,e){return U.current.useReducer(a,b,e)};react_production_min.useRef=function(a){return U.current.useRef(a)};react_production_min.useState=function(a){return U.current.useState(a)};react_production_min.useSyncExternalStore=function(a,b,e){return U.current.useSyncExternalStore(a,b,e)};react_production_min.useTransition=function(){return U.current.useTransition()};react_production_min.version=\"18.3.1\";\n\n{\n react.exports = react_production_min;\n}\n\nvar React = react.exports;\nvar vanilla = vanilla$1;\n\nconst identity = (arg) => arg;\nfunction useStore(api, selector = identity) {\n const slice = React.useSyncExternalStore(\n api.subscribe,\n () => selector(api.getState()),\n () => selector(api.getInitialState())\n );\n React.useDebugValue(slice);\n return slice;\n}\nconst createImpl = (createState) => {\n const api = vanilla.createStore(createState);\n const useBoundStore = (selector) => useStore(api, selector);\n Object.assign(useBoundStore, api);\n return useBoundStore;\n};\nconst create = (createState) => createState ? createImpl(createState) : createImpl;\n\nreact$1.create = create;\nreact$1.useStore = useStore;\n\n(function (exports) {\n\nvar vanilla = vanilla$1;\nvar react = react$1;\n\n\n\nObject.keys(vanilla).forEach(function (k) {\n\tif (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {\n\t\tenumerable: true,\n\t\tget: function () { return vanilla[k]; }\n\t});\n});\nObject.keys(react).forEach(function (k) {\n\tif (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {\n\t\tenumerable: true,\n\t\tget: function () { return react[k]; }\n\t});\n});\n}(zustand));\n\nvar D = Object.defineProperty;\nvar B = (n, t, r) => t in n ? D(n, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : n[t] = r;\nvar p = (n, t, r) => B(n, typeof t != \"symbol\" ? t + \"\" : t, r);\nconst L = \"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict\";\nlet N = (n = 21) => {\n let t = \"\", r = crypto.getRandomValues(new Uint8Array(n |= 0));\n for (; n--; )\n t += L[r[n] & 63];\n return t;\n};\nfunction w(n, t, r, o) {\n return new (r || (r = Promise))(function(s, i) {\n function e(u) {\n try {\n d(o.next(u));\n } catch (a) {\n i(a);\n }\n }\n function c(u) {\n try {\n d(o.throw(u));\n } catch (a) {\n i(a);\n }\n }\n function d(u) {\n var a;\n u.done ? s(u.value) : (a = u.value, a instanceof r ? a : new r(function(g) {\n g(a);\n })).then(e, c);\n }\n d((o = o.apply(n, [])).next());\n });\n}\nfunction y(n, t) {\n var r, o, s, i, e = { label: 0, sent: function() {\n if (1 & s[0]) throw s[1];\n return s[1];\n }, trys: [], ops: [] };\n return i = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == \"function\" && (i[Symbol.iterator] = function() {\n return this;\n }), i;\n function c(d) {\n return function(u) {\n return function(a) {\n if (r) throw new TypeError(\"Generator is already executing.\");\n for (; i && (i = 0, a[0] && (e = 0)), e; ) try {\n if (r = 1, o && (s = 2 & a[0] ? o.return : a[0] ? o.throw || ((s = o.return) && s.call(o), 0) : o.next) && !(s = s.call(o, a[1])).done) return s;\n switch (o = 0, s && (a = [2 & a[0], s.value]), a[0]) {\n case 0:\n case 1:\n s = a;\n break;\n case 4:\n return e.label++, { value: a[1], done: !1 };\n case 5:\n e.label++, o = a[1], a = [0];\n continue;\n case 7:\n a = e.ops.pop(), e.trys.pop();\n continue;\n default:\n if (s = e.trys, !((s = s.length > 0 && s[s.length - 1]) || a[0] !== 6 && a[0] !== 2)) {\n e = 0;\n continue;\n }\n if (a[0] === 3 && (!s || a[1] > s[0] && a[1] < s[3])) {\n e.label = a[1];\n break;\n }\n if (a[0] === 6 && e.label < s[1]) {\n e.label = s[1], s = a;\n break;\n }\n if (s && e.label < s[2]) {\n e.label = s[2], e.ops.push(a);\n break;\n }\n s[2] && e.ops.pop(), e.trys.pop();\n continue;\n }\n a = t.call(n, e);\n } catch (g) {\n a = [6, g], o = 0;\n } finally {\n r = s = 0;\n }\n if (5 & a[0]) throw a[1];\n return { value: a[0] ? a[1] : void 0, done: !0 };\n }([d, u]);\n };\n }\n}\nvar b = { exclude: [] }, T = {}, j = { timeout: \"true\" }, v = function(n, t) {\n typeof window < \"u\" && (T[n] = t);\n}, q = function() {\n return Object.fromEntries(Object.entries(T).filter(function(n) {\n var t, r = n[0];\n return !(!((t = b == null ? void 0 : b.exclude) === null || t === void 0) && t.includes(r));\n }).map(function(n) {\n return [n[0], (0, n[1])()];\n }));\n};\nfunction M(n) {\n return n ^= n >>> 16, n = Math.imul(n, 2246822507), n ^= n >>> 13, n = Math.imul(n, 3266489909), (n ^= n >>> 16) >>> 0;\n}\nvar f = new Uint32Array([597399067, 2869860233, 951274213, 2716044179]);\nfunction m(n, t) {\n return n << t | n >>> 32 - t;\n}\nfunction I(n, t) {\n var r;\n if (t === void 0 && (t = 0), t = t ? 0 | t : 0, typeof n == \"string\" && (r = n, n = new TextEncoder().encode(r).buffer), !(n instanceof ArrayBuffer)) throw new TypeError(\"Expected key to be ArrayBuffer or string\");\n var o = new Uint32Array([t, t, t, t]);\n ((function(i, e) {\n for (var c = i.byteLength / 16 | 0, d = new Uint32Array(i, 0, 4 * c), u = 0; u < c; u++) {\n var a = d.subarray(4 * u, 4 * (u + 1));\n a[0] = Math.imul(a[0], f[0]), a[0] = m(a[0], 15), a[0] = Math.imul(a[0], f[1]), e[0] = e[0] ^ a[0], e[0] = m(e[0], 19), e[0] = e[0] + e[1], e[0] = Math.imul(e[0], 5) + 1444728091, a[1] = Math.imul(a[1], f[1]), a[1] = m(a[1], 16), a[1] = Math.imul(a[1], f[2]), e[1] = e[1] ^ a[1], e[1] = m(e[1], 17), e[1] = e[1] + e[2], e[1] = Math.imul(e[1], 5) + 197830471, a[2] = Math.imul(a[2], f[2]), a[2] = m(a[2], 17), a[2] = Math.imul(a[2], f[3]), e[2] = e[2] ^ a[2], e[2] = m(e[2], 15), e[2] = e[2] + e[3], e[2] = Math.imul(e[2], 5) + 2530024501, a[3] = Math.imul(a[3], f[3]), a[3] = m(a[3], 18), a[3] = Math.imul(a[3], f[0]), e[3] = e[3] ^ a[3], e[3] = m(e[3], 13), e[3] = e[3] + e[0], e[3] = Math.imul(e[3], 5) + 850148119;\n }\n }))(n, o), function(i, e) {\n var c = i.byteLength / 16 | 0, d = i.byteLength % 16, u = new Uint32Array(4), a = new Uint8Array(i, 16 * c, d);\n switch (d) {\n case 15:\n u[3] = u[3] ^ a[14] << 16;\n case 14:\n u[3] = u[3] ^ a[13] << 8;\n case 13:\n u[3] = u[3] ^ a[12] << 0, u[3] = Math.imul(u[3], f[3]), u[3] = m(u[3], 18), u[3] = Math.imul(u[3], f[0]), e[3] = e[3] ^ u[3];\n case 12:\n u[2] = u[2] ^ a[11] << 24;\n case 11:\n u[2] = u[2] ^ a[10] << 16;\n case 10:\n u[2] = u[2] ^ a[9] << 8;\n case 9:\n u[2] = u[2] ^ a[8] << 0, u[2] = Math.imul(u[2], f[2]), u[2] = m(u[2], 17), u[2] = Math.imul(u[2], f[3]), e[2] = e[2] ^ u[2];\n case 8:\n u[1] = u[1] ^ a[7] << 24;\n case 7:\n u[1] = u[1] ^ a[6] << 16;\n case 6:\n u[1] = u[1] ^ a[5] << 8;\n case 5:\n u[1] = u[1] ^ a[4] << 0, u[1] = Math.imul(u[1], f[1]), u[1] = m(u[1], 16), u[1] = Math.imul(u[1], f[2]), e[1] = e[1] ^ u[1];\n case 4:\n u[0] = u[0] ^ a[3] << 24;\n case 3:\n u[0] = u[0] ^ a[2] << 16;\n case 2:\n u[0] = u[0] ^ a[1] << 8;\n case 1:\n u[0] = u[0] ^ a[0] << 0, u[0] = Math.imul(u[0], f[0]), u[0] = m(u[0], 15), u[0] = Math.imul(u[0], f[1]), e[0] = e[0] ^ u[0];\n }\n }(n, o), function(i, e) {\n e[0] = e[0] ^ i.byteLength, e[1] = e[1] ^ i.byteLength, e[2] = e[2] ^ i.byteLength, e[3] = e[3] ^ i.byteLength, e[0] = e[0] + e[1] | 0, e[0] = e[0] + e[2] | 0, e[0] = e[0] + e[3] | 0, e[1] = e[1] + e[0] | 0, e[2] = e[2] + e[0] | 0, e[3] = e[3] + e[0] | 0, e[0] = M(e[0]), e[1] = M(e[1]), e[2] = M(e[2]), e[3] = M(e[3]), e[0] = e[0] + e[1] | 0, e[0] = e[0] + e[2] | 0, e[0] = e[0] + e[3] | 0, e[1] = e[1] + e[0] | 0, e[2] = e[2] + e[0] | 0, e[3] = e[3] + e[0] | 0;\n }(n, o);\n var s = new Uint8Array(o.buffer);\n return Array.from(s).map(function(i) {\n return i.toString(16).padStart(2, \"0\");\n }).join(\"\");\n}\nfunction G(n, t) {\n return new Promise(function(r) {\n setTimeout(function() {\n return r(t);\n }, n);\n });\n}\nfunction W(n, t, r) {\n return Promise.all(n.map(function(o) {\n return Promise.race([o, G(t, r)]);\n }));\n}\nfunction V() {\n return w(this, void 0, void 0, function() {\n var n, t, r, o, s;\n return y(this, function(i) {\n switch (i.label) {\n case 0:\n return i.trys.push([0, 2, , 3]), n = q(), t = Object.keys(n), [4, W(Object.values(n), (b == null ? void 0 : b.timeout) || 1e3, j)];\n case 1:\n return r = i.sent(), o = r.filter(function(e) {\n return e !== void 0;\n }), s = {}, o.forEach(function(e, c) {\n s[t[c]] = e;\n }), [2, F(s, b.exclude || [])];\n case 2:\n throw i.sent();\n case 3:\n return [2];\n }\n });\n });\n}\nfunction F(n, t) {\n var r = {}, o = function(i) {\n if (n.hasOwnProperty(i)) {\n var e = n[i];\n if (typeof e != \"object\" || Array.isArray(e)) t.includes(i) || (r[i] = e);\n else {\n var c = F(e, t.map(function(d) {\n return d.startsWith(i + \".\") ? d.slice(i.length + 1) : d;\n }));\n Object.keys(c).length > 0 && (r[i] = c);\n }\n }\n };\n for (var s in n) o(s);\n return r;\n}\nfunction H(n) {\n return w(this, void 0, void 0, function() {\n var t, r;\n return y(this, function(o) {\n switch (o.label) {\n case 0:\n return o.trys.push([0, 2, , 3]), [4, V()];\n case 1:\n return t = o.sent(), r = I(JSON.stringify(t)), [2, r.toString()];\n case 2:\n throw o.sent();\n case 3:\n return [2];\n }\n });\n });\n}\nfunction $(n) {\n for (var t = 0, r = 0; r < n.length; ++r) t += Math.abs(n[r]);\n return t;\n}\nfunction _(n, t, r) {\n for (var o = [], s = 0; s < n[0].data.length; s++) {\n for (var i = [], e = 0; e < n.length; e++) i.push(n[e].data[s]);\n o.push(K(i));\n }\n var c = new Uint8ClampedArray(o);\n return new ImageData(c, t, r);\n}\nfunction K(n) {\n if (n.length === 0) return 0;\n for (var t = {}, r = 0, o = n; r < o.length; r++)\n t[i = o[r]] = (t[i] || 0) + 1;\n var s = n[0];\n for (var i in t) t[i] > t[s] && (s = parseInt(i, 10));\n return s;\n}\nfunction E() {\n if (typeof navigator > \"u\") return { name: \"unknown\", version: \"unknown\" };\n for (var n = navigator.userAgent, t = { Edg: \"Edge\", OPR: \"Opera\" }, r = 0, o = [/(?<name>Edge|Edg)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>(?:Chrome|Chromium|OPR|Opera|Vivaldi|Brave))\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>(?:Firefox|Waterfox|Iceweasel|IceCat))\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>Safari)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>MSIE|Trident|IEMobile).+?(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>[A-Za-z]+)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>SamsungBrowser)\\/(?<version>\\d+(?:\\.\\d+)?)/]; r < o.length; r++) {\n var s = o[r], i = n.match(s);\n if (i && i.groups) return { name: t[i.groups.name] || i.groups.name, version: i.groups.version };\n }\n return { name: \"unknown\", version: \"unknown\" };\n}\nv(\"audio\", function() {\n return w(this, void 0, void 0, function() {\n return y(this, function(n) {\n return [2, new Promise(function(t, r) {\n try {\n var o = new (window.OfflineAudioContext || window.webkitOfflineAudioContext)(1, 5e3, 44100), s = o.createBufferSource(), i = o.createOscillator();\n i.frequency.value = 1e3;\n var e, c = o.createDynamicsCompressor();\n c.threshold.value = -50, c.knee.value = 40, c.ratio.value = 12, c.attack.value = 0, c.release.value = 0.2, i.connect(c), c.connect(o.destination), i.start(), o.oncomplete = function(d) {\n e = d.renderedBuffer.getChannelData(0), t({ sampleHash: $(e), oscillator: i.type, maxChannels: o.destination.maxChannelCount, channelCountMode: s.channelCountMode });\n }, o.startRendering();\n } catch (d) {\n console.error(\"Error creating audio fingerprint:\", d), r(d);\n }\n })];\n });\n });\n});\nvar z = E().name !== \"SamsungBrowser\" ? 1 : 3, C = 280, k = 20;\nE().name != \"Firefox\" && v(\"canvas\", function() {\n return document.createElement(\"canvas\").getContext(\"2d\"), new Promise(function(n) {\n var t = Array.from({ length: z }, function() {\n return function() {\n var r = document.createElement(\"canvas\"), o = r.getContext(\"2d\");\n if (!o) return new ImageData(1, 1);\n r.width = C, r.height = k;\n var s = o.createLinearGradient(0, 0, r.width, r.height);\n s.addColorStop(0, \"red\"), s.addColorStop(0.16666666666666666, \"orange\"), s.addColorStop(0.3333333333333333, \"yellow\"), s.addColorStop(0.5, \"green\"), s.addColorStop(0.6666666666666666, \"blue\"), s.addColorStop(0.8333333333333334, \"indigo\"), s.addColorStop(1, \"violet\"), o.fillStyle = s, o.fillRect(0, 0, r.width, r.height);\n var i = \"Random Text WMwmil10Oo\";\n o.font = \"23.123px Arial\", o.fillStyle = \"black\", o.fillText(i, -5, 15), o.fillStyle = \"rgba(0, 0, 255, 0.5)\", o.fillText(i, -3.3, 17.7), o.beginPath(), o.moveTo(0, 0), o.lineTo(2 * r.width / 7, r.height), o.strokeStyle = \"white\", o.lineWidth = 2, o.stroke();\n var e = o.getImageData(0, 0, r.width, r.height);\n return e;\n }();\n });\n n({ commonImageDataHash: I(_(t, C, k).data.toString()).toString() });\n });\n});\nvar A, J = [\"Arial\", \"Arial Black\", \"Arial Narrow\", \"Arial Rounded MT\", \"Arimo\", \"Archivo\", \"Barlow\", \"Bebas Neue\", \"Bitter\", \"Bookman\", \"Calibri\", \"Cabin\", \"Candara\", \"Century\", \"Century Gothic\", \"Comic Sans MS\", \"Constantia\", \"Courier\", \"Courier New\", \"Crimson Text\", \"DM Mono\", \"DM Sans\", \"DM Serif Display\", \"DM Serif Text\", \"Dosis\", \"Droid Sans\", \"Exo\", \"Fira Code\", \"Fira Sans\", \"Franklin Gothic Medium\", \"Garamond\", \"Geneva\", \"Georgia\", \"Gill Sans\", \"Helvetica\", \"Impact\", \"Inconsolata\", \"Indie Flower\", \"Inter\", \"Josefin Sans\", \"Karla\", \"Lato\", \"Lexend\", \"Lucida Bright\", \"Lucida Console\", \"Lucida Sans Unicode\", \"Manrope\", \"Merriweather\", \"Merriweather Sans\", \"Montserrat\", \"Myriad\", \"Noto Sans\", \"Nunito\", \"Nunito Sans\", \"Open Sans\", \"Optima\", \"Orbitron\", \"Oswald\", \"Pacifico\", \"Palatino\", \"Perpetua\", \"PT Sans\", \"PT Serif\", \"Poppins\", \"Prompt\", \"Public Sans\", \"Quicksand\", \"Rajdhani\", \"Recursive\", \"Roboto\", \"Roboto Condensed\", \"Rockwell\", \"Rubik\", \"Segoe Print\", \"Segoe Script\", \"Segoe UI\", \"Sora\", \"Source Sans Pro\", \"Space Mono\", \"Tahoma\", \"Taviraj\", \"Times\", \"Times New Roman\", \"Titillium Web\", \"Trebuchet MS\", \"Ubuntu\", \"Varela Round\", \"Verdana\", \"Work Sans\"], Y = [\"monospace\", \"sans-serif\", \"serif\"];\nfunction P(n, t) {\n if (!n) throw new Error(\"Canvas context not supported\");\n return n.font = \"72px \".concat(t), n.measureText(\"WwMmLli0Oo\").width;\n}\nfunction Q() {\n var n, t = document.createElement(\"canvas\"), r = (n = t.getContext(\"webgl\")) !== null && n !== void 0 ? n : t.getContext(\"experimental-webgl\");\n if (r && \"getParameter\" in r) try {\n var o = (r.getParameter(r.VENDOR) || \"\").toString(), s = (r.getParameter(r.RENDERER) || \"\").toString(), i = { vendor: o, renderer: s, version: (r.getParameter(r.VERSION) || \"\").toString(), shadingLanguageVersion: (r.getParameter(r.SHADING_LANGUAGE_VERSION) || \"\").toString() };\n if (!s.length || !o.length) {\n var e = r.getExtension(\"WEBGL_debug_renderer_info\");\n if (e) {\n var c = (r.getParameter(e.UNMASKED_VENDOR_WEBGL) || \"\").toString(), d = (r.getParameter(e.UNMASKED_RENDERER_WEBGL) || \"\").toString();\n c && (i.vendorUnmasked = c), d && (i.rendererUnmasked = d);\n }\n }\n return i;\n } catch {\n }\n return \"undefined\";\n}\nfunction X() {\n var n = new Float32Array(1), t = new Uint8Array(n.buffer);\n return n[0] = 1 / 0, n[0] = n[0] - n[0], t[3];\n}\nfunction Z(n, t) {\n var r = {};\n return t.forEach(function(o) {\n var s = function(i) {\n if (i.length === 0) return null;\n var e = {};\n i.forEach(function(u) {\n var a = String(u);\n e[a] = (e[a] || 0) + 1;\n });\n var c = i[0], d = 1;\n return Object.keys(e).forEach(function(u) {\n e[u] > d && (c = u, d = e[u]);\n }), c;\n }(n.map(function(i) {\n return o in i ? i[o] : void 0;\n }).filter(function(i) {\n return i !== void 0;\n }));\n s && (r[o] = s);\n }), r;\n}\nfunction ee() {\n var n = [], t = { \"prefers-contrast\": [\"high\", \"more\", \"low\", \"less\", \"forced\", \"no-preference\"], \"any-hover\": [\"hover\", \"none\"], \"any-pointer\": [\"none\", \"coarse\", \"fine\"], pointer: [\"none\", \"coarse\", \"fine\"], hover: [\"hover\", \"none\"], update: [\"fast\", \"slow\"], \"inverted-colors\": [\"inverted\", \"none\"], \"prefers-reduced-motion\": [\"reduce\", \"no-preference\"], \"prefers-reduced-transparency\": [\"reduce\", \"no-preference\"], scripting: [\"none\", \"initial-only\", \"enabled\"], \"forced-colors\": [\"active\", \"none\"] };\n return Object.keys(t).forEach(function(r) {\n t[r].forEach(function(o) {\n matchMedia(\"(\".concat(r, \": \").concat(o, \")\")).matches && n.push(\"\".concat(r, \": \").concat(o));\n });\n }), n;\n}\nfunction te() {\n if (window.location.protocol === \"https:\" && typeof window.ApplePaySession == \"function\") try {\n for (var n = window.ApplePaySession.supportsVersion, t = 15; t > 0; t--) if (n(t)) return t;\n } catch {\n return 0;\n }\n return 0;\n}\nE().name != \"Firefox\" && v(\"fonts\", function() {\n var n = this;\n return new Promise(function(t, r) {\n try {\n (function(o) {\n var s;\n w(this, void 0, void 0, function() {\n var i, e, c;\n return y(this, function(d) {\n switch (d.label) {\n case 0:\n return document.body ? [3, 2] : [4, (u = 50, new Promise(function(g) {\n return setTimeout(g, u, a);\n }))];\n case 1:\n return d.sent(), [3, 0];\n case 2:\n if ((i = document.createElement(\"iframe\")).setAttribute(\"frameBorder\", \"0\"), (e = i.style).setProperty(\"position\", \"fixed\"), e.setProperty(\"display\", \"block\", \"important\"), e.setProperty(\"visibility\", \"visible\"), e.setProperty(\"border\", \"0\"), e.setProperty(\"opacity\", \"0\"), i.src = \"about:blank\", document.body.appendChild(i), !(c = i.contentDocument || ((s = i.contentWindow) === null || s === void 0 ? void 0 : s.document))) throw new Error(\"Iframe document is not accessible\");\n return o({ iframe: c }), setTimeout(function() {\n document.body.removeChild(i);\n }, 0), [2];\n }\n var u, a;\n });\n });\n })(function(o) {\n var s = o.iframe;\n return w(n, void 0, void 0, function() {\n var i, e, c, d;\n return y(this, function(u) {\n return i = s.createElement(\"canvas\"), e = i.getContext(\"2d\"), c = Y.map(function(a) {\n return P(e, a);\n }), d = {}, J.forEach(function(a) {\n var g = P(e, a);\n c.includes(g) || (d[a] = g);\n }), t(d), [2];\n });\n });\n });\n } catch {\n r({ error: \"unsupported\" });\n }\n });\n}), v(\"hardware\", function() {\n return new Promise(function(n, t) {\n var r = navigator.deviceMemory !== void 0 ? navigator.deviceMemory : 0, o = window.performance && window.performance.memory ? window.performance.memory : 0;\n n({ videocard: Q(), architecture: X(), deviceMemory: r.toString() || \"undefined\", jsHeapSizeLimit: o.jsHeapSizeLimit || 0 });\n });\n}), v(\"locales\", function() {\n return new Promise(function(n) {\n n({ languages: navigator.language, timezone: Intl.DateTimeFormat().resolvedOptions().timeZone });\n });\n}), v(\"permissions\", function() {\n return w(this, void 0, void 0, function() {\n var n;\n return y(this, function(t) {\n return A = (b == null ? void 0 : b.permissions_to_check) || [\"accelerometer\", \"accessibility\", \"accessibility-events\", \"ambient-light-sensor\", \"background-fetch\", \"background-sync\", \"bluetooth\", \"camera\", \"clipboard-read\", \"clipboard-write\", \"device-info\", \"display-capture\", \"gyroscope\", \"geolocation\", \"local-fonts\", \"magnetometer\", \"microphone\", \"midi\", \"nfc\", \"notifications\", \"payment-handler\", \"persistent-storage\", \"push\", \"speaker\", \"storage-access\", \"top-level-storage-access\", \"window-management\", \"query\"], n = Array.from({ length: (b == null ? void 0 : b.retries) || 3 }, function() {\n return function() {\n return w(this, void 0, void 0, function() {\n var r, o, s, i, e;\n return y(this, function(c) {\n switch (c.label) {\n case 0:\n r = {}, o = 0, s = A, c.label = 1;\n case 1:\n if (!(o < s.length)) return [3, 6];\n i = s[o], c.label = 2;\n case 2:\n return c.trys.push([2, 4, , 5]), [4, navigator.permissions.query({ name: i })];\n case 3:\n return e = c.sent(), r[i] = e.state.toString(), [3, 5];\n case 4:\n return c.sent(), [3, 5];\n case 5:\n return o++, [3, 1];\n case 6:\n return [2, r];\n }\n });\n });\n }();\n }), [2, Promise.all(n).then(function(r) {\n return Z(r, A);\n })];\n });\n });\n}), v(\"plugins\", function() {\n var n = [];\n if (navigator.plugins) for (var t = 0; t < navigator.plugins.length; t++) {\n var r = navigator.plugins[t];\n n.push([r.name, r.filename, r.description].join(\"|\"));\n }\n return new Promise(function(o) {\n o({ plugins: n });\n });\n}), v(\"screen\", function() {\n return new Promise(function(n) {\n n({ is_touchscreen: navigator.maxTouchPoints > 0, maxTouchPoints: navigator.maxTouchPoints, colorDepth: screen.colorDepth, mediaMatches: ee() });\n });\n}), v(\"system\", function() {\n return new Promise(function(n) {\n var t = E();\n n({ platform: window.navigator.platform, cookieEnabled: window.navigator.cookieEnabled, productSub: navigator.productSub, product: navigator.product, useragent: navigator.userAgent, hardwareConcurrency: navigator.hardwareConcurrency, browser: { name: t.name, version: t.version }, applePayVersion: te() });\n });\n});\nvar h, ne = E().name !== \"SamsungBrowser\" ? 1 : 3, l = null;\nv(\"webgl\", function() {\n return w(this, void 0, void 0, function() {\n var n;\n return y(this, function(t) {\n typeof document < \"u\" && ((h = document.createElement(\"canvas\")).width = 200, h.height = 100, l = h.getContext(\"webgl\"));\n try {\n if (!l) throw new Error(\"WebGL not supported\");\n return n = Array.from({ length: ne }, function() {\n return function() {\n try {\n if (!l) throw new Error(\"WebGL not supported\");\n var r = `\n attribute vec2 position;\n void main() {\n gl_Position = vec4(position, 0.0, 1.0);\n }\n `, o = `\n precision mediump float;\n void main() {\n gl_FragColor = vec4(0.812, 0.195, 0.553, 0.921); // Set line color\n }\n `, s = l.createShader(l.VERTEX_SHADER), i = l.createShader(l.FRAGMENT_SHADER);\n if (!s || !i) throw new Error(\"Failed to create shaders\");\n if (l.shaderSource(s, r), l.shaderSource(i, o), l.compileShader(s), !l.getShaderParameter(s, l.COMPILE_STATUS)) throw new Error(\"Vertex shader compilation failed: \" + l.getShaderInfoLog(s));\n if (l.compileShader(i), !l.getShaderParameter(i, l.COMPILE_STATUS)) throw new Error(\"Fragment shader compilation failed: \" + l.getShaderInfoLog(i));\n var e = l.createProgram();\n if (!e) throw new Error(\"Failed to create shader program\");\n if (l.attachShader(e, s), l.attachShader(e, i), l.linkProgram(e), !l.getProgramParameter(e, l.LINK_STATUS)) throw new Error(\"Shader program linking failed: \" + l.getProgramInfoLog(e));\n l.useProgram(e);\n for (var c = 137, d = new Float32Array(4 * c), u = 2 * Math.PI / c, a = 0; a < c; a++) {\n var g = a * u;\n d[4 * a] = 0, d[4 * a + 1] = 0, d[4 * a + 2] = Math.cos(g) * (h.width / 2), d[4 * a + 3] = Math.sin(g) * (h.height / 2);\n }\n var U = l.createBuffer();\n l.bindBuffer(l.ARRAY_BUFFER, U), l.bufferData(l.ARRAY_BUFFER, d, l.STATIC_DRAW);\n var x = l.getAttribLocation(e, \"position\");\n l.enableVertexAttribArray(x), l.vertexAttribPointer(x, 2, l.FLOAT, !1, 0, 0), l.viewport(0, 0, h.width, h.height), l.clearColor(0, 0, 0, 1), l.clear(l.COLOR_BUFFER_BIT), l.drawArrays(l.LINES, 0, 2 * c);\n var R = new Uint8ClampedArray(h.width * h.height * 4);\n return l.readPixels(0, 0, h.width, h.height, l.RGBA, l.UNSIGNED_BYTE, R), new ImageData(R, h.width, h.height);\n } catch {\n return new ImageData(1, 1);\n } finally {\n l && (l.bindBuffer(l.ARRAY_BUFFER, null), l.useProgram(null), l.viewport(0, 0, l.drawingBufferWidth, l.drawingBufferHeight), l.clearColor(0, 0, 0, 0));\n }\n }();\n }), [2, { commonImageHash: I(_(n, h.width, h.height).data.toString()).toString() }];\n } catch {\n return [2, { webgl: \"unsupported\" }];\n }\n return [2];\n });\n });\n});\nvar S = function(n, t, r, o) {\n for (var s = (r - t) / o, i = 0, e = 0; e < o; e++)\n i += n(t + (e + 0.5) * s);\n return i * s;\n};\nv(\"math\", function() {\n return w(void 0, void 0, void 0, function() {\n return y(this, function(n) {\n return [2, { acos: Math.acos(0.5), asin: S(Math.asin, -1, 1, 97), atan: S(Math.atan, -1, 1, 97), cos: S(Math.cos, 0, Math.PI, 97), cosh: Math.cosh(9 / 7), e: Math.E, largeCos: Math.cos(1e20), largeSin: Math.sin(1e20), largeTan: Math.tan(1e20), log: Math.log(1e3), pi: Math.PI, sin: S(Math.sin, -Math.PI, Math.PI, 97), sinh: S(Math.sinh, -9 / 7, 7 / 9, 97), sqrt: Math.sqrt(2), tan: S(Math.tan, 0, 2 * Math.PI, 97), tanh: S(Math.tanh, -9 / 7, 7 / 9, 97) }];\n });\n });\n});\nclass ie {\n constructor(t, r) {\n p(this, \"config\");\n p(this, \"sdkInfo\");\n p(this, \"userId\");\n p(this, \"sessionId\");\n /**\n * Performs a search operation.\n * @param {SearchParams} searchParams - The parameters for the search.\n * @returns {Promise<SearchcraftResponse>} - Returns the search response or throws an error.\n */\n p(this, \"search\", async (t) => {\n if (this.sendMeasureEvent(\"search_requested\", {\n search_term: t.query\n }), (t.query.match(/\"/g) || []).length % 2 !== 0)\n throw new Error(\n \"The search term contains an uneven number of quote characters.\"\n );\n try {\n const o = {\n query: this.buildQueryObject(t),\n limit: t.limit ?? 20\n // Default to 20 if not provided\n };\n t.offset !== void 0 && (o.offset = t.offset), t.order_by && (o.order_by = t.order_by, o.sort = t.sort === \"desc\" || t.sort === \"asc\" ? t.sort : \"asc\");\n const s = {\n method: \"POST\",\n headers: {\n Authorization: this.config.readKey,\n \"Content-Type\": \"application/json\",\n \"X-Sc-User-Id\": this.userId\n },\n body: JSON.stringify(o)\n }, i = await fetch(this.baseSearchUrl, s);\n if (!i.ok)\n throw new Error(\n `Error: ${i.statusText} (Status: ${i.status})`\n );\n const e = await i.json();\n return this.sendMeasureEvent(\"search_response_received\", {\n search_term: t.query,\n number_of_documents: e.data.count\n }), e;\n } catch (o) {\n throw console.error(\"Error parsing response:\", o), o;\n }\n });\n /**\n * Sends a measure event to the `/measure/event` endpoint for analytics purposes.\n *\n * @param {MeasureEventName} eventName - Name of the event.\n * @param {Partial<MeasureRequestProperties>} properties - Additional properties to send with the event.\n * @param {Partial<MeasureRequestUser>} user - Additional user properites to send with the event.\n */\n p(this, \"sendMeasureEvent\", async (t, r = {}, o = {}) => {\n const s = {\n event_name: t,\n properties: {\n searchcraft_index_names: this.config.index,\n ...r\n },\n user: {\n ...this.measureRequestUser,\n ...o\n }\n }, i = JSON.stringify(s), e = `${this.baseMeasureUrl}/event`;\n try {\n const c = await fetch(e, {\n method: \"POST\",\n headers: {\n \"Content-Type\": \"application/json\",\n Authorization: this.config.readKey,\n \"X-Sc-User-Id\": this.userId\n },\n body: i,\n keepalive: !0\n });\n if (!c.ok)\n throw new Error(\n `Failed to send request: ${c.status} ${c.statusText}`\n );\n return;\n } catch (c) {\n throw console.error(\"Error sending MeasureRequest:\", c), c;\n }\n });\n if (!t.endpointURL || !t.index || !t.readKey)\n throw new Error(\n \"Endpoint URL, Index value(s), and Read Key must be provided\"\n );\n this.config = t, this.sdkInfo = r, this.userId = t.userId || \"\", this.sessionId = \"\", setTimeout(() => {\n this.sessionId = N(), this.initMeasure();\n }, 300);\n }\n /**\n * Initializes this.userId based on config & sends the `sdk_innitialized` event.\n */\n async initMeasure() {\n if (!this.config.userId) {\n const t = await H();\n this.userId = t;\n }\n this.sendMeasureEvent(\"sdk_initialized\");\n }\n /**\n * Getter for the base url used by the /search endpoint.\n */\n get baseSearchUrl() {\n return `${this.config.endpointURL}/index/${this.config.index.join(\",\")}/search`;\n }\n /**\n * Getter for the base url used by the /measure endpoints.\n */\n get baseMeasureUrl() {\n return `${this.config.endpointURL}/measure`;\n }\n /**\n * Getter for the measure request user. Uses config values + navigator values.\n */\n get measureRequestUser() {\n return {\n user_id: this.userId,\n locale: navigator.language || \"en-US\",\n os: navigator.userAgent.includes(\"Windows\") ? \"Windows\" : navigator.userAgent.includes(\"Mac\") ? \"Mac\" : navigator.userAgent.includes(\"Linux\") ? \"Linux\" : \"Unknown\",\n platform: navigator.platform || \"Unknown\",\n sdk_name: this.sdkInfo.sdkName,\n sdk_version: this.sdkInfo.sdkVersion,\n user_agent: navigator.userAgent || \"Unknown\"\n };\n }\n /**\n * Builds a query object for the search request.\n * @param {SearchParams} searchParams - The parameters for the search.\n * @returns {QueryObject} - A properly formatted query object.\n */\n buildQueryObject(t) {\n const r = [];\n let o = \"should\";\n return t.facetPathsForIndexFields && Object.keys(t.facetPathsForIndexFields).forEach(\n (s) => {\n var e;\n const i = (e = t.facetPathsForIndexFields) == null ? void 0 : e[s];\n i && (o = \"must\", r.push({\n occur: o,\n normal: {\n ctx: i.value\n }\n }));\n }\n ), t.rangeValueForIndexFields && Object.keys(t.rangeValueForIndexFields).forEach(\n (s) => {\n var e;\n const i = (e = t.rangeValueForIndexFields) == null ? void 0 : e[s];\n i && (o = \"must\", r.push({\n occur: o,\n normal: {\n ctx: i.value\n }\n }));\n }\n ), t.sort === \"desc\" ? t.order_by = \"date_published\" : t.order_by = \"\", r.push({\n occur: o,\n // Valid, as 'occur' is a required property in QueryItem\n [t.mode]: { ctx: t.query }\n // Ensure dynamic mode is inside queryType\n }), r;\n }\n}\nvar O = /* @__PURE__ */ ((n) => (n[n.DEBUG = 0] = \"DEBUG\", n[n.INFO = 1] = \"INFO\", n[n.WARN = 2] = \"WARN\", n[n.ERROR = 3] = \"ERROR\", n))(O || {});\nclass ae {\n constructor(t) {\n p(this, \"logLevel\");\n p(this, \"logFormatter\");\n this.logLevel = t.logLevel || 1, this.logFormatter = t.logFormatter || this.defaultFormatter;\n }\n defaultFormatter(t, r) {\n return `[${O[t]}] ${( new Date()).toISOString()}: ${r}`;\n }\n debug(t) {\n this.logLevel <= 0 && console.log(this.logFormatter(0, t));\n }\n info(t) {\n this.logLevel <= 1 && console.info(this.logFormatter(1, t));\n }\n warn(t) {\n this.logLevel <= 2 && console.warn(this.logFormatter(2, t));\n }\n error(t) {\n this.logLevel <= 3 && console.error(this.logFormatter(3, t));\n }\n}\n\n// Zustand store for Searchcraft state\nconst useSearchcraftStore = zustand.create((set, get) => {\n let searchcraft = null;\n let debuggerInstance = null;\n const log = (level, message) => {\n if (debuggerInstance) {\n switch (level) {\n case O.DEBUG:\n debuggerInstance.debug(message);\n break;\n case O.INFO:\n debuggerInstance.info(message);\n break;\n case O.WARN:\n debuggerInstance.warn(message);\n break;\n case O.ERROR:\n debuggerInstance.error(message);\n break;\n }\n }\n };\n return {\n resetFacetPaths: () => {\n set({\n facetPathsForIndexFields: {},\n });\n },\n addFacetPathsForIndexField: (data) => set((state) => ({\n facetPathsForIndexFields: Object.assign(Object.assign({}, state.facetPathsForIndexFields), { [data.fieldName]: data }),\n })),\n removeFacetPathsForIndexField: (fieldName) => set((state) => {\n const currentPaths = state.facetPathsForIndexFields;\n delete currentPaths[fieldName];\n return {\n facetPathsForIndexFields: Object.assign({}, currentPaths),\n };\n }),\n addRangeValueForIndexField: (data) => set((state) => ({\n rangeValueForIndexFields: Object.assign(Object.assign({}, state.rangeValueForIndexFields), { [data.fieldName]: data }),\n })),\n removeRangeValueForIndexField: (fieldName) => set((state) => {\n const currentValues = state.rangeValueForIndexFields;\n delete currentValues[fieldName];\n return {\n rangeValueForIndexFields: Object.assign({}, currentValues),\n };\n }),\n setSearchMode: (mode) => set({ searchMode: mode }),\n setSortType: (type) => set({ sortType: type }),\n searchMode: 'fuzzy',\n sortType: 'asc',\n facetPathsForIndexFields: {},\n rangeValueForIndexFields: {},\n query: '',\n isRequesting: false,\n searchResults: null,\n facets: null,\n getSearchcraftInstance: () => searchcraft,\n setQuery: (query) => {\n /**\n * When a new query is set, also reset the sort type, search mode, and facet paths.\n */\n set(Object.assign({ query, facetPathsForIndexFields: {} }, (query.trim().length === 0 && {\n searchMode: 'fuzzy',\n sortType: 'asc',\n })));\n },\n setSearchResults: (results) => set({ searchResults: results }),\n setFacets: (facets) => set({ facets }),\n setIsRequesting: (isRequesting) => set({ isRequesting }),\n search: async () => {\n const state = get();\n log(O.INFO, `Starting search with search term: \"${state.query}\"`);\n if (!searchcraft) {\n throw new Error('Searchcraft instance is not initialized.');\n }\n if (!state.query.trim()) {\n log(O.INFO, 'No search request was made: search term was empty.');\n state.setSearchResults(null);\n return;\n }\n state.setIsRequesting(true);\n try {\n const results = await searchcraft.search({\n query: state.query,\n mode: state.searchMode,\n sort: state.sortType,\n facetPathsForIndexFields: state.facetPathsForIndexFields,\n rangeValueForIndexFields: state.rangeValueForIndexFields,\n });\n const updatedFacets = results.data.facets || null;\n state.setSearchResults(results);\n state.setFacets(updatedFacets);\n log(O.DEBUG, `Search results: ${JSON.stringify(results)}`);\n log(O.DEBUG, `Updated facets: ${JSON.stringify(updatedFacets)}`);\n }\n catch (error) {\n console.error(`Search failed: ${error.message}`);\n log(O.ERROR, `Search failed with error: ${error.message}`);\n }\n finally {\n state.setIsRequesting(false);\n }\n },\n initialize: (searchcraftInstance, debug = false) => {\n searchcraft = searchcraftInstance;\n debuggerInstance = debug\n ? new ae({ logLevel: O.DEBUG })\n : null;\n log(O.INFO, 'Searchcraft store initialized.');\n },\n };\n});\nconst useThemeStore = zustand.create((set) => ({\n theme: 'light',\n toggleTheme: () => set((state) => ({ theme: state.theme === 'light' ? 'dark' : 'light' })),\n}));\n\nexport { useThemeStore as a, ie as i, useSearchcraftStore as u };\n\n//# sourceMappingURL=p-ad4ebde0.js.map","import { p as proxyCustomElement, H, h, F as Fragment } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\n\nconst searchcraftBaseSearchResultModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-search-result-container{all:unset;align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;color:inherit;background-color:var(--sc-surface-neutral-primary)}@media (min-width: 900px){.searchcraft-search-result-container{flex-direction:row}}a.searchcraft-search-result-container{cursor:pointer;transition:background-color 100ms}.searchcraft-base-search-result-content-container{flex:1;display:flex;flex-direction:column;gap:8px}.searchcraft-search-result-image{border-radius:var(--sc-image-border-radius);width:100%}@media (min-width: 900px){.searchcraft-search-result-image{width:200px}}.searchcraft-base-search-result-title{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-bold-font-size);font-weight:var(--sc-body-bold-font-weight);line-height:var(--sc-body-bold-line-height);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-base-search-result-subtitle{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);margin:0;color:var(--sc-content-disabled)}.searchcraft-base-search-result-body-content{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-base-search-result-footer-content{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-disabled)}\";\nconst SearchcraftBaseSearchResultStyle0 = searchcraftBaseSearchResultModuleCss;\n\nconst SearchcraftBaseSearchResult = /*@__PURE__*/ proxyCustomElement(class SearchcraftBaseSearchResult extends H {\n constructor() {\n super();\n this.__registerHost();\n this.searchcraftStore = useSearchcraftStore.getState();\n this.recordMeasureEvent = () => {\n var _a, _b, _c;\n const searchcraft = this.searchcraftStore.getSearchcraftInstance();\n if (searchcraft) {\n const document_position = this.documentPosition;\n const search_term = this.searchcraftStore.query;\n const number_of_documents = ((_c = (_b = (_a = this.searchcraftStore.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;\n searchcraft.sendMeasureEvent('document_clicked', {\n document_position,\n number_of_documents,\n search_term,\n });\n }\n };\n this.parseStyles = () => {\n if (this.customStyles) {\n try {\n return JSON.parse(this.customStyles);\n }\n catch (error) {\n console.error('Error parsing custom styles:', error);\n return {};\n }\n }\n return {};\n };\n this.titleContent = undefined;\n this.subtitleContent = undefined;\n this.bodyContent = undefined;\n this.footerContent = undefined;\n this.buttonLabel = undefined;\n this.buttonHref = undefined;\n this.buttonTarget = '_blank';\n this.buttonRel = undefined;\n this.containerHref = undefined;\n this.containerTarget = '_blank';\n this.containerRel = undefined;\n this.imageSrc = undefined;\n this.imageAlt = undefined;\n this.imagePlacement = undefined;\n this.customStyles = undefined;\n this.documentPosition = 0;\n }\n render() {\n const styles = this.parseStyles();\n const imageContainer = this.imageSrc && (h(\"img\", { alt: this.imageAlt, class: 'searchcraft-search-result-image', src: this.imageSrc, style: styles.image || {} }));\n const contentContainer = (h(Fragment, null, this.imageSrc && this.imagePlacement === 'left' && imageContainer, h(\"div\", { class: 'searchcraft-base-search-result-content-container' }, this.titleContent && (h(\"h2\", { class: 'searchcraft-base-search-result-title', style: styles.title || {} }, this.titleContent)), this.subtitleContent && (h(\"h3\", { class: 'searchcraft-base-search-result-subtitle', style: styles.subtitle || {} }, this.subtitleContent)), this.bodyContent && (h(\"p\", { class: 'searchcraft-base-search-result-body-content', style: styles.primaryContent || {} }, this.bodyContent)), this.footerContent && (h(\"p\", { class: 'searchcraft-base-search-result-footer-content', style: styles.secondaryContent || {} }, this.footerContent)), this.buttonHref && !this.containerHref && this.buttonLabel && (h(\"a\", { class: 'searchcraft-search-result-button', href: this.buttonHref, style: styles.button || {}, target: this.buttonTarget, rel: this.buttonRel }, this.buttonLabel))), this.imageSrc && this.imagePlacement === 'right' && imageContainer));\n /** Render as an anchor tag if the containerHref prop is present. */\n if (this.containerHref) {\n return (h(\"a\", { class: 'searchcraft-search-result-container', onClick: this.recordMeasureEvent, href: this.containerHref, rel: this.containerRel, style: styles.container || {}, tabindex: '0', target: this.containerTarget }, contentContainer));\n }\n /** Render as a div if no href prop. */\n return (h(\"div\", { class: 'searchcraft-search-result-container', style: styles.container || {} }, contentContainer));\n }\n static get style() { return SearchcraftBaseSearchResultStyle0; }\n}, [0, \"searchcraft-base-search-result\", {\n \"titleContent\": [1, \"title-content\"],\n \"subtitleContent\": [1, \"subtitle-content\"],\n \"bodyContent\": [1, \"body-content\"],\n \"footerContent\": [1, \"footer-content\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"buttonHref\": [1, \"button-href\"],\n \"buttonTarget\": [1, \"button-target\"],\n \"buttonRel\": [1, \"button-rel\"],\n \"containerHref\": [1, \"container-href\"],\n \"containerTarget\": [1, \"container-target\"],\n \"containerRel\": [1, \"container-rel\"],\n \"imageSrc\": [1, \"image-src\"],\n \"imageAlt\": [1, \"image-alt\"],\n \"imagePlacement\": [1, \"image-placement\"],\n \"customStyles\": [1, \"custom-styles\"],\n \"documentPosition\": [2, \"document-position\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-base-search-result\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-base-search-result\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftBaseSearchResult);\n }\n break;\n } });\n}\n\nexport { SearchcraftBaseSearchResult as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-cbdcf6df.js.map","import { S as SearchcraftBaseSearchResult$1, d as defineCustomElement$1 } from './p-cbdcf6df.js';\n\nconst SearchcraftBaseSearchResult = SearchcraftBaseSearchResult$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftBaseSearchResult, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-base-search-result.js.map","function parseCustomStyles(styles) {\n if (typeof styles === 'string') {\n try {\n return JSON.parse(styles);\n }\n catch (error) {\n console.error('Invalid customStyles format:', styles);\n return {};\n }\n }\n return styles || {};\n}\nfunction serializeStyles(styles) {\n try {\n return JSON.stringify(styles);\n }\n catch (error) {\n console.error('Error serializing styles:', error);\n return '{}';\n }\n}\n/**\n * Given a timestamp value, returns a formatted time string for the time\n * since now.\n *\n * @param timestamp\n * @returns {string} Formatted string value\n */\nfunction getFormattedTimeFromNow(timestamp) {\n const now = new Date();\n const inputTime = new Date(timestamp);\n const diffInSeconds = Math.floor((now.getTime() - inputTime.getTime()) / 1000);\n const minutes = Math.floor(diffInSeconds / 60);\n const hours = Math.floor(minutes / 60);\n const days = Math.floor(hours / 24);\n const years = Math.floor(days / 365);\n if (minutes < 60) {\n return `${minutes}m ago`;\n }\n if (hours < 24) {\n return `${hours}h ago`;\n }\n if (days < 365) {\n return `${days}d ago`;\n }\n return `${years}y ago`;\n}\nfunction formatNumberWithCommas(number) {\n return number.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n}\nfunction getMillis(unit) {\n const millisInHour = 60 * 60 * 1000;\n const millisInDay = 24 * millisInHour;\n const millisInMonth = 30 * millisInDay;\n const millisInYear = 365 * millisInDay;\n switch (unit) {\n case 'hour':\n return millisInHour;\n case 'day':\n return millisInDay;\n case 'month':\n return millisInMonth;\n case 'year':\n return millisInYear;\n default:\n return 3600000;\n }\n}\n/**\n * Given an array of facet paths, removes parent facet paths.\n */\nfunction removeSubstringMatches(arr) {\n return arr.filter((entry, index, array) => !array.some((otherEntry, otherIndex) => otherIndex !== index && otherEntry.includes(entry)));\n}\n/**\n * Given a document and a SearchResultMapping, return a mapped value from the document.\n *\n * @param document\n * @param {SearchResultMapping} mapping\n * @returns {string | undefined}\n */\nfunction getDocumentValueFromSearchResultMapping(document, mapping) {\n if (document && mapping) {\n return mapping.fieldNames\n .map((fieldNameDetails) => {\n let valueFound = document[fieldNameDetails.fieldName];\n if (valueFound && fieldNameDetails.dataType === 'date') {\n valueFound = getFormattedTimeFromNow(valueFound);\n }\n return valueFound;\n })\n .filter((value) => !!value)\n .join(mapping.delimiter || ' ');\n }\n}\nfunction deepMergeWithSpread(obj1, obj2) {\n const result = Object.assign({}, obj1);\n for (const key in obj2) {\n // biome-ignore lint/suspicious/noPrototypeBuiltins: <explanation>\n if (obj2.hasOwnProperty(key)) {\n if (obj2[key] instanceof Object && obj1[key] instanceof Object) {\n result[key] = deepMergeWithSpread(obj1[key], obj2[key]);\n }\n else {\n result[key] = obj2[key];\n }\n }\n }\n return result;\n}\nfunction facetToRecord(facet) {\n const records = {};\n const traverseAndAddToFragments = (facetChild) => {\n var _a;\n records[facetChild.path] = {\n count: facetChild.count,\n path: facetChild.path,\n };\n (_a = facetChild.children) === null || _a === void 0 ? void 0 : _a.forEach((child) => {\n traverseAndAddToFragments(child);\n });\n };\n traverseAndAddToFragments(facet);\n return records;\n}\nfunction recordToObject(record) {\n const root = {\n count: 0,\n path: '/',\n children: {},\n };\n Object.keys(record).forEach((key) => {\n const fragment = record[key];\n if (fragment.path === '/') {\n return;\n }\n const pathParts = fragment.path.substring(1).split('/');\n let currentRoot = root;\n let currentPath = '';\n pathParts.forEach((part, index) => {\n const nextPath = `${currentPath}/${part}`;\n if (!currentRoot.children[nextPath]) {\n currentRoot.children[nextPath] = {\n count: 0,\n path: nextPath,\n children: {},\n };\n }\n if (index === pathParts.length - 1) {\n currentRoot.children[nextPath].count = fragment.count;\n }\n currentPath = nextPath;\n currentRoot = currentRoot.children[nextPath];\n });\n });\n return root;\n}\nfunction objectToFacet(childObject) {\n const transformed = {\n count: childObject.count,\n path: childObject.path,\n children: [],\n };\n if (Object.keys(childObject.children).length > 0) {\n transformed.children = Object.values(childObject.children).map((subChildObject) => objectToFacet(subChildObject));\n }\n return transformed;\n}\n/**\n * Filters records with the parent paths from record2 OUT of record1\n */\nfunction filterRecordByParentPaths(record1, record2) {\n // Extract all paths (keys) both records\n const paths1 = Object.keys(record1);\n const paths2 = Object.keys(record2);\n // Find all parent paths in record2\n const parentPaths = new Set(paths2\n .filter((path) => path.split('/').length > 2) // Only consider paths with more than one level\n .map((path) => path.substring(0, path.lastIndexOf('/'))));\n // Filter out keys in record1 that share a parent path with any of the identified parent paths\n const filteredRecord = Object.fromEntries(paths1\n .filter((path) => !parentPaths.has(path.substring(0, path.lastIndexOf('/'))))\n .map((path) => [path, record1[path]]));\n return filteredRecord;\n}\nfunction mergeFacetRoots(fieldName, currentRoot, incomingRoot) {\n const currentArray = currentRoot[fieldName];\n const incomingArray = incomingRoot[fieldName];\n const currentRootFacetChild = {\n count: 0,\n path: '/',\n children: currentArray,\n };\n const incomingRootFacetChild = {\n count: 0,\n path: '/',\n children: incomingArray,\n };\n // Flatten them into records\n const currentRecord = facetToRecord(currentRootFacetChild);\n const incomingRecord = facetToRecord(incomingRootFacetChild);\n // Filter out the records from record1 (the current set of records)\n // that share a parent path with record2 (the incoming records)\n const filteredCurrentRecord = filterRecordByParentPaths(currentRecord, incomingRecord);\n // Deep merge the records together\n const mergedRecord = deepMergeWithSpread(filteredCurrentRecord, incomingRecord);\n // Convert into a heirarchical object\n const mergedObject = recordToObject(mergedRecord);\n // Convert the heirarchical object back to the Facet child structure\n const mergedFacetChild = objectToFacet(mergedObject);\n return {\n [fieldName]: mergedFacetChild.children,\n };\n}\n\nexport { getMillis as a, formatNumberWithCommas as f, getDocumentValueFromSearchResultMapping as g, mergeFacetRoots as m, parseCustomStyles as p, removeSubstringMatches as r, serializeStyles as s };\n\n//# sourceMappingURL=p-f308d05d.js.map","import { p as proxyCustomElement, H, h } from './p-e4846fa2.js';\n\nconst searchcraftErrorMessageModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-error-message{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);color:var(--sc-content-danger);margin:0}\";\nconst SearchcraftErrorMessageStyle0 = searchcraftErrorMessageModuleCss;\n\nconst SearchcraftErrorMessage = /*@__PURE__*/ proxyCustomElement(class SearchcraftErrorMessage extends H {\n constructor() {\n super();\n this.__registerHost();\n this.errorMessage = undefined;\n }\n render() {\n return (h(\"p\", { key: '68c4058c43418e96729a91e6a2a9a106303c8bc0', class: 'searchcraft-error-message' }, this.errorMessage || 'Search term is required.'));\n }\n static get style() { return SearchcraftErrorMessageStyle0; }\n}, [0, \"searchcraft-error-message\", {\n \"errorMessage\": [1, \"error-message\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-error-message\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftErrorMessage);\n }\n break;\n } });\n}\n\nexport { SearchcraftErrorMessage as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-16983367.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\nimport { g as getDocumentValueFromSearchResultMapping, s as serializeStyles } from './p-f308d05d.js';\nimport { d as defineCustomElement$3 } from './p-cbdcf6df.js';\nimport { d as defineCustomElement$2 } from './p-16983367.js';\n\nconst searchcraftBaseSearchResultsModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-search-results-container{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-ad-section{align-items:center;background-color:#F1F1F1;border-radius:16px;display:flex;flex-direction:column;font-size:16px;justify-content:center;min-height:176px;text-align:center}.searchcraft-ad-section p{margin:0;color:var(--sc-content-disabled)}.searchcraft-search-results-empty-state-container{text-align:center}.searchcraft-search-results-error-message-container{text-align:center}\";\nconst SearchcraftBaseSearchResultsStyle0 = searchcraftBaseSearchResultsModuleCss;\n\nconst SearchcraftBaseSearchResults$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftBaseSearchResults extends H {\n constructor() {\n super();\n this.__registerHost();\n this.noResults = createEvent(this, \"noResults\", 7);\n this.adInterval = 4;\n this.customStylesForResults = undefined;\n this.searchResultMappings = undefined;\n this.placeAdAtEnd = false;\n this.placeAdAtStart = true;\n this.resultImagePlacement = 'right';\n this.buttonLabel = undefined;\n this.buttonTarget = '_blank';\n this.buttonRel = undefined;\n this.containerTarget = '_blank';\n this.containerRel = undefined;\n this.hasSearched = false;\n this.query = '';\n this.searchResults = null;\n }\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query.length > 0) {\n this.hasSearched = true;\n }\n else {\n this.hasSearched = false;\n }\n this.searchResults = Object.assign({}, state.searchResults);\n this.query = state.query;\n });\n const { searchResults, query } = useSearchcraftStore.getState();\n this.searchResults = searchResults;\n this.query = query;\n }\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n renderDocument(document, index) {\n /**\n * Index field values -> Result container props mappings.\n */\n const titleContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.title);\n const subtitleContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.subtitle);\n const bodyContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.body);\n const containerHref = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.containerHref);\n const buttonHref = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.buttonHref);\n const imageSource = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.imageSource);\n const footerContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.footer);\n const serializedStyles = typeof this.customStylesForResults === 'string'\n ? this.customStylesForResults\n : serializeStyles(this.customStylesForResults);\n return (h(\"searchcraft-base-search-result\", { key: `${document.document_id}-${index}`, \"custom-styles\": serializedStyles, \"image-placement\": this.resultImagePlacement, \"container-rel\": this.containerRel, \"container-target\": this.containerTarget, \"button-label\": this.buttonLabel || 'View more', \"button-rel\": this.buttonRel, \"button-target\": this.buttonTarget, \"document-position\": index, \"title-content\": titleContent, \"subtitle-content\": subtitleContent, \"body-content\": bodyContent, \"footer-content\": footerContent, \"container-href\": containerHref, \"button-href\": buttonHref, \"image-src\": imageSource }));\n }\n render() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;\n if (this.query.trim() === '') {\n return (h(\"div\", { class: 'searchcraft-search-results-empty-state-container' }, h(\"slot\", { name: 'empty-search' })));\n }\n if (!((_a = this.searchResults) === null || _a === void 0 ? void 0 : _a.data)) {\n return;\n }\n const documents = (_d = (_c = (_b = this.searchResults) === null || _b === void 0 ? void 0 : _b.data) === null || _c === void 0 ? void 0 : _c.hits) === null || _d === void 0 ? void 0 : _d.map((data, _index) => {\n const { doc: result } = data;\n return result;\n });\n const finalComponents = [];\n if (this.placeAdAtStart) {\n finalComponents.push(h(\"div\", { key: 'ad-section-start', class: 'searchcraft-ad-section' }, h(\"p\", null, \"Ad Section\")));\n }\n if (this.adInterval > 0) {\n documents.forEach((document, index) => {\n finalComponents.push(this.renderDocument(document, index));\n if ((index + 1) % this.adInterval === 0) {\n finalComponents.push(h(\"div\", { key: `ad-section-${index + 1}`, class: 'searchcraft-ad-section ' }, h(\"p\", null, \"Ad Section\")));\n }\n });\n }\n else {\n const documentElements = documents.map((document, index) => this.renderDocument(document, index));\n finalComponents.push(...documentElements);\n }\n if (this.placeAdAtEnd) {\n finalComponents.push(h(\"div\", { key: 'ad-section-end', class: 'searchcraft-ad-section' }, h(\"p\", null, \"Ad Section\")));\n }\n if (this.query.length > 0 && ((_g = (_f = (_e = this.searchResults) === null || _e === void 0 ? void 0 : _e.data) === null || _f === void 0 ? void 0 : _f.hits) === null || _g === void 0 ? void 0 : _g.length) === 0) {\n this.noResults.emit();\n }\n return (h(\"div\", { class: 'searchcraft-search-results-container' }, finalComponents, this.query.length > 0 &&\n ((_k = (_j = (_h = this.searchResults) === null || _h === void 0 ? void 0 : _h.data) === null || _j === void 0 ? void 0 : _j.hits) === null || _k === void 0 ? void 0 : _k.length) === 0 && (h(\"div\", { class: 'searchcraft-search-results-error-message-container' }, h(\"searchcraft-error-message\", { \"error-message\": `No search results found for \"${this.query}\" query` })))));\n }\n static get style() { return SearchcraftBaseSearchResultsStyle0; }\n}, [4, \"searchcraft-base-search-results\", {\n \"adInterval\": [2, \"ad-interval\"],\n \"customStylesForResults\": [1, \"custom-styles-for-results\"],\n \"searchResultMappings\": [16],\n \"placeAdAtEnd\": [4, \"place-ad-at-end\"],\n \"placeAdAtStart\": [4, \"place-ad-at-start\"],\n \"resultImagePlacement\": [1, \"result-image-placement\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"buttonTarget\": [1, \"button-target\"],\n \"buttonRel\": [1, \"button-rel\"],\n \"containerTarget\": [1, \"container-target\"],\n \"containerRel\": [1, \"container-rel\"],\n \"hasSearched\": [32],\n \"query\": [32],\n \"searchResults\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-base-search-results\", \"searchcraft-base-search-result\", \"searchcraft-error-message\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-base-search-results\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftBaseSearchResults$1);\n }\n break;\n case \"searchcraft-base-search-result\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftBaseSearchResults = SearchcraftBaseSearchResults$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftBaseSearchResults, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-base-search-results.js.map","var classnames = {exports: {}};\n\n/*!\n\tCopyright (c) 2018 Jed Watson.\n\tLicensed under the MIT License (MIT), see\n\thttp://jedwatson.github.io/classnames\n*/\n\n(function (module) {\n/* global define */\n\n(function () {\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames () {\n\t\tvar classes = '';\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (arg) {\n\t\t\t\tclasses = appendClass(classes, parseValue(arg));\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction parseValue (arg) {\n\t\tif (typeof arg === 'string' || typeof arg === 'number') {\n\t\t\treturn arg;\n\t\t}\n\n\t\tif (typeof arg !== 'object') {\n\t\t\treturn '';\n\t\t}\n\n\t\tif (Array.isArray(arg)) {\n\t\t\treturn classNames.apply(null, arg);\n\t\t}\n\n\t\tif (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes('[native code]')) {\n\t\t\treturn arg.toString();\n\t\t}\n\n\t\tvar classes = '';\n\n\t\tfor (var key in arg) {\n\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\tclasses = appendClass(classes, key);\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction appendClass (value, newClass) {\n\t\tif (!newClass) {\n\t\t\treturn value;\n\t\t}\n\t\n\t\tif (value) {\n\t\t\treturn value + ' ' + newClass;\n\t\t}\n\t\n\t\treturn value + newClass;\n\t}\n\n\tif (module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n}(classnames));\n\nconst classNames = classnames.exports;\n\nexport { classNames as c };\n\n//# sourceMappingURL=p-5cdc6210.js.map","import { p as proxyCustomElement, H, c as createEvent, h, F as Fragment } from './p-e4846fa2.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftButtonModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-button{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-bold-font-size);font-weight:var(--sc-body-bold-font-weight);line-height:var(--sc-body-bold-line-height);border-radius:8px;display:flex;padding:12px 20px;position:relative;background-color:var(--sc-surface-brand-primary);border:1px solid var(--sc-border-primary);color:var(--sc-content-brand-on-primary)}.searchcraft-button:hover{cursor:pointer;background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button:focus{outline:2px solid var(--sc-surface-brand-primary)}.buttonLabel{position:relative}\";\nconst SearchcraftButtonStyle0 = searchcraftButtonModuleCss;\n\nconst SearchcraftButton = /*@__PURE__*/ proxyCustomElement(class SearchcraftButton extends H {\n constructor() {\n super();\n this.__registerHost();\n this.buttonClick = createEvent(this, \"buttonClick\", 7);\n this.handleClick = () => {\n this.buttonClick.emit();\n };\n this.iconElement = undefined;\n this.iconOnly = false;\n this.iconPosition = 'left';\n this.label = 'Search';\n this.isRequesting = false;\n }\n render() {\n return (h(Fragment, { key: '8ea823d757ceca459ef80affa8dfdf7e96076c32' }, this.iconOnly ? (h(\"button\", { class: classNames('searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.isRequesting ? (h(\"searchcraft-spinner-dark\", null)) : (this.iconElement))) : (h(\"button\", { class: classNames('searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.iconPosition === 'left' && this.iconElement, h(\"span\", { class: classNames('buttonLabel', 'searchcraft-button-label') }, this.label)))));\n }\n static get style() { return SearchcraftButtonStyle0; }\n}, [0, \"searchcraft-button\", {\n \"iconElement\": [16],\n \"iconOnly\": [4, \"icon-only\"],\n \"iconPosition\": [1, \"icon-position\"],\n \"label\": [1],\n \"isRequesting\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-button\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftButton);\n }\n break;\n } });\n}\n\nexport { SearchcraftButton as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-9cb3d38b.js.map","import { S as SearchcraftButton$1, d as defineCustomElement$1 } from './p-9cb3d38b.js';\n\nconst SearchcraftButton = SearchcraftButton$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftButton, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-button.js.map","import { S as SearchcraftErrorMessage$1, d as defineCustomElement$1 } from './p-16983367.js';\n\nconst SearchcraftErrorMessage = SearchcraftErrorMessage$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftErrorMessage, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-error-message.js.map","import { p as proxyCustomElement, H, c as createEvent, h, F as Fragment } from './p-e4846fa2.js';\nimport { c as classNames } from './p-5cdc6210.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\nimport { m as mergeFacetRoots, r as removeSubstringMatches } from './p-f308d05d.js';\n\nconst searchcraftFacetListModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.filtersListContainer{width:100%}.filterCheckboxLabel{align-items:center;color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);font-size:14px;font-weight:600;gap:14px;position:relative;-webkit-font-smoothing:antialiased}.filterCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:var(--sc-surface-brand-secondary-hover);border:1px solid var(--sc-surface-disabled);border-radius:8px;cursor:pointer;display:flex;height:24px;justify-content:center;width:24px}.filterCheckboxLabel input[type=checkbox]:focus{outline:2px solid var(--sc-surface-brand-primary)}.filterCheckboxLabel input[type=checkbox]:checked{background-color:var(--sc-surface-brand-primary);position:relative}.filterCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.filterCheckboxLabel input[type=checkbox]:checked+.dashContainer{display:block}.childFilterCheckboxLabel{align-items:center;color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);font-size:14px;font-weight:600;gap:12px;margin-left:24px;position:relative}.childFilterCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:var(--sc-surface-brand-secondary-hover);border:1px solid var(--sc-surface-disabled);border-radius:8px;cursor:pointer;display:flex;height:24px;justify-content:center;position:relative;width:24px;-webkit-font-smoothing:antialiased}.childFilterCheckboxLabel input[type=checkbox]:focus{outline:2px solid var(--sc-surface-brand-primary)}.childFilterCheckboxLabel input[type=checkbox]:checked{background-color:var(--sc-surface-brand-primary);position:relative}.childFilterCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.childFilterCheckboxLabel input[type=checkbox]:checked+.dashContainer{display:block}.checkContainer{display:none;height:16px;width:16px;position:absolute;top:9px;left:8px}.dashContainer{display:none;height:3px;width:14px;position:absolute;top:3px;left:9px}.searchcraft-facet-message{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);color:var(--sc-content-disabled);text-align:center}\";\nconst SearchcraftFacetListStyle0 = searchcraftFacetListModuleCss;\n\nconst SearchcraftFacetList = /*@__PURE__*/ proxyCustomElement(class SearchcraftFacetList extends H {\n constructor() {\n super();\n this.__registerHost();\n this.facetSelectionUpdated = createEvent(this, \"facetSelectionUpdated\", 7);\n this.searchStore = useSearchcraftStore.getState();\n this.formatLabel = (facetChild) => {\n const label = facetChild.path.replace(/^\\//, '');\n const count = facetChild.count;\n return `${label.replace(/-/g, ' ').replace(/\\b\\w/g, (char) => char.toUpperCase())} (${count})`;\n };\n this.formatSubLabel = (facetChild, facetChildAncestor) => {\n const facetChildPath = facetChild.path.substring(facetChildAncestor.path.length);\n const label = facetChildPath.replace(/^\\//, '');\n const count = facetChild.count;\n return `${label.replace(/-/g, ' ').replace(/\\b\\w/g, (char) => char.toUpperCase())} (${count})`;\n };\n this.fieldName = undefined;\n this.baseFacetRoot = undefined;\n this.facetRoot = undefined;\n this.selectedPaths = {};\n this.lastTimeTaken = undefined;\n this.hasNewSearchTerm = false;\n this.lastQuery = undefined;\n this.lastSearchMode = undefined;\n this.lastSortType = undefined;\n this.unsubscribe = undefined;\n }\n handleStateUpdate(state) {\n var _a, _b;\n const facetPrime = (_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data.facets;\n const timeTaken = (_b = state.searchResults) === null || _b === void 0 ? void 0 : _b.data.time_taken;\n /** Things to do when the state's search term has changed, but before the response received */\n if (state.query !== this.lastQuery ||\n state.searchMode !== this.lastSearchMode ||\n state.sortType !== this.lastSortType) {\n this.selectedPaths = {};\n this.hasNewSearchTerm = true;\n }\n /** Things to do when a new response with a new facet prime has been received */\n if (timeTaken !== this.lastTimeTaken && facetPrime) {\n this.facetRoot = undefined;\n const incomingFacetRoot = facetPrime.find((facet) => this.fieldName === Object.keys(facet)[0]);\n /** Data is from a new search term: completely override our facets */\n if (this.hasNewSearchTerm) {\n this.baseFacetRoot = incomingFacetRoot;\n this.facetRoot = incomingFacetRoot;\n this.hasNewSearchTerm = false;\n }\n else if (this.baseFacetRoot) {\n /** Data is from an existing search term, merge the facets together */\n this.facetRoot = mergeFacetRoots(this.fieldName, this.baseFacetRoot, incomingFacetRoot);\n }\n }\n this.lastQuery = state.query;\n this.lastSearchMode = state.searchMode;\n this.lastSortType = state.sortType;\n this.lastTimeTaken = timeTaken;\n }\n connectedCallback() {\n this.handleStateUpdate(this.searchStore);\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.handleStateUpdate(state);\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n handleCheckboxChange(path) {\n const isCheckboxChecked = !this.selectedPaths[path];\n if (isCheckboxChecked) {\n /**\n * Checkbox Checked: Add to the selectedPaths record\n * Uses spread operator here so UI updates.\n */\n this.selectedPaths = Object.assign(Object.assign({}, this.selectedPaths), { [path]: true });\n }\n else {\n /**\n * Checkbox Uncheck: Remove any paths and sub-paths\n */\n const updatedPaths = Object.keys(this.selectedPaths).filter((testPath) => !testPath.includes(path));\n this.selectedPaths = updatedPaths.reduce((acc, str) => {\n acc[str] = true;\n return acc;\n }, {});\n }\n /**\n * Emit the paths array, with parent paths removed.\n */\n const paths = Object.keys(this.selectedPaths).filter((path) => this.selectedPaths[path]);\n const pathsWithParentPathsRemoved = removeSubstringMatches(paths);\n this.facetSelectionUpdated.emit({ paths: pathsWithParentPathsRemoved });\n }\n render() {\n var _a;\n const firstFacet = (_a = this.facetRoot) === null || _a === void 0 ? void 0 : _a[this.fieldName];\n return (h(\"div\", { key: 'c7b6a2c7bbb48d0835745b4bcae43a283ade4139', class: classNames('filtersListContainer', 'searchcraft-filters-list-container') }, !firstFacet && (h(\"p\", { key: 'a682f57ff51fdcfec670744ef84930c90c9b9c20', class: 'searchcraft-facet-message' }, \"Enter a search to view facets.\")), firstFacet === null || firstFacet === void 0 ? void 0 :\n firstFacet.map((facetChild) => {\n var _a;\n const isChildSelected = facetChild.children\n ? (_a = facetChild.children) === null || _a === void 0 ? void 0 : _a.some((child) => this.selectedPaths[child.path])\n : false;\n return (h(\"div\", { key: facetChild.path, class: classNames('searchcraft-filters-list-item') }, h(\"label\", { class: classNames('filterCheckboxLabel', 'searchcraft-filters-list-checkbox-label') }, h(\"input\", { checked: this.selectedPaths[facetChild.path], onChange: (_event) => this.handleCheckboxChange(facetChild.path), type: 'checkbox' }), isChildSelected ? (h(\"div\", { class: classNames('dashContainer', 'searchcraft-filter-list-dash-container') }, h(\"searchcraft-dash-icon\", null))) : (h(\"div\", { class: classNames('checkContainer', 'searchcraft-filter-list-check-container') }, h(\"searchcraft-check-icon\", null))), this.formatLabel(facetChild)), facetChild.children && facetChild.children.length > 0 && (h(Fragment, null, facetChild.children.map((grandchild) => (h(\"label\", { key: grandchild.path, class: classNames('childFilterCheckboxLabel', 'searchcraft-child-filter-checkbox-label'), style: {\n display: this.selectedPaths[facetChild.path]\n ? 'flex'\n : 'none',\n } }, h(\"input\", { checked: this.selectedPaths[grandchild.path], onChange: (_event) => {\n this.handleCheckboxChange(grandchild.path);\n }, type: 'checkbox' }), h(\"div\", { class: classNames('checkContainer', 'searchcraft-filter-list-check-container') }, h(\"searchcraft-check-icon\", null)), this.formatSubLabel(grandchild, facetChild))))))));\n })));\n }\n static get style() { return SearchcraftFacetListStyle0; }\n}, [0, \"searchcraft-facet-list\", {\n \"fieldName\": [1, \"field-name\"],\n \"baseFacetRoot\": [32],\n \"facetRoot\": [32],\n \"selectedPaths\": [32],\n \"lastTimeTaken\": [32],\n \"hasNewSearchTerm\": [32],\n \"lastQuery\": [32],\n \"lastSearchMode\": [32],\n \"lastSortType\": [32],\n \"unsubscribe\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-facet-list\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-facet-list\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftFacetList);\n }\n break;\n } });\n}\n\nexport { SearchcraftFacetList as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-42bfef5f.js.map","import { S as SearchcraftFacetList$1, d as defineCustomElement$1 } from './p-42bfef5f.js';\n\nconst SearchcraftFacetList = SearchcraftFacetList$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftFacetList, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-facet-list.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-e4846fa2.js';\nimport { a as getMillis } from './p-f308d05d.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftSliderModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-slider-container{align-items:center;display:flex;flex-direction:column;gap:10px;width:100%}.searchcraft-slider-range-container{align-items:center;background-color:var(--sc-surface-disabled);border-radius:999px;display:flex;position:relative;height:4px;width:100%}.searchcraft-slider-range-container::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-active-range{background-color:var(--sc-surface-brand-primary);border-radius:2px;height:4px;position:absolute;top:50%;transform:translateY(-50%);z-index:0}.searchcraft-slider-range-container .searchcraft-slider-active-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-active-range::-moz-range-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-input{appearance:none;background:transparent;border-radius:2px;height:4px;margin:0;outline:none;pointer-events:none;position:absolute;width:100%;-webkit-appearance:none}.searchcraft-slider-range-container .searchcraft-slider-input::-webkit-slider-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:2px solid var(--sc-border-neutral);cursor:pointer;height:20px;pointer-events:all;width:20px;-webkit-appearance:none}.searchcraft-slider-range-container .searchcraft-slider-input::-moz-range-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:2px solid var(--sc-border-neutral);cursor:pointer;height:20px;pointer-events:all;width:20px}.searchcraft-slider-label-container{color:var(--sc-content-primary);display:flex;font-family:\\\"Source Sans Pro\\\", sans-serif;font-size:15px;font-weight:600;justify-content:space-between;margin-top:10px;width:100%}.searchcraft-slider-label{min-width:30px;text-align:center}\";\nconst SearchcraftSliderStyle0 = searchcraftSliderModuleCss;\n\nconst SearchcraftSlider = /*@__PURE__*/ proxyCustomElement(class SearchcraftSlider extends H {\n constructor() {\n super();\n this.__registerHost();\n this.rangeChanged = createEvent(this, \"rangeChanged\", 7);\n this.emitUpdate = async () => {\n this.rangeChanged.emit({\n startValue: this.startValue,\n endValue: this.endValue,\n });\n };\n this.handleStartValueChange = (event) => {\n const inputElement = event.target;\n const value = Number.parseInt(inputElement.value, 10);\n this.lastFocusedHandle = 'min';\n if (value <= this.endValue) {\n this.startValue = value;\n this.emitUpdate();\n }\n else {\n this.startValue = this.endValue;\n inputElement.value = `${this.endValue}`;\n }\n };\n this.handleEndValueChange = (event) => {\n const inputElement = event.target;\n const value = Number.parseInt(inputElement.value, 10);\n this.lastFocusedHandle = 'max';\n if (value >= this.startValue) {\n this.endValue = value;\n this.emitUpdate();\n }\n else {\n this.endValue = this.startValue;\n inputElement.value = `${this.startValue}`;\n }\n };\n this.max = 100;\n this.min = 0;\n this.granularity = getMillis('month');\n this.dataType = 'number';\n this.endValue = this.max;\n this.startValue = this.min;\n this.lastFocusedHandle = 'max';\n }\n componentDidLoad() {\n this.startValue = this.min;\n this.endValue = this.max;\n }\n render() {\n const rangeMin = this.min;\n const rangeMax = this.max;\n const startPercent = ((this.startValue - rangeMin) / (rangeMax - rangeMin)) * 100;\n const endPercent = ((this.endValue - rangeMin) / (rangeMax - rangeMin)) * 100;\n const startLabel = this.dataType === 'number'\n ? this.startValue\n : new Date(this.startValue).getFullYear();\n const endLabel = this.dataType === 'number'\n ? this.endValue\n : new Date(this.endValue).getFullYear();\n return (h(\"div\", { key: '51de4996df052bf178590aeb4c56a67ec57c92e5', class: 'searchcraft-slider-container' }, h(\"div\", { key: '634bead69c3fbc462cda3dd65dd4ba6a398c6913', class: 'searchcraft-slider-range-container' }, h(\"div\", { key: '1b7a0b63ef208884f24b9f56b48a72bca320c71b', class: 'searchcraft-slider-active-range', style: {\n left: `${startPercent}%`,\n width: `${endPercent - startPercent}%`,\n } }), h(\"input\", { key: '29313d6909d5ff646d7f3810163f5f01fe09cc36', class: classNames('searchcraft-slider-input', 'searchcraft-slider-input-min-handle'), max: this.max, min: this.min, onInput: this.handleStartValueChange.bind(this), step: this.granularity, style: { zIndex: this.lastFocusedHandle === 'min' ? '2' : '1' }, type: 'range', value: this.startValue }), h(\"input\", { key: '1e95e93a028c7bc204e2f3894bfe8b77ac6c9d28', class: classNames('searchcraft-slider-input', 'searchcraft-slider-input-max-handle'), max: this.max, min: this.min, onInput: this.handleEndValueChange.bind(this), step: this.granularity, style: { zIndex: this.lastFocusedHandle === 'max' ? '2' : '1' }, type: 'range', value: this.endValue })), h(\"div\", { key: 'c1560933a38f3153ac1dbaece041ef75df479dc4', class: 'searchcraft-slider-label-container' }, h(\"span\", { key: '638f72b8c081a324cc3ecb833163cd036a6ab90c', class: 'searchcraft-slider-label' }, startLabel), h(\"span\", { key: '011968bdf897de9960fe2214b4adceee4d79b6d0', class: 'searchcraft-slider-label' }, endLabel))));\n }\n static get style() { return SearchcraftSliderStyle0; }\n}, [0, \"searchcraft-slider\", {\n \"max\": [2],\n \"min\": [2],\n \"granularity\": [2],\n \"dataType\": [1, \"data-type\"],\n \"endValue\": [32],\n \"startValue\": [32],\n \"lastFocusedHandle\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-slider\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-slider\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftSlider);\n }\n break;\n } });\n}\n\nexport { SearchcraftSlider as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-5380505b.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftToggleButtonModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-toggle-button-container{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}.searchcraft-toggle-button-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-toggle-button-background{transition:background-color 0.2s;background:var(--sc-surface-disabled);border:none;border-radius:16px;cursor:pointer;height:26px;position:relative;width:44px;flex-shrink:0}.searchcraft-toggle-button-background.active{background:var(--sc-surface-brand-primary);box-shadow:0px 0px 0px 1px rgba(0, 0, 0, 0.05)}.searchcraft-toggle-button-handle{background:var(--sc-surface-neutral-light);border-radius:50%;height:18px;left:4px;position:absolute;top:calc(50% - 9px);transition:transform 0.3s ease;width:18px}.searchcraft-toggle-button-handle.active{transform:translateX(16px)}\";\nconst SearchcraftToggleButtonStyle0 = searchcraftToggleButtonModuleCss;\n\nconst SearchcraftToggleButton = /*@__PURE__*/ proxyCustomElement(class SearchcraftToggleButton extends H {\n constructor() {\n super();\n this.__registerHost();\n this.toggleUpdated = createEvent(this, \"toggleUpdated\", 7);\n this.handleToggle = async () => {\n this.isActive = !this.isActive;\n this.toggleUpdated.emit(this.isActive);\n };\n this.label = 'Toggle';\n this.subLabel = undefined;\n this.isActive = false;\n this.unsubscribe = undefined;\n this.lastQuery = undefined;\n }\n connectedCallback() {\n /** When the query changes, sets toggle button state back to inactive. */\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query !== this.lastQuery && state.query.trim().length === 0) {\n this.isActive = false;\n }\n this.lastQuery = state.query;\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n render() {\n return (h(\"div\", { key: '90a7816e1e02125939f3f05a9dbfd94a5f161959', class: 'searchcraft-toggle-button-container' }, h(\"div\", { key: '6a3e570ba3d00ccc315cd092d5b1c618c0b23ea2' }, h(\"p\", { key: '41d1d0ab4557c856bb0ed12af8a4b0c81203d6d5', class: 'searchcraft-toggle-button-label' }, this.label), this.subLabel && (h(\"p\", { key: 'ec145b4f655bacec600ac9aa137662f7fed9b7d2', class: 'searchcraft-toggle-button-sub-label' }, this.subLabel))), h(\"button\", { key: '226599543806881f306630708eee24e922ff592e', class: classNames('searchcraft-toggle-button-background', {\n active: this.isActive,\n }), onClick: this.handleToggle, type: 'button' }, h(\"div\", { key: 'b83e81e7820705952cfc8c911223e67dfbc0f98d', class: classNames('searchcraft-toggle-button-handle', {\n active: this.isActive,\n }) }))));\n }\n static get style() { return SearchcraftToggleButtonStyle0; }\n}, [0, \"searchcraft-toggle-button\", {\n \"label\": [1],\n \"subLabel\": [1, \"sub-label\"],\n \"isActive\": [32],\n \"unsubscribe\": [32],\n \"lastQuery\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-toggle-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-toggle-button\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftToggleButton);\n }\n break;\n } });\n}\n\nexport { SearchcraftToggleButton as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-a23d2994.js.map","import { p as proxyCustomElement, H, h } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\nimport { a as getMillis } from './p-f308d05d.js';\nimport { d as defineCustomElement$4 } from './p-42bfef5f.js';\nimport { d as defineCustomElement$3 } from './p-5380505b.js';\nimport { d as defineCustomElement$2 } from './p-a23d2994.js';\n\nconst searchcraftFilterPanelModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-filter-panel{display:flex;flex-direction:column;gap:16px}.searchcraft-filter-panel-section{display:flex;flex-direction:column;gap:8px}.searchcraft-filter-panel-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-bold-font-size);font-weight:var(--sc-body-small-bold-font-weight);line-height:var(--sc-body-small-bold-line-height)}\";\nconst SearchcraftFilterPanelStyle0 = searchcraftFilterPanelModuleCss;\n\nconst SearchcraftFilterPanel$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftFilterPanel extends H {\n constructor() {\n super();\n this.__registerHost();\n this.searchStore = useSearchcraftStore.getState();\n this.items = [];\n this.unsubscribe = undefined;\n this.lastQuery = undefined;\n }\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.lastQuery = state.query || '';\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n handleDateRangeChanged(fieldName, min, max) {\n const start = new Date(min);\n const end = new Date(max);\n this.searchStore.addRangeValueForIndexField({\n fieldName,\n value: `${fieldName}:[${start.toISOString()} TO ${end.toISOString()}]`,\n });\n this.searchStore.search();\n }\n handleNumericRangeChanged(fieldName, min, max) {\n this.searchStore.addRangeValueForIndexField({\n fieldName,\n value: `${fieldName}:[${min} TO ${max}]`,\n });\n this.searchStore.search();\n }\n handleFacetSelectionUpdated(fieldName, paths) {\n if (paths.length > 0) {\n this.searchStore.addFacetPathsForIndexField({\n fieldName,\n value: `${fieldName}: IN [${paths.join(' ')}]`,\n });\n }\n else {\n this.searchStore.removeFacetPathsForIndexField(fieldName);\n }\n this.searchStore.search();\n }\n handleExactMatchToggleUpdated(isActive) {\n this.searchStore.setSearchMode(isActive ? 'normal' : 'fuzzy');\n this.searchStore.search();\n }\n handleMostRecentToggleUpdated(isActive) {\n this.searchStore.setSortType(isActive ? 'desc' : 'asc');\n this.searchStore.search();\n }\n /**\n * Iterate through `items` and render them based on `type`\n */\n render() {\n return (h(\"div\", { key: '45bcbe509465b8fe3720f3a535902906acfac2ea', class: 'searchcraft-filter-panel' }, this.items.map((filterItem) => {\n switch (filterItem.type) {\n case 'dateRange': {\n const item = filterItem;\n const min = new Date(item.options.minDate).getTime();\n const max = new Date(item.options.maxDate).getTime();\n const granularityValue = getMillis(item.options.granularity);\n // return date range slider\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-slider\", { min: min, max: max, granularity: granularityValue, dataType: 'date', onRangeChanged: (event) => {\n this.handleDateRangeChanged(item.fieldName, event.detail.startValue, event.detail.endValue);\n } })));\n }\n case 'numericRange': {\n const item = filterItem;\n // return date range slider\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-slider\", { min: item.options.min, max: item.options.max, granularity: item.options.granularity, onRangeChanged: (event) => {\n this.handleNumericRangeChanged(item.fieldName, event.detail.startValue, event.detail.endValue);\n } })));\n }\n case 'facets': {\n const item = filterItem;\n // return \"filters-list\"\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-facet-list\", { fieldName: item.fieldName, onFacetSelectionUpdated: (event) => {\n this.handleFacetSelectionUpdated(item.fieldName, event.detail.paths);\n } })));\n }\n case 'exactMatchToggle': {\n const item = filterItem;\n return (h(\"searchcraft-toggle-button\", { label: item.label, subLabel: item.options.subLabel, onToggleUpdated: (event) => {\n this.handleExactMatchToggleUpdated(event.detail);\n } }));\n }\n case 'mostRecentToggle': {\n const item = filterItem;\n return (h(\"searchcraft-toggle-button\", { label: item.label, subLabel: item.options.subLabel, onToggleUpdated: (event) => {\n this.handleMostRecentToggleUpdated(event.detail);\n } }));\n }\n }\n })));\n }\n static get style() { return SearchcraftFilterPanelStyle0; }\n}, [0, \"searchcraft-filter-panel\", {\n \"items\": [16],\n \"unsubscribe\": [32],\n \"lastQuery\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-filter-panel\", \"searchcraft-facet-list\", \"searchcraft-slider\", \"searchcraft-toggle-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-filter-panel\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftFilterPanel$1);\n }\n break;\n case \"searchcraft-facet-list\":\n if (!customElements.get(tagName)) {\n defineCustomElement$4();\n }\n break;\n case \"searchcraft-slider\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-toggle-button\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftFilterPanel = SearchcraftFilterPanel$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftFilterPanel, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-filter-panel.js.map","import { p as proxyCustomElement, H, h } from './p-e4846fa2.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftInputLabelModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-input-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-bold-font-size);font-weight:var(--sc-body-small-bold-font-weight);line-height:var(--sc-body-small-bold-line-height);color:var(--sc-content-neutral-primary);margin-top:4px;margin-bottom:4px}\";\nconst SearchcraftInputLabelStyle0 = searchcraftInputLabelModuleCss;\n\nconst SearchcraftInputLabel = /*@__PURE__*/ proxyCustomElement(class SearchcraftInputLabel extends H {\n constructor() {\n super();\n this.__registerHost();\n this.inputLabelClassName = '';\n this.label = undefined;\n }\n render() {\n if (!this.label) {\n return null;\n }\n return (h(\"label\", { class: classNames('searchcraft-input-label', this.inputLabelClassName), htmlFor: 'searchcraft-input-id' }, this.label));\n }\n static get style() { return SearchcraftInputLabelStyle0; }\n}, [0, \"searchcraft-input-label\", {\n \"inputLabelClassName\": [1, \"input-label-class-name\"],\n \"label\": [1]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-input-label\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-input-label\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftInputLabel);\n }\n break;\n } });\n}\n\nexport { SearchcraftInputLabel as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-bd5fede3.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore, i as ie } from './p-ad4ebde0.js';\nimport { p as parseCustomStyles } from './p-f308d05d.js';\nimport { c as classNames } from './p-5cdc6210.js';\nimport { d as defineCustomElement$4 } from './p-9cb3d38b.js';\nimport { d as defineCustomElement$3 } from './p-16983367.js';\nimport { d as defineCustomElement$2 } from './p-bd5fede3.js';\n\nconst name = \"@searchcraft/javascript-sdk\";\nconst version = \"0.5.3\";\nconst description = \"Searchcraft Javascript SDK\";\nconst author = \"Searchcraft\";\nconst license = \"Apache-2.0\";\nconst main = \"dist/index.cjs.js\";\nconst module = \"dist/index.js\";\nconst types = \"dist/types/index.d.ts\";\nconst collection = \"dist/collection/collection-manifest.json\";\nconst unpkg = \"dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js\";\nconst exports = {\n\t\".\": {\n\t\t\"import\": \"./dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js\",\n\t\trequire: \"./dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.cjs.js\",\n\t\ttypes: \"./dist/types/index.d.ts\"\n\t},\n\t\"./components\": {\n\t\t\"import\": \"./dist/components/index.js\",\n\t\ttypes: \"./dist/components/index.d.ts\"\n\t},\n\t\"./loader\": {\n\t\t\"import\": \"./dist/loader/index.js\",\n\t\trequire: \"./dist/loader/index.cjs\",\n\t\ttypes: \"./dist/loader/index.d.ts\"\n\t},\n\t\"./dist/components/*\": {\n\t\t\"import\": \"./dist/components/*\",\n\t\ttypes: \"./dist/components/*\"\n\t}\n};\nconst repository = {\n\ttype: \"git\",\n\turl: \"https://bitbucket.org/madebychalk/searchcraft-javascript-sdks/\"\n};\nconst files = [\n\t\"dist/\"\n];\nconst scripts = {\n\tbuild: \"stencil build\",\n\tdev: \"stencil build --dev --watch\",\n\ttest: \"stencil test --spec --e2e\",\n\t\"test.watch\": \"stencil test --spec --e2e --watchAll\",\n\tgenerate: \"stencil generate\"\n};\nconst dependencies = {\n\tclassnames: \"^2.3.2\"\n};\nconst devDependencies = {\n\t\"@searchcraft/core\": \"*\",\n\t\"@searchcraft/javascript-sdk\": \"*\",\n\t\"@stencil/core\": \"^4.7.0\",\n\t\"@stencil/react-output-target\": \"^0.8.2\",\n\t\"@stencil/sass\": \"^3.0.12\",\n\t\"@types/node\": \"^16.18.11\",\n\tzustand: \"^5.0.1\"\n};\nconst packageJson = {\n\tname: name,\n\t\"private\": false,\n\tversion: version,\n\tdescription: description,\n\tauthor: author,\n\tlicense: license,\n\tmain: main,\n\tmodule: module,\n\ttypes: types,\n\tcollection: collection,\n\t\"collection:main\": \"dist/collection/index.js\",\n\tunpkg: unpkg,\n\texports: exports,\n\trepository: repository,\n\tfiles: files,\n\tscripts: scripts,\n\tdependencies: dependencies,\n\tdevDependencies: devDependencies\n};\n\nconst searchcraftInputFormModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-input-wrapper{position:relative;display:flex}.searchcraft-input-grid{display:grid;gap:4px 8px}.searchcraft-input-grid-buttonLeft{grid-template-rows:repeat(3, auto);grid-template-columns:auto 1fr}.searchcraft-input-grid-buttonLeft .searchcraft-input-button-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-label-wrapper{grid-column:2/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-error-wrapper{grid-column:2/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonRight{grid-template-rows:repeat(3, auto);grid-template-columns:1fr auto}.searchcraft-input-grid-buttonRight .searchcraft-input-button-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-label-wrapper{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-error-wrapper{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonNone{grid-template-rows:repeat(3, auto);grid-template-columns:auto}.searchcraft-input-grid-buttonNone .searchcraft-input-button-wrapper{display:none}.searchcraft-input-grid-buttonNone .searchcraft-input-label-wrapper{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonNone .searchcraft-input-error-wrapper{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonNone .searchcraft-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);background-color:var(--sc-surface-neutral-secondary);border:none;border-radius:var(--sc-input-border-radius);color:var(--sc-content-neutral-primary);outline:none;padding-left:var(--sc-input-padding-left);padding-right:var(--sc-input-padding-right);padding-top:12px;padding-bottom:12px;flex:1}.searchcraft-input::placeholder{color:var(--sc-content-disabled)}.searchcraft-input:focus{outline:var(--sc-border-brand) solid 2px}.searchcraft-input:focus::placeholder{opacity:0}.searchcraft-input.error{color:var(--sc-content-danger);outline:var(--sc-border-danger) solid 2px}.searchcraft-input.error:focus{outline:var(--sc-border-danger) solid 2px}.searchcraft-input-search-icon-wrapper{align-items:center;justify-content:center;display:flex;position:absolute;pointer-events:none;bottom:0;left:0;top:0;width:var(--sc-input-padding-left)}.searchcraft-input-search-icon{pointer-events:none;width:var(--sc-input-search-icon-size);height:var(--sc-input-search-icon-size)}.searchcraft-input-clear-button{all:unset;align-items:center;justify-content:center;cursor:pointer;display:flex;position:absolute;border:none;outline:none;bottom:0;right:0;top:0;width:var(--sc-input-padding-right)}.searchcraft-input-clear-icon{width:var(--sc-input-clear-icon-size);height:var(--sc-input-clear-icon-size)}\";\nconst SearchcraftInputFormStyle0 = searchcraftInputFormModuleCss;\n\nconst SearchcraftInput = /*@__PURE__*/ proxyCustomElement(class SearchcraftInput extends H {\n constructor() {\n super();\n this.__registerHost();\n this.inputCleared = createEvent(this, \"inputCleared\", 7);\n this.noResultsReceived = createEvent(this, \"noResultsReceived\", 7);\n this.querySubmit = createEvent(this, \"querySubmit\", 7);\n this.inputFocus = createEvent(this, \"inputFocus\", 7);\n this.inputBlur = createEvent(this, \"inputBlur\", 7);\n this.debounceTimeout = null;\n this.searchStore = useSearchcraftStore.getState();\n this.handleOnInput = (event) => {\n const input = event.target;\n this.inputValue = input.value;\n if (input.value.trim() === '') {\n this.inputCleared.emit();\n return;\n }\n if (!this.autoSearch) {\n return;\n }\n if (this.debounceDelay > 0) {\n if (this.debounceTimeout) {\n clearTimeout(this.debounceTimeout);\n }\n this.debounceTimeout = setTimeout(() => this.performSearch(input.value), this.debounceDelay);\n }\n else {\n this.performSearch(input.value);\n }\n };\n this.performSearch = async (value) => {\n if (value === useSearchcraftStore.getState().query) {\n return;\n }\n this.querySubmit.emit(value);\n this.searchTerm = value.trim();\n this.error = false;\n this.searchStore.setQuery(this.searchTerm);\n try {\n await this.searchStore.search();\n }\n catch (error) {\n this.error = true;\n this.inputCleared.emit();\n }\n };\n this.handleClearInput = () => {\n this.inputValue = '';\n if (this.debounceTimeout) {\n clearTimeout(this.debounceTimeout);\n }\n this.searchTerm = '';\n this.searchStore.setQuery('');\n this.searchStore.setSearchResults(null);\n this.error = false;\n if (this.inputCleared) {\n this.inputCleared.emit();\n }\n };\n this.handleFormSubmit = async (event) => {\n event.preventDefault();\n await this.performSearch(this.searchTerm);\n };\n this.config = undefined;\n this.autoSearch = true;\n this.buttonPlacement = 'none';\n this.buttonLabel = undefined;\n this.inputLabel = undefined;\n this.customStyles = {};\n this.placeholderValue = 'Enter Search';\n this.searchTerm = '';\n this.debounceDelay = 0;\n this.inputValue = this.searchTerm;\n this.error = false;\n this.isSearchcraftInitialized = false;\n }\n init() {\n if (this.config && !this.isSearchcraftInitialized) {\n const searchcraft = new ie(this.config, {\n sdkName: packageJson.name,\n sdkVersion: packageJson.version,\n });\n this.searchStore.initialize(searchcraft, true);\n this.isSearchcraftInitialized = true;\n }\n }\n componentDidLoad() {\n this.init();\n }\n onConfigChange() {\n this.init();\n }\n render() {\n const validatedCustomStyles = parseCustomStyles(this.customStyles);\n const isShowingClearButton = this.inputValue.length > 0;\n const inputGridClassNames = classNames('searchcraft-input-grid', {\n 'searchcraft-input-grid-buttonLeft': this.buttonPlacement === 'left',\n 'searchcraft-input-grid-buttonRight': this.buttonPlacement === 'right',\n 'searchcraft-input-grid-buttonNone': this.buttonPlacement === 'none',\n });\n return (h(\"form\", { key: '7f224a10ab80d70660c9db97be5d68830932570b', class: 'searchcraft-input-form', onSubmit: this.handleFormSubmit }, h(\"div\", { key: '6822a21a43e5be992b11ddb6c86370ddd68e1475', class: inputGridClassNames }, h(\"div\", { key: '6022989ca876ea46de048398a076bc43d5213554', class: 'searchcraft-input-button-wrapper' }, h(\"searchcraft-button\", { key: 'd48b61729ef9a3f19049dfe751aefa22fdc85e9f', onButtonClick: this.handleFormSubmit, label: this.buttonLabel })), h(\"div\", { key: '3465e467cbb965ad813b6c9c726173bb3fe828f2', class: 'searchcraft-input-label-wrapper' }, h(\"searchcraft-input-label\", { key: '1026b7834358c6673a72ef8352830c9b4681020f', label: this.inputLabel })), this.error && (h(\"div\", { key: 'ff0d55cd88e1895f9b0bd4c0afc917127e76afa2', class: 'searchcraft-input-error-wrapper' }, h(\"searchcraft-error-message\", { key: '57fc160411f21f45617e1a3b8677fb4c6e96c0f0', errorMessage: 'Please enter a search query.' }))), h(\"div\", { key: 'b2783bf86177d22d4abedb4420fdb2a1807527ef', class: 'searchcraft-input-wrapper' }, h(\"input\", { key: 'e985da32be58ab3e200866e085b2acd25b54aa31', autoComplete: 'off', class: 'searchcraft-input', onFocus: () => this.inputFocus.emit(), onBlur: () => this.inputBlur.emit(), onInput: (event) => {\n this.handleOnInput(event);\n }, placeholder: this.placeholderValue, style: validatedCustomStyles, type: 'text', value: this.inputValue }), h(\"div\", { key: 'd5277758ae26262f5f3b49e8763add412661e5cf', class: 'searchcraft-input-search-icon-wrapper' }, h(\"svg\", { key: '79792740ea1207fad40786f555c63c4a26ff3fe2', class: 'searchcraft-input-search-icon', viewBox: '0 0 20 20', fill: 'none', xmlns: 'http://www.w3.org/2000/svg', \"aria-labelledby\": 'searchcraft-title' }, h(\"title\", { key: '7a487bdf41babdafb802ebd79c34a6a5da300cd6', id: 'searchcraft-title' }, \"Searchcraft Search Icon Light\"), h(\"path\", { key: '27c442bf412aca373cbc982b3a35a00fe7bb82ed', 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' }))), isShowingClearButton && (h(\"button\", { key: '4c4bc21e9e87f4245ac38d7af269aae35876b6b0', type: 'button', class: 'searchcraft-input-clear-button', onClick: this.handleClearInput }, h(\"svg\", { key: '4b82e65987a8a8c296d2b9c279474c29607727e0', class: 'searchcraft-input-clear-icon', viewBox: '0 0 22 22', fill: 'none', xmlns: 'http://www.w3.org/2000/svg', \"aria-labelledby\": 'icon-title' }, h(\"title\", { key: '9d64212798691a2f8c6c9c4f74ceca1d2fe39fd1', id: 'icon-title' }, \"Searchcraft Clear Input Icon Light\"), h(\"path\", { key: '4c6c5b33fbd9ac02661996bb56e0902094e9b140', 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' }))))))));\n }\n static get watchers() { return {\n \"config\": [\"onConfigChange\"]\n }; }\n static get style() { return SearchcraftInputFormStyle0; }\n}, [0, \"searchcraft-input-form\", {\n \"config\": [16],\n \"autoSearch\": [4, \"auto-search\"],\n \"buttonPlacement\": [1, \"button-placement\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"inputLabel\": [1, \"input-label\"],\n \"customStyles\": [1, \"custom-styles\"],\n \"placeholderValue\": [1, \"placeholder-value\"],\n \"searchTerm\": [1, \"search-term\"],\n \"debounceDelay\": [2, \"debounce-delay\"],\n \"inputValue\": [32],\n \"error\": [32],\n \"isSearchcraftInitialized\": [32]\n }, undefined, {\n \"config\": [\"onConfigChange\"]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-input-form\", \"searchcraft-button\", \"searchcraft-error-message\", \"searchcraft-input-label\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-input-form\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftInput);\n }\n break;\n case \"searchcraft-button\":\n if (!customElements.get(tagName)) {\n defineCustomElement$4();\n }\n break;\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-input-label\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftInputForm = SearchcraftInput;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftInputForm, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-input-form.js.map","import { S as SearchcraftInputLabel$1, d as defineCustomElement$1 } from './p-bd5fede3.js';\n\nconst SearchcraftInputLabel = SearchcraftInputLabel$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftInputLabel, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-input-label.js.map","import { p as proxyCustomElement, H, h } from './p-e4846fa2.js';\nimport { u as useSearchcraftStore } from './p-ad4ebde0.js';\nimport { f as formatNumberWithCommas } from './p-f308d05d.js';\n\nconst searchcraftResultsInfoModuleCss = \":root{--sc-spinner-size:20px;--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}.searchcraft-results-info-container{border-bottom:1px solid var(--sc-surface-disabled);display:flex;justify-content:flex-start}.searchcraft-results-info-content{color:var(--sc-content-primary);font-family:var(--sc-font-family);font-size:18px;font-weight:600;line-height:20px;margin:0px 0 8px}@media (max-width: 900px){.searchcraft-results-info-content{margin:0;margin-bottom:8px}}\";\nconst SearchcraftResultsInfoStyle0 = searchcraftResultsInfoModuleCss;\n\nconst SearchcraftResultsInfo$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftResultsInfo extends H {\n constructor() {\n super();\n this.__registerHost();\n this.isRequesting = false;\n this.resultsCount = 0;\n this.responseTime = '';\n this.query = '';\n }\n connectedCallback() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n var _a, _b, _c, _d;\n this.isRequesting = state.isRequesting;\n this.resultsCount = ((_b = (_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.count) || 0;\n this.responseTime = ((((_d = (_c = state.searchResults) === null || _c === void 0 ? void 0 : _c.data) === null || _d === void 0 ? void 0 : _d.time_taken) || 0) * 1000).toFixed(2);\n this.query = state.query || '';\n });\n }\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n const formattedResults = formatNumberWithCommas(this.resultsCount);\n return (h(\"div\", { class: 'searchcraft-results-info-container' }, h(\"p\", { class: 'searchcraft-results-info-content' }, formattedResults, \" results found in \", this.responseTime, \"ms\")));\n }\n static get style() { return SearchcraftResultsInfoStyle0; }\n}, [0, \"searchcraft-results-info\", {\n \"isRequesting\": [32],\n \"resultsCount\": [32],\n \"responseTime\": [32],\n \"query\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-results-info\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-results-info\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftResultsInfo$1);\n }\n break;\n } });\n}\n\nconst SearchcraftResultsInfo = SearchcraftResultsInfo$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftResultsInfo, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-results-info.js.map","import { S as SearchcraftSlider$1, d as defineCustomElement$1 } from './p-5380505b.js';\n\nconst SearchcraftSlider = SearchcraftSlider$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftSlider, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-slider.js.map","import { S as SearchcraftToggleButton$1, d as defineCustomElement$1 } from './p-a23d2994.js';\n\nconst SearchcraftToggleButton = SearchcraftToggleButton$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftToggleButton, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-toggle-button.js.map","/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst e=new Set([\"children\",\"localName\",\"ref\",\"style\",\"className\"]),n=new WeakMap,t=(e,t,o,l,a)=>{const s=a?.[t];void 0===s?(e[t]=o,null==o&&t in HTMLElement.prototype&&e.removeAttribute(t)):o!==l&&((e,t,o)=>{let l=n.get(e);void 0===l&&n.set(e,l=new Map);let a=l.get(t);void 0!==o?void 0===a?(l.set(t,a={handleEvent:o}),e.addEventListener(t,a)):a.handleEvent=o:void 0!==a&&(l.delete(t),e.removeEventListener(t,a))})(e,s,o)},o=({react:n,tagName:o,elementClass:l,events:a,displayName:s})=>{const c=new Set(Object.keys(a??{})),r=n.forwardRef(((s,r)=>{const i=n.useRef(new Map),d=n.useRef(null),f={},u={};for(const[n,t]of Object.entries(s))e.has(n)?f[\"className\"===n?\"class\":n]=t:c.has(n)||n in l.prototype?u[n]=t:f[n]=t;return n.useLayoutEffect((()=>{if(null===d.current)return;const e=new Map;for(const n in u)t(d.current,n,s[n],i.current.get(n),a),i.current.delete(n),e.set(n,s[n]);for(const[e,n]of i.current)t(d.current,e,void 0,n,a);i.current=e})),n.useLayoutEffect((()=>{d.current?.removeAttribute(\"defer-hydration\")}),[]),f.suppressHydrationWarning=!0,n.createElement(o,{...f,ref:n.useCallback((e=>{d.current=e,\"function\"==typeof r?r(e):null!==r&&(r.current=e)}),[r])})}));return r.displayName=s??l.name,r};export{o as createComponent};\n//# sourceMappingURL=create-component.js.map\n","import { createComponent as a } from \"@lit/react\";\nconst i = ({\n defineCustomElement: e,\n ...r\n}) => (typeof e < \"u\" && e(), a(r)), p = ({\n hydrateModule: e,\n properties: r,\n tagName: n\n}) => async (t) => {\n const { createComponentForServerSideRendering: o } = await import(\"./ssr.js\");\n return o({\n tagName: n,\n properties: r,\n renderToString: (await e).renderToString\n })(t);\n};\nexport {\n i as createComponent,\n p as createSSRComponent\n};\n","'use client';\n\n/**\n * This file was automatically generated by the Stencil React Output Target.\n * Changes to this file may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\n/* eslint-disable */\n\nimport { SearchcraftBaseSearchResult as SearchcraftBaseSearchResultElement, defineCustomElement as defineSearchcraftBaseSearchResult } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-base-search-result.js\";\nimport { SearchcraftBaseSearchResults as SearchcraftBaseSearchResultsElement, defineCustomElement as defineSearchcraftBaseSearchResults } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-base-search-results.js\";\nimport { SearchcraftButton as SearchcraftButtonElement, defineCustomElement as defineSearchcraftButton } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-button.js\";\nimport { SearchcraftErrorMessage as SearchcraftErrorMessageElement, defineCustomElement as defineSearchcraftErrorMessage } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-error-message.js\";\nimport { SearchcraftFacetList as SearchcraftFacetListElement, defineCustomElement as defineSearchcraftFacetList } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-facet-list.js\";\nimport { SearchcraftFilterPanel as SearchcraftFilterPanelElement, defineCustomElement as defineSearchcraftFilterPanel } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-filter-panel.js\";\nimport { SearchcraftInputForm as SearchcraftInputFormElement, defineCustomElement as defineSearchcraftInputForm } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-input-form.js\";\nimport { SearchcraftInputLabel as SearchcraftInputLabelElement, defineCustomElement as defineSearchcraftInputLabel } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-input-label.js\";\nimport { SearchcraftPopoverForm as SearchcraftPopoverFormElement, defineCustomElement as defineSearchcraftPopoverForm } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-form.js\";\nimport { SearchcraftPopoverListView as SearchcraftPopoverListViewElement, defineCustomElement as defineSearchcraftPopoverListView } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-list-view.js\";\nimport { SearchcraftPopoverResult as SearchcraftPopoverResultElement, defineCustomElement as defineSearchcraftPopoverResult } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-result.js\";\nimport { SearchcraftResultsInfo as SearchcraftResultsInfoElement, defineCustomElement as defineSearchcraftResultsInfo } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-results-info.js\";\nimport { SearchcraftSlider as SearchcraftSliderElement, defineCustomElement as defineSearchcraftSlider } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-slider.js\";\nimport { SearchcraftToggleButton as SearchcraftToggleButtonElement, defineCustomElement as defineSearchcraftToggleButton } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-toggle-button.js\";\nimport type { EventName, StencilReactComponent } from '@stencil/react-output-target/runtime';\nimport { createComponent } from '@stencil/react-output-target/runtime';\nimport React from 'react';\n\ntype SearchcraftBaseSearchResultEvents = NonNullable<unknown>;\n\nexport const SearchcraftBaseSearchResult: StencilReactComponent<SearchcraftBaseSearchResultElement, SearchcraftBaseSearchResultEvents> = /*@__PURE__*/ createComponent<SearchcraftBaseSearchResultElement, SearchcraftBaseSearchResultEvents>({\n tagName: 'searchcraft-base-search-result',\n elementClass: SearchcraftBaseSearchResultElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftBaseSearchResultEvents,\n defineCustomElement: defineSearchcraftBaseSearchResult\n});\n\ntype SearchcraftBaseSearchResultsEvents = { onNoResults: EventName<CustomEvent<void>> };\n\nexport const SearchcraftBaseSearchResults: StencilReactComponent<SearchcraftBaseSearchResultsElement, SearchcraftBaseSearchResultsEvents> = /*@__PURE__*/ createComponent<SearchcraftBaseSearchResultsElement, SearchcraftBaseSearchResultsEvents>({\n tagName: 'searchcraft-base-search-results',\n elementClass: SearchcraftBaseSearchResultsElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onNoResults: 'noResults' } as SearchcraftBaseSearchResultsEvents,\n defineCustomElement: defineSearchcraftBaseSearchResults\n});\n\ntype SearchcraftButtonEvents = { onButtonClick: EventName<CustomEvent<void>> };\n\nexport const SearchcraftButton: StencilReactComponent<SearchcraftButtonElement, SearchcraftButtonEvents> = /*@__PURE__*/ createComponent<SearchcraftButtonElement, SearchcraftButtonEvents>({\n tagName: 'searchcraft-button',\n elementClass: SearchcraftButtonElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onButtonClick: 'buttonClick' } as SearchcraftButtonEvents,\n defineCustomElement: defineSearchcraftButton\n});\n\ntype SearchcraftErrorMessageEvents = NonNullable<unknown>;\n\nexport const SearchcraftErrorMessage: StencilReactComponent<SearchcraftErrorMessageElement, SearchcraftErrorMessageEvents> = /*@__PURE__*/ createComponent<SearchcraftErrorMessageElement, SearchcraftErrorMessageEvents>({\n tagName: 'searchcraft-error-message',\n elementClass: SearchcraftErrorMessageElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftErrorMessageEvents,\n defineCustomElement: defineSearchcraftErrorMessage\n});\n\ntype SearchcraftFacetListEvents = { onFacetSelectionUpdated: EventName<CustomEvent<{ paths: string[] }>> };\n\nexport const SearchcraftFacetList: StencilReactComponent<SearchcraftFacetListElement, SearchcraftFacetListEvents> = /*@__PURE__*/ createComponent<SearchcraftFacetListElement, SearchcraftFacetListEvents>({\n tagName: 'searchcraft-facet-list',\n elementClass: SearchcraftFacetListElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onFacetSelectionUpdated: 'facetSelectionUpdated' } as SearchcraftFacetListEvents,\n defineCustomElement: defineSearchcraftFacetList\n});\n\ntype SearchcraftFilterPanelEvents = NonNullable<unknown>;\n\nexport const SearchcraftFilterPanel: StencilReactComponent<SearchcraftFilterPanelElement, SearchcraftFilterPanelEvents> = /*@__PURE__*/ createComponent<SearchcraftFilterPanelElement, SearchcraftFilterPanelEvents>({\n tagName: 'searchcraft-filter-panel',\n elementClass: SearchcraftFilterPanelElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftFilterPanelEvents,\n defineCustomElement: defineSearchcraftFilterPanel\n});\n\ntype SearchcraftInputFormEvents = {\n onInputCleared: EventName<CustomEvent<void>>,\n onNoResultsReceived: EventName<CustomEvent<void>>,\n onQuerySubmit: EventName<CustomEvent<string>>,\n onInputFocus: EventName<CustomEvent<void>>,\n onInputBlur: EventName<CustomEvent<void>>\n};\n\nexport const SearchcraftInputForm: StencilReactComponent<SearchcraftInputFormElement, SearchcraftInputFormEvents> = /*@__PURE__*/ createComponent<SearchcraftInputFormElement, SearchcraftInputFormEvents>({\n tagName: 'searchcraft-input-form',\n elementClass: SearchcraftInputFormElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {\n onInputCleared: 'inputCleared',\n onNoResultsReceived: 'noResultsReceived',\n onQuerySubmit: 'querySubmit',\n onInputFocus: 'inputFocus',\n onInputBlur: 'inputBlur'\n } as SearchcraftInputFormEvents,\n defineCustomElement: defineSearchcraftInputForm\n});\n\ntype SearchcraftInputLabelEvents = NonNullable<unknown>;\n\nexport const SearchcraftInputLabel: StencilReactComponent<SearchcraftInputLabelElement, SearchcraftInputLabelEvents> = /*@__PURE__*/ createComponent<SearchcraftInputLabelElement, SearchcraftInputLabelEvents>({\n tagName: 'searchcraft-input-label',\n elementClass: SearchcraftInputLabelElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftInputLabelEvents,\n defineCustomElement: defineSearchcraftInputLabel\n});\n\ntype SearchcraftPopoverFormEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverForm: StencilReactComponent<SearchcraftPopoverFormElement, SearchcraftPopoverFormEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverFormElement, SearchcraftPopoverFormEvents>({\n tagName: 'searchcraft-popover-form',\n elementClass: SearchcraftPopoverFormElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverFormEvents,\n defineCustomElement: defineSearchcraftPopoverForm\n});\n\ntype SearchcraftPopoverListViewEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverListView: StencilReactComponent<SearchcraftPopoverListViewElement, SearchcraftPopoverListViewEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverListViewElement, SearchcraftPopoverListViewEvents>({\n tagName: 'searchcraft-popover-list-view',\n elementClass: SearchcraftPopoverListViewElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverListViewEvents,\n defineCustomElement: defineSearchcraftPopoverListView\n});\n\ntype SearchcraftPopoverResultEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverResult: StencilReactComponent<SearchcraftPopoverResultElement, SearchcraftPopoverResultEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverResultElement, SearchcraftPopoverResultEvents>({\n tagName: 'searchcraft-popover-result',\n elementClass: SearchcraftPopoverResultElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverResultEvents,\n defineCustomElement: defineSearchcraftPopoverResult\n});\n\ntype SearchcraftResultsInfoEvents = NonNullable<unknown>;\n\nexport const SearchcraftResultsInfo: StencilReactComponent<SearchcraftResultsInfoElement, SearchcraftResultsInfoEvents> = /*@__PURE__*/ createComponent<SearchcraftResultsInfoElement, SearchcraftResultsInfoEvents>({\n tagName: 'searchcraft-results-info',\n elementClass: SearchcraftResultsInfoElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftResultsInfoEvents,\n defineCustomElement: defineSearchcraftResultsInfo\n});\n\ntype SearchcraftSliderEvents = { onRangeChanged: EventName<CustomEvent<{ startValue: number; endValue: number }>> };\n\nexport const SearchcraftSlider: StencilReactComponent<SearchcraftSliderElement, SearchcraftSliderEvents> = /*@__PURE__*/ createComponent<SearchcraftSliderElement, SearchcraftSliderEvents>({\n tagName: 'searchcraft-slider',\n elementClass: SearchcraftSliderElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onRangeChanged: 'rangeChanged' } as SearchcraftSliderEvents,\n defineCustomElement: defineSearchcraftSlider\n});\n\ntype SearchcraftToggleButtonEvents = { onToggleUpdated: EventName<CustomEvent<boolean>> };\n\nexport const SearchcraftToggleButton: StencilReactComponent<SearchcraftToggleButtonElement, SearchcraftToggleButtonEvents> = /*@__PURE__*/ createComponent<SearchcraftToggleButtonElement, SearchcraftToggleButtonEvents>({\n tagName: 'searchcraft-toggle-button',\n elementClass: SearchcraftToggleButtonElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onToggleUpdated: 'toggleUpdated' } as SearchcraftToggleButtonEvents,\n defineCustomElement: defineSearchcraftToggleButton\n});\n","import type { FC } from 'react';\n\nimport { SearchcraftBaseSearchResult as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftBaseSearchResultProps\n extends Components.SearchcraftBaseSearchResult {}\n\nconst SearchcraftBaseSearchResult: FC<SearchcraftBaseSearchResultProps> = (\n props,\n) => <Component {...props} />;\n\nexport { SearchcraftBaseSearchResult };\nexport type { SearchcraftBaseSearchResultProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftBaseSearchResults as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftBaseSearchResultsProps\n extends Components.SearchcraftBaseSearchResults {}\n\nconst SearchcraftBaseSearchResults: FC<SearchcraftBaseSearchResultsProps> = (\n props,\n) => <Component {...props} />;\n\nexport { SearchcraftBaseSearchResults };\nexport type { SearchcraftBaseSearchResultsProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftButton as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftButtonProps extends Components.SearchcraftButton {}\n\nconst SearchcraftButton: FC<SearchcraftButtonProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftButton };\nexport type { SearchcraftButtonProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftErrorMessage as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftErrorMessageProps\n extends Components.SearchcraftErrorMessage {}\n\nconst SearchcraftErrorMessage: FC<SearchcraftErrorMessageProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftErrorMessage };\nexport type { SearchcraftErrorMessageProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftFacetList as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftFacetListProps extends Components.SearchcraftFacetList {}\n\nconst SearchcraftFacetList: FC<SearchcraftFacetListProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftFacetList };\nexport type { SearchcraftFacetListProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftFilterPanel as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftFilterPanelProps\n extends Components.SearchcraftFilterPanel {}\n\nconst SearchcraftFilterPanel: FC<SearchcraftFilterPanelProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftFilterPanel };\nexport type { SearchcraftFilterPanelProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftInputForm as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftInputFormProps extends Components.SearchcraftInputForm {}\n\nconst SearchcraftInputForm: FC<SearchcraftInputFormProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftInputForm };\nexport type { SearchcraftInputFormProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftInputLabel as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftInputLabelProps extends Components.SearchcraftInputLabel {}\n\nconst SearchcraftInputLabel: FC<SearchcraftInputLabelProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftInputLabel };\nexport type { SearchcraftInputLabelProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftResultsInfo as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftResultsInfoProps\n extends Components.SearchcraftResultsInfo {}\n\nconst SearchcraftResultsInfo: FC<SearchcraftResultsInfoProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftResultsInfo };\nexport type { SearchcraftResultsInfoProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftSlider as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftSliderProps extends Components.SearchcraftSlider {}\n\nconst SearchcraftSlider: FC<SearchcraftSliderProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftSlider };\nexport type { SearchcraftSliderProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftToggleButton as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftToggleButtonProps\n extends Components.SearchcraftToggleButton {}\n\nconst SearchcraftToggleButton: FC<SearchcraftToggleButtonProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftToggleButton };\nexport type { SearchcraftToggleButtonProps };\n"],"names":["NAMESPACE","BUILD","__defProp","__export","target","all","name","hostRefs","getHostRef","ref","registerHost","hostElement","cmpMeta","hostRef","r","isMemberInElement","elm","memberName","consoleError","el","styles","SLOT_FB_CSS","win","doc","H","plt","h2","eventName","listener","opts","supportsShadow","promiseResolve","v","supportsConstructableStylesheets","queuePending","queueDomReads","queueDomWrites","queueTask","queue","write","cb","nextTick","flush","consume","i2","e","writeTask","EMPTY_OBJ","SVG_NS","HTML_NS","isComplexType","o","queryNonceMetaTagContent","doc2","_a","_b","_c","result_exports","err","map","ok","unwrap","unwrapErr","value","result","fn","val","newVal","createTime","fnName","tagName","h","nodeName","vnodeData","children","child","key","slotName","simple","lastSimple","vNodeChildren","walk","c","newVNode","classData","k","vdomFnUtils","vnode","tag","text","Host","isHost","node","convertToPublic","convertToPrivate","parsePropertyValue","propValue","propType","getElement","createEvent","flags","detail","emitEvent","ev","rootAppliedStyles","registerStyle","scopeId2","cssText","allowCS","style","addStyle","styleContainerNode","mode","getScopeId","appliedStyles","styleElm","nonce","preconnectLinks","referenceNode2","stylesheet","existingStyleContainer","attachStyles","endAttachStyles","cmp","setAccessor","oldValue","newValue","isSvg","isProp","ln","classList","oldClasses","parseClassList","newClasses","prop","capture","CAPTURE_EVENT_SUFFIX","CAPTURE_EVENT_REGEX","isComplex","n","parseClassListRegex","updateElement","oldVnode","newVnode","isSvgMode2","oldVnodeAttrs","newVnodeAttrs","sortedAttrNames","attrNames","attr","contentRef","hostTagName","useNativeShadowDom","checkSlotFallbackVisibility","checkSlotRelocate","isSvgMode","createElm","oldParentVNode","newParentVNode","childIndex","parentElm","newVNode2","childNode","oldVNode","putBackInOriginalLocation","recursive","oldSlotChildNodes","insertBefore","parentReferenceNode","referenceNode","addVnodes","before","parentVNode","vnodes","startIdx","endIdx","containerElm","removeVnodes","index","updateChildren","oldCh","newCh","isInitialRender","oldStartIdx","newStartIdx","idxInOld","oldEndIdx","oldStartVnode","oldEndVnode","newEndIdx","newStartVnode","newEndVnode","elmToMove","isSameVnode","patch","leftVNode","rightVNode","oldChildren","newChildren","defaultHolder","updateFallbackSlotVisibility","childNodes","siblingNode","relocateNodes","markSlotContentForRelocation","hostContentNodes","j","isNodeLocatedInSlot","relocateNodeData","relocateNode","nodeToRelocate","parent","newNode","reference","renderVdom","renderFnResults","isInitialLoad","_d","hostElm","rootVnode","relocateData","orgLocationNode","slotRefNode","parentNodeRef","insertBeforeNode","refNode","attachToAncestor","ancestorComponent","scheduleUpdate","dispatchHooks","endSchedule","instance","maybePromise","enqueue","updateComponent","isPromisey","err2","endUpdate","rc","endRender","callRender","childrenPromises","postUpdate","postUpdateComponent","endPostUpdate","addHydratedFlag","safeCall","appDidLoad","who","method","arg","getValue","propName","setValue","oldVal","areBothNaN","watchMethods","watchMethodName","proxyComponent","Cstr","prototype","members","memberFlags","attrNameToPropName","attrName","_a2","flags2","entry","callbackName","_","m","initializeComponent","hmrVersionId","cmpTag","endRegisterStyles","schedule","fireConnectedCallback","connectedCallback","endConnected","setContentReference","contentRefElm","disconnectedCallback","proxyCustomElement","compactMeta","originalConnectedCallback","originalDisconnectedCallback","hasHostListenerAttached","Fragment","zustand","vanilla$1","createStoreImpl","createState","state","listeners","setState","partial","replace","nextState","previousState","getState","api","initialState","createStore","react$1","react","react_production_min","l$1","p$1","q$1","t","u","v$1","w$1","x","y$1","z$1","A$1","a","B$1","C$1","D$1","E$1","b","F$1","G$1","H$1","I$1","J$1","K$1","L$1","M$1","d","g","f","N$1","O$1","escape","P$1","Q$1","R","S$1","T$1","U","V$1","W$1","X$1","React","vanilla","identity","useStore","selector","slice","createImpl","useBoundStore","create","exports","D","B","p","L","N","w","s","i","y","T","q","M","I","G","W","V","F","$","K","E","z","C","A","J","Y","P","Q","X","Z","ee","te","ne","l","S","ie","O","ae","useSearchcraftStore","set","get","searchcraft","debuggerInstance","log","level","message","data","fieldName","currentPaths","currentValues","type","query","results","facets","isRequesting","updatedFacets","error","searchcraftInstance","debug","searchcraftBaseSearchResultModuleCss","SearchcraftBaseSearchResultStyle0","SearchcraftBaseSearchResult","document_position","search_term","number_of_documents","imageContainer","contentContainer","defineCustomElement","SearchcraftBaseSearchResult$1","defineCustomElement$1","parseCustomStyles","serializeStyles","getFormattedTimeFromNow","timestamp","now","inputTime","diffInSeconds","minutes","hours","days","years","formatNumberWithCommas","number","getMillis","unit","removeSubstringMatches","arr","array","otherEntry","otherIndex","getDocumentValueFromSearchResultMapping","document","mapping","fieldNameDetails","valueFound","deepMergeWithSpread","obj1","obj2","facetToRecord","facet","records","traverseAndAddToFragments","facetChild","recordToObject","record","root","fragment","pathParts","currentRoot","currentPath","part","nextPath","objectToFacet","childObject","transformed","subChildObject","filterRecordByParentPaths","record1","record2","paths1","paths2","parentPaths","path","mergeFacetRoots","incomingRoot","currentArray","incomingArray","currentRootFacetChild","incomingRootFacetChild","currentRecord","incomingRecord","filteredCurrentRecord","mergedRecord","mergedObject","mergedFacetChild","searchcraftErrorMessageModuleCss","SearchcraftErrorMessageStyle0","SearchcraftErrorMessage","searchcraftBaseSearchResultsModuleCss","SearchcraftBaseSearchResultsStyle0","SearchcraftBaseSearchResults$1","searchResults","titleContent","subtitleContent","bodyContent","containerHref","buttonHref","imageSource","footerContent","serializedStyles","_e","_f","_g","_h","_j","_k","documents","_index","finalComponents","documentElements","defineCustomElement$3","defineCustomElement$2","SearchcraftBaseSearchResults","classnames","module","hasOwn","classNames","classes","appendClass","parseValue","newClass","searchcraftButtonModuleCss","SearchcraftButtonStyle0","SearchcraftButton","SearchcraftButton$1","SearchcraftErrorMessage$1","searchcraftFacetListModuleCss","SearchcraftFacetListStyle0","SearchcraftFacetList","label","count","char","facetChildAncestor","facetPrime","timeTaken","incomingFacetRoot","updatedPaths","testPath","acc","str","paths","pathsWithParentPathsRemoved","firstFacet","isChildSelected","_event","grandchild","SearchcraftFacetList$1","searchcraftSliderModuleCss","SearchcraftSliderStyle0","SearchcraftSlider","event","inputElement","rangeMin","rangeMax","startPercent","endPercent","startLabel","endLabel","searchcraftToggleButtonModuleCss","SearchcraftToggleButtonStyle0","SearchcraftToggleButton","searchcraftFilterPanelModuleCss","SearchcraftFilterPanelStyle0","SearchcraftFilterPanel$1","min","max","start","end","isActive","filterItem","item","granularityValue","defineCustomElement$4","SearchcraftFilterPanel","searchcraftInputLabelModuleCss","SearchcraftInputLabelStyle0","SearchcraftInputLabel","version","description","author","license","main","types","collection","unpkg","repository","files","scripts","dependencies","devDependencies","packageJson","searchcraftInputFormModuleCss","SearchcraftInputFormStyle0","SearchcraftInput","input","validatedCustomStyles","isShowingClearButton","inputGridClassNames","SearchcraftInputForm","SearchcraftInputLabel$1","searchcraftResultsInfoModuleCss","SearchcraftResultsInfoStyle0","SearchcraftResultsInfo$1","formattedResults","SearchcraftResultsInfo","SearchcraftSlider$1","SearchcraftToggleButton$1","createComponent","SearchcraftBaseSearchResultElement","defineSearchcraftBaseSearchResult","SearchcraftBaseSearchResultsElement","defineSearchcraftBaseSearchResults","SearchcraftButtonElement","defineSearchcraftButton","SearchcraftErrorMessageElement","defineSearchcraftErrorMessage","SearchcraftFacetListElement","defineSearchcraftFacetList","SearchcraftFilterPanelElement","defineSearchcraftFilterPanel","SearchcraftInputFormElement","defineSearchcraftInputForm","SearchcraftInputLabelElement","defineSearchcraftInputLabel","SearchcraftResultsInfoElement","defineSearchcraftResultsInfo","SearchcraftSliderElement","define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D,gBAAAC,EAAAC,IAAA,EAAW,GAAGF,EAAO,CAAA,GCAlB1B,KAA0D,CAAC0B,MAC9D,gBAAAC,EAAAC,IAAA,EAAW,GAAGF,EAAO,CAAA,GCFlBjF,KAAgD,CAACiF,MACpD,gBAAAC,EAAAC,IAAA,EAAW,GAAGF,EAAO,CAAA,GCAlBtE,KAA4D,CAACsE,MAChE,gBAAAC,EAAAC,IAAA,EAAW,GAAGF,EAAO,CAAA;","x_google_ignoreList":[22,23]}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../javascript-sdk/dist/components/p-6cafd48d.js","../../javascript-sdk/dist/components/p-01dc5b3b.js","../../javascript-sdk/dist/components/p-87d1611b.js","../../javascript-sdk/dist/components/searchcraft-base-search-result.js","../../javascript-sdk/dist/components/p-755f491b.js","../../javascript-sdk/dist/components/p-d9551738.js","../../javascript-sdk/dist/components/p-f5a06210.js","../../javascript-sdk/dist/components/searchcraft-base-search-results.js","../../javascript-sdk/dist/components/p-5cdc6210.js","../../javascript-sdk/dist/components/p-cf096782.js","../../javascript-sdk/dist/components/searchcraft-button.js","../../javascript-sdk/dist/components/searchcraft-error-message.js","../../javascript-sdk/dist/components/p-649654b5.js","../../javascript-sdk/dist/components/searchcraft-facet-list.js","../../javascript-sdk/dist/components/p-cc9f8c61.js","../../javascript-sdk/dist/components/p-662cb490.js","../../javascript-sdk/dist/components/searchcraft-filter-panel.js","../../javascript-sdk/dist/components/p-c273e43d.js","../../javascript-sdk/dist/components/p-da5b92ef.js","../../javascript-sdk/dist/components/searchcraft-input-form.js","../../javascript-sdk/dist/components/searchcraft-input-label.js","../../javascript-sdk/dist/components/searchcraft-popover-button.js","../../javascript-sdk/dist/components/p-1ae87308.js","../../javascript-sdk/dist/components/p-e1cf5f9d.js","../../javascript-sdk/dist/components/searchcraft-popover-form.js","../../javascript-sdk/dist/components/searchcraft-results-info.js","../../javascript-sdk/dist/components/searchcraft-slider.js","../../javascript-sdk/dist/components/searchcraft-toggle-button.js","../../../node_modules/@lit/react/create-component.js","../../../node_modules/@stencil/react-output-target/dist/react.js","../src/stencil-web-components/components.ts","../src/components/SearchcraftBaseSearchResult.tsx","../src/components/SearchcraftBaseSearchResults.tsx","../src/components/SearchcraftButton.tsx","../src/components/SearchcraftErrorMessage.tsx","../src/components/SearchcraftFacetList.tsx","../src/components/SearchcraftFilterPanel.tsx","../src/components/SearchcraftInputForm.tsx","../src/components/SearchcraftInputLabel.tsx","../src/components/SearchcraftPopoverButton.tsx","../src/components/SearchcraftPopoverForm.tsx","../src/components/SearchcraftResultsInfo.tsx","../src/components/SearchcraftSlider.tsx","../src/components/SearchcraftToggleButton.tsx"],"sourcesContent":["const NAMESPACE = 'searchcraft-javascript-sdk';\nconst BUILD = /* searchcraft-javascript-sdk */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: \"hydrated\", invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: false, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: false, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: false, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: true, taskQueue: true, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: true, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };\n\n/*\n Stencil Client Platform v4.25.0 | MIT Licensed | https://stenciljs.com\n */\nvar __defProp = Object.defineProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\n\n// src/utils/constants.ts\nvar SVG_NS = \"http://www.w3.org/2000/svg\";\nvar HTML_NS = \"http://www.w3.org/1999/xhtml\";\n\n// src/client/client-host-ref.ts\nvar hostRefs = /* @__PURE__ */ new WeakMap();\nvar deleteHostRef = (ref) => hostRefs.delete(ref);\nvar getHostRef = (ref) => hostRefs.get(ref);\nvar registerHost = (hostElement, cmpMeta) => {\n const hostRef = {\n $flags$: 0,\n $hostElement$: hostElement,\n $cmpMeta$: cmpMeta,\n $instanceValues$: /* @__PURE__ */ new Map()\n };\n {\n hostRef.$onReadyPromise$ = new Promise((r) => hostRef.$onReadyResolve$ = r);\n hostElement[\"s-p\"] = [];\n hostElement[\"s-rc\"] = [];\n }\n const ref = hostRefs.set(hostElement, hostRef);\n return ref;\n};\nvar isMemberInElement = (elm, memberName) => memberName in elm;\nvar consoleError = (e, el) => (0, console.error)(e, el);\n\n// src/client/client-style.ts\nvar styles = /* @__PURE__ */ new Map();\nvar HYDRATED_STYLE_ID = \"sty-id\";\nvar SLOT_FB_CSS = \"slot-fb{display:contents}slot-fb[hidden]{display:none}\";\nvar win = typeof window !== \"undefined\" ? window : {};\nvar doc = win.document || { head: {} };\nvar H = win.HTMLElement || class {\n};\nvar plt = {\n $flags$: 0,\n $resourcesUrl$: \"\",\n jmp: (h2) => h2(),\n raf: (h2) => requestAnimationFrame(h2),\n ael: (el, eventName, listener, opts) => el.addEventListener(eventName, listener, opts),\n rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),\n ce: (eventName, opts) => new CustomEvent(eventName, opts)\n};\nvar supportsShadow = BUILD.shadowDom;\nvar promiseResolve = (v) => Promise.resolve(v);\nvar supportsConstructableStylesheets = /* @__PURE__ */ (() => {\n try {\n new CSSStyleSheet();\n return typeof new CSSStyleSheet().replaceSync === \"function\";\n } catch (e) {\n }\n return false;\n})() ;\nvar queuePending = false;\nvar queueDomReads = [];\nvar queueDomWrites = [];\nvar queueTask = (queue, write) => (cb) => {\n queue.push(cb);\n if (!queuePending) {\n queuePending = true;\n if (write && plt.$flags$ & 4 /* queueSync */) {\n nextTick(flush);\n } else {\n plt.raf(flush);\n }\n }\n};\nvar consume = (queue) => {\n for (let i2 = 0; i2 < queue.length; i2++) {\n try {\n queue[i2](performance.now());\n } catch (e) {\n consoleError(e);\n }\n }\n queue.length = 0;\n};\nvar flush = () => {\n consume(queueDomReads);\n {\n consume(queueDomWrites);\n if (queuePending = queueDomReads.length > 0) {\n plt.raf(flush);\n }\n }\n};\nvar nextTick = (cb) => promiseResolve().then(cb);\nvar writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);\n\n// src/runtime/asset-path.ts\nvar getAssetPath = (path) => {\n const assetUrl = new URL(path, plt.$resourcesUrl$);\n return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;\n};\nvar setAssetPath = (path) => plt.$resourcesUrl$ = path;\nvar isComplexType = (o) => {\n o = typeof o;\n return o === \"object\" || o === \"function\";\n};\n\n// src/utils/query-nonce-meta-tag-content.ts\nfunction queryNonceMetaTagContent(doc2) {\n var _a, _b, _c;\n return (_c = (_b = (_a = doc2.head) == null ? void 0 : _a.querySelector('meta[name=\"csp-nonce\"]')) == null ? void 0 : _b.getAttribute(\"content\")) != null ? _c : void 0;\n}\n\n// src/utils/result.ts\nvar result_exports = {};\n__export(result_exports, {\n err: () => err,\n map: () => map,\n ok: () => ok,\n unwrap: () => unwrap,\n unwrapErr: () => unwrapErr\n});\nvar ok = (value) => ({\n isOk: true,\n isErr: false,\n value\n});\nvar err = (value) => ({\n isOk: false,\n isErr: true,\n value\n});\nfunction map(result, fn) {\n if (result.isOk) {\n const val = fn(result.value);\n if (val instanceof Promise) {\n return val.then((newVal) => ok(newVal));\n } else {\n return ok(val);\n }\n }\n if (result.isErr) {\n const value = result.value;\n return err(value);\n }\n throw \"should never get here\";\n}\nvar unwrap = (result) => {\n if (result.isOk) {\n return result.value;\n } else {\n throw result.value;\n }\n};\nvar unwrapErr = (result) => {\n if (result.isErr) {\n return result.value;\n } else {\n throw result.value;\n }\n};\nvar updateFallbackSlotVisibility = (elm) => {\n const childNodes = elm.__childNodes || elm.childNodes;\n if (elm.tagName && elm.tagName.includes(\"-\") && elm[\"s-cr\"] && elm.tagName !== \"SLOT-FB\") {\n getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {\n var _a;\n if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === \"SLOT-FB\") {\n if ((_a = getHostSlotChildNodes(slotNode, slotNode[\"s-sn\"], false)) == null ? void 0 : _a.length) {\n slotNode.hidden = true;\n } else {\n slotNode.hidden = false;\n }\n }\n });\n }\n for (const childNode of childNodes) {\n if (childNode.nodeType === 1 /* ElementNode */ && (childNode.__childNodes || childNode.childNodes).length) {\n updateFallbackSlotVisibility(childNode);\n }\n }\n};\nfunction getHostSlotNodes(childNodes, hostName, slotName) {\n let i2 = 0;\n let slottedNodes = [];\n let childNode;\n for (; i2 < childNodes.length; i2++) {\n childNode = childNodes[i2];\n if (childNode[\"s-sr\"] && childNode[\"s-hn\"] === hostName && (slotName === void 0 || childNode[\"s-sn\"] === slotName)) {\n slottedNodes.push(childNode);\n if (typeof slotName !== \"undefined\") return slottedNodes;\n }\n slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];\n }\n return slottedNodes;\n}\nvar getHostSlotChildNodes = (node, slotName, includeSlot = true) => {\n const childNodes = [];\n if (includeSlot && node[\"s-sr\"] || !node[\"s-sr\"]) childNodes.push(node);\n while ((node = node.nextSibling) && node[\"s-sn\"] === slotName) {\n childNodes.push(node);\n }\n return childNodes;\n};\nvar isNodeLocatedInSlot = (nodeToRelocate, slotName) => {\n if (nodeToRelocate.nodeType === 1 /* ElementNode */) {\n if (nodeToRelocate.getAttribute(\"slot\") === null && slotName === \"\") {\n return true;\n }\n if (nodeToRelocate.getAttribute(\"slot\") === slotName) {\n return true;\n }\n return false;\n }\n if (nodeToRelocate[\"s-sn\"] === slotName) {\n return true;\n }\n return slotName === \"\";\n};\nvar createTime = (fnName, tagName = \"\") => {\n {\n return () => {\n return;\n };\n }\n};\nvar h = (nodeName, vnodeData, ...children) => {\n let child = null;\n let key = null;\n let slotName = null;\n let simple = false;\n let lastSimple = false;\n const vNodeChildren = [];\n const walk = (c) => {\n for (let i2 = 0; i2 < c.length; i2++) {\n child = c[i2];\n if (Array.isArray(child)) {\n walk(child);\n } else if (child != null && typeof child !== \"boolean\") {\n if (simple = typeof nodeName !== \"function\" && !isComplexType(child)) {\n child = String(child);\n }\n if (simple && lastSimple) {\n vNodeChildren[vNodeChildren.length - 1].$text$ += child;\n } else {\n vNodeChildren.push(simple ? newVNode(null, child) : child);\n }\n lastSimple = simple;\n }\n }\n };\n walk(children);\n if (vnodeData) {\n if (vnodeData.key) {\n key = vnodeData.key;\n }\n if (vnodeData.name) {\n slotName = vnodeData.name;\n }\n {\n const classData = vnodeData.className || vnodeData.class;\n if (classData) {\n vnodeData.class = typeof classData !== \"object\" ? classData : Object.keys(classData).filter((k) => classData[k]).join(\" \");\n }\n }\n }\n if (typeof nodeName === \"function\") {\n return nodeName(\n vnodeData === null ? {} : vnodeData,\n vNodeChildren,\n vdomFnUtils\n );\n }\n const vnode = newVNode(nodeName, null);\n vnode.$attrs$ = vnodeData;\n if (vNodeChildren.length > 0) {\n vnode.$children$ = vNodeChildren;\n }\n {\n vnode.$key$ = key;\n }\n {\n vnode.$name$ = slotName;\n }\n return vnode;\n};\nvar newVNode = (tag, text) => {\n const vnode = {\n $flags$: 0,\n $tag$: tag,\n $text$: text,\n $elm$: null,\n $children$: null\n };\n {\n vnode.$attrs$ = null;\n }\n {\n vnode.$key$ = null;\n }\n {\n vnode.$name$ = null;\n }\n return vnode;\n};\nvar Host = {};\nvar isHost = (node) => node && node.$tag$ === Host;\nvar vdomFnUtils = {\n forEach: (children, cb) => children.map(convertToPublic).forEach(cb),\n map: (children, cb) => children.map(convertToPublic).map(cb).map(convertToPrivate)\n};\nvar convertToPublic = (node) => ({\n vattrs: node.$attrs$,\n vchildren: node.$children$,\n vkey: node.$key$,\n vname: node.$name$,\n vtag: node.$tag$,\n vtext: node.$text$\n});\nvar convertToPrivate = (node) => {\n if (typeof node.vtag === \"function\") {\n const vnodeData = { ...node.vattrs };\n if (node.vkey) {\n vnodeData.key = node.vkey;\n }\n if (node.vname) {\n vnodeData.name = node.vname;\n }\n return h(node.vtag, vnodeData, ...node.vchildren || []);\n }\n const vnode = newVNode(node.vtag, node.vtext);\n vnode.$attrs$ = node.vattrs;\n vnode.$children$ = node.vchildren;\n vnode.$key$ = node.vkey;\n vnode.$name$ = node.vname;\n return vnode;\n};\nvar parsePropertyValue = (propValue, propType) => {\n if (propValue != null && !isComplexType(propValue)) {\n if (propType & 4 /* Boolean */) {\n return propValue === \"false\" ? false : propValue === \"\" || !!propValue;\n }\n if (propType & 2 /* Number */) {\n return parseFloat(propValue);\n }\n if (propType & 1 /* String */) {\n return String(propValue);\n }\n return propValue;\n }\n return propValue;\n};\nvar getElement = (ref) => ref;\n\n// src/runtime/event-emitter.ts\nvar createEvent = (ref, name, flags) => {\n const elm = getElement(ref);\n return {\n emit: (detail) => {\n return emitEvent(elm, name, {\n bubbles: !!(flags & 4 /* Bubbles */),\n composed: !!(flags & 2 /* Composed */),\n cancelable: !!(flags & 1 /* Cancellable */),\n detail\n });\n }\n };\n};\nvar emitEvent = (elm, name, opts) => {\n const ev = plt.ce(name, opts);\n elm.dispatchEvent(ev);\n return ev;\n};\nvar rootAppliedStyles = /* @__PURE__ */ new WeakMap();\nvar registerStyle = (scopeId2, cssText, allowCS) => {\n let style = styles.get(scopeId2);\n if (supportsConstructableStylesheets && allowCS) {\n style = style || new CSSStyleSheet();\n if (typeof style === \"string\") {\n style = cssText;\n } else {\n style.replaceSync(cssText);\n }\n } else {\n style = cssText;\n }\n styles.set(scopeId2, style);\n};\nvar addStyle = (styleContainerNode, cmpMeta, mode) => {\n var _a;\n const scopeId2 = getScopeId(cmpMeta);\n const style = styles.get(scopeId2);\n styleContainerNode = styleContainerNode.nodeType === 11 /* DocumentFragment */ ? styleContainerNode : doc;\n if (style) {\n if (typeof style === \"string\") {\n styleContainerNode = styleContainerNode.head || styleContainerNode;\n let appliedStyles = rootAppliedStyles.get(styleContainerNode);\n let styleElm;\n if (!appliedStyles) {\n rootAppliedStyles.set(styleContainerNode, appliedStyles = /* @__PURE__ */ new Set());\n }\n if (!appliedStyles.has(scopeId2)) {\n {\n styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}=\"${scopeId2}\"]`) || doc.createElement(\"style\");\n styleElm.innerHTML = style;\n const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);\n if (nonce != null) {\n styleElm.setAttribute(\"nonce\", nonce);\n }\n if (!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */)) {\n if (styleContainerNode.nodeName === \"HEAD\") {\n const preconnectLinks = styleContainerNode.querySelectorAll(\"link[rel=preconnect]\");\n const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector(\"style\");\n styleContainerNode.insertBefore(styleElm, referenceNode2);\n } else if (\"host\" in styleContainerNode) {\n if (supportsConstructableStylesheets) {\n const stylesheet = new CSSStyleSheet();\n stylesheet.replaceSync(style);\n styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];\n } else {\n const existingStyleContainer = styleContainerNode.querySelector(\"style\");\n if (existingStyleContainer) {\n existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;\n } else {\n styleContainerNode.prepend(styleElm);\n }\n }\n } else {\n styleContainerNode.append(styleElm);\n }\n }\n if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */ && styleContainerNode.nodeName !== \"HEAD\") {\n styleContainerNode.insertBefore(styleElm, null);\n }\n }\n if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {\n styleElm.innerHTML += SLOT_FB_CSS;\n }\n if (appliedStyles) {\n appliedStyles.add(scopeId2);\n }\n }\n } else if (!styleContainerNode.adoptedStyleSheets.includes(style)) {\n styleContainerNode.adoptedStyleSheets = [...styleContainerNode.adoptedStyleSheets, style];\n }\n }\n return scopeId2;\n};\nvar attachStyles = (hostRef) => {\n const cmpMeta = hostRef.$cmpMeta$;\n const elm = hostRef.$hostElement$;\n const endAttachStyles = createTime(\"attachStyles\", cmpMeta.$tagName$);\n addStyle(\n elm.getRootNode(),\n cmpMeta);\n endAttachStyles();\n};\nvar getScopeId = (cmp, mode) => \"sc-\" + (cmp.$tagName$);\nvar setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {\n if (oldValue !== newValue) {\n let isProp = isMemberInElement(elm, memberName);\n let ln = memberName.toLowerCase();\n if (memberName === \"class\") {\n const classList = elm.classList;\n const oldClasses = parseClassList(oldValue);\n let newClasses = parseClassList(newValue);\n if (elm[\"s-si\"]) {\n newClasses.push(elm[\"s-si\"]);\n oldClasses.forEach((c) => {\n if (c.startsWith(elm[\"s-si\"])) newClasses.push(c);\n });\n newClasses = [...new Set(newClasses)];\n classList.add(...newClasses);\n delete elm[\"s-si\"];\n } else {\n classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));\n classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));\n }\n } else if (memberName === \"style\") {\n {\n for (const prop in oldValue) {\n if (!newValue || newValue[prop] == null) {\n if (prop.includes(\"-\")) {\n elm.style.removeProperty(prop);\n } else {\n elm.style[prop] = \"\";\n }\n }\n }\n }\n for (const prop in newValue) {\n if (!oldValue || newValue[prop] !== oldValue[prop]) {\n if (prop.includes(\"-\")) {\n elm.style.setProperty(prop, newValue[prop]);\n } else {\n elm.style[prop] = newValue[prop];\n }\n }\n }\n } else if (memberName === \"key\") ; else if ((!elm.__lookupSetter__(memberName)) && memberName[0] === \"o\" && memberName[1] === \"n\") {\n if (memberName[2] === \"-\") {\n memberName = memberName.slice(3);\n } else if (isMemberInElement(win, ln)) {\n memberName = ln.slice(2);\n } else {\n memberName = ln[2] + memberName.slice(3);\n }\n if (oldValue || newValue) {\n const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);\n memberName = memberName.replace(CAPTURE_EVENT_REGEX, \"\");\n if (oldValue) {\n plt.rel(elm, memberName, oldValue, capture);\n }\n if (newValue) {\n plt.ael(elm, memberName, newValue, capture);\n }\n }\n } else {\n const isComplex = isComplexType(newValue);\n if ((isProp || isComplex && newValue !== null) && !isSvg) {\n try {\n if (!elm.tagName.includes(\"-\")) {\n const n = newValue == null ? \"\" : newValue;\n if (memberName === \"list\") {\n isProp = false;\n } else if (oldValue == null || elm[memberName] != n) {\n if (typeof elm.__lookupSetter__(memberName) === \"function\") {\n elm[memberName] = n;\n } else {\n elm.setAttribute(memberName, n);\n }\n }\n } else if (elm[memberName] !== newValue) {\n elm[memberName] = newValue;\n }\n } catch (e) {\n }\n }\n if (newValue == null || newValue === false) {\n if (newValue !== false || elm.getAttribute(memberName) === \"\") {\n {\n elm.removeAttribute(memberName);\n }\n }\n } else if ((!isProp || flags & 4 /* isHost */ || isSvg) && !isComplex) {\n newValue = newValue === true ? \"\" : newValue;\n {\n elm.setAttribute(memberName, newValue);\n }\n }\n }\n }\n};\nvar parseClassListRegex = /\\s/;\nvar parseClassList = (value) => {\n if (typeof value === \"object\" && \"baseVal\" in value) {\n value = value.baseVal;\n }\n if (!value) {\n return [];\n }\n return value.split(parseClassListRegex);\n};\nvar CAPTURE_EVENT_SUFFIX = \"Capture\";\nvar CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + \"$\");\n\n// src/runtime/vdom/update-element.ts\nvar updateElement = (oldVnode, newVnode, isSvgMode2) => {\n const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;\n const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};\n const newVnodeAttrs = newVnode.$attrs$ || {};\n {\n for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {\n if (!(memberName in newVnodeAttrs)) {\n setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);\n }\n }\n }\n for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {\n setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);\n }\n};\nfunction sortedAttrNames(attrNames) {\n return attrNames.includes(\"ref\") ? (\n // we need to sort these to ensure that `'ref'` is the last attr\n [...attrNames.filter((attr) => attr !== \"ref\"), \"ref\"]\n ) : (\n // no need to sort, return the original array\n attrNames\n );\n}\nvar contentRef;\nvar hostTagName;\nvar useNativeShadowDom = false;\nvar checkSlotFallbackVisibility = false;\nvar checkSlotRelocate = false;\nvar isSvgMode = false;\nvar createElm = (oldParentVNode, newParentVNode, childIndex) => {\n var _a;\n const newVNode2 = newParentVNode.$children$[childIndex];\n let i2 = 0;\n let elm;\n let childNode;\n let oldVNode;\n if (!useNativeShadowDom) {\n checkSlotRelocate = true;\n if (newVNode2.$tag$ === \"slot\") {\n newVNode2.$flags$ |= newVNode2.$children$ ? (\n // slot element has fallback content\n // still create an element that \"mocks\" the slot element\n 2 /* isSlotFallback */\n ) : (\n // slot element does not have fallback content\n // create an html comment we'll use to always reference\n // where actual slot content should sit next to\n 1 /* isSlotReference */\n );\n }\n }\n if (newVNode2.$text$ !== null) {\n elm = newVNode2.$elm$ = doc.createTextNode(newVNode2.$text$);\n } else if (newVNode2.$flags$ & 1 /* isSlotReference */) {\n elm = newVNode2.$elm$ = doc.createTextNode(\"\");\n } else {\n if (!isSvgMode) {\n isSvgMode = newVNode2.$tag$ === \"svg\";\n }\n elm = newVNode2.$elm$ = doc.createElementNS(\n isSvgMode ? SVG_NS : HTML_NS,\n !useNativeShadowDom && BUILD.slotRelocation && newVNode2.$flags$ & 2 /* isSlotFallback */ ? \"slot-fb\" : newVNode2.$tag$\n ) ;\n if (isSvgMode && newVNode2.$tag$ === \"foreignObject\") {\n isSvgMode = false;\n }\n {\n updateElement(null, newVNode2, isSvgMode);\n }\n if (newVNode2.$children$) {\n for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {\n childNode = createElm(oldParentVNode, newVNode2, i2);\n if (childNode) {\n elm.appendChild(childNode);\n }\n }\n }\n {\n if (newVNode2.$tag$ === \"svg\") {\n isSvgMode = false;\n } else if (elm.tagName === \"foreignObject\") {\n isSvgMode = true;\n }\n }\n }\n elm[\"s-hn\"] = hostTagName;\n {\n if (newVNode2.$flags$ & (2 /* isSlotFallback */ | 1 /* isSlotReference */)) {\n elm[\"s-sr\"] = true;\n elm[\"s-cr\"] = contentRef;\n elm[\"s-sn\"] = newVNode2.$name$ || \"\";\n elm[\"s-rf\"] = (_a = newVNode2.$attrs$) == null ? void 0 : _a.ref;\n oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];\n if (oldVNode && oldVNode.$tag$ === newVNode2.$tag$ && oldParentVNode.$elm$) {\n {\n putBackInOriginalLocation(oldParentVNode.$elm$, false);\n }\n }\n }\n }\n return elm;\n};\nvar putBackInOriginalLocation = (parentElm, recursive) => {\n plt.$flags$ |= 1 /* isTmpDisconnected */;\n const oldSlotChildNodes = Array.from(parentElm.__childNodes || parentElm.childNodes);\n if (parentElm[\"s-sr\"] && BUILD.experimentalSlotFixes) {\n let node = parentElm;\n while (node = node.nextSibling) {\n if (node && node[\"s-sn\"] === parentElm[\"s-sn\"] && node[\"s-sh\"] === hostTagName) {\n oldSlotChildNodes.push(node);\n }\n }\n }\n for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {\n const childNode = oldSlotChildNodes[i2];\n if (childNode[\"s-hn\"] !== hostTagName && childNode[\"s-ol\"]) {\n insertBefore(referenceNode(childNode).parentNode, childNode, referenceNode(childNode));\n childNode[\"s-ol\"].remove();\n childNode[\"s-ol\"] = void 0;\n childNode[\"s-sh\"] = void 0;\n checkSlotRelocate = true;\n }\n if (recursive) {\n putBackInOriginalLocation(childNode, recursive);\n }\n }\n plt.$flags$ &= ~1 /* isTmpDisconnected */;\n};\nvar addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {\n let containerElm = parentElm[\"s-cr\"] && parentElm[\"s-cr\"].parentNode || parentElm;\n let childNode;\n for (; startIdx <= endIdx; ++startIdx) {\n if (vnodes[startIdx]) {\n childNode = createElm(null, parentVNode, startIdx);\n if (childNode) {\n vnodes[startIdx].$elm$ = childNode;\n insertBefore(containerElm, childNode, referenceNode(before) );\n }\n }\n }\n};\nvar removeVnodes = (vnodes, startIdx, endIdx) => {\n for (let index = startIdx; index <= endIdx; ++index) {\n const vnode = vnodes[index];\n if (vnode) {\n const elm = vnode.$elm$;\n if (elm) {\n {\n checkSlotFallbackVisibility = true;\n if (elm[\"s-ol\"]) {\n elm[\"s-ol\"].remove();\n } else {\n putBackInOriginalLocation(elm, true);\n }\n }\n elm.remove();\n }\n }\n }\n};\nvar updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = false) => {\n let oldStartIdx = 0;\n let newStartIdx = 0;\n let idxInOld = 0;\n let i2 = 0;\n let oldEndIdx = oldCh.length - 1;\n let oldStartVnode = oldCh[0];\n let oldEndVnode = oldCh[oldEndIdx];\n let newEndIdx = newCh.length - 1;\n let newStartVnode = newCh[0];\n let newEndVnode = newCh[newEndIdx];\n let node;\n let elmToMove;\n while (oldStartIdx <= oldEndIdx && newStartIdx <= newEndIdx) {\n if (oldStartVnode == null) {\n oldStartVnode = oldCh[++oldStartIdx];\n } else if (oldEndVnode == null) {\n oldEndVnode = oldCh[--oldEndIdx];\n } else if (newStartVnode == null) {\n newStartVnode = newCh[++newStartIdx];\n } else if (newEndVnode == null) {\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldStartVnode, newStartVnode, isInitialRender)) {\n patch(oldStartVnode, newStartVnode, isInitialRender);\n oldStartVnode = oldCh[++oldStartIdx];\n newStartVnode = newCh[++newStartIdx];\n } else if (isSameVnode(oldEndVnode, newEndVnode, isInitialRender)) {\n patch(oldEndVnode, newEndVnode, isInitialRender);\n oldEndVnode = oldCh[--oldEndIdx];\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldStartVnode, newEndVnode, isInitialRender)) {\n if ((oldStartVnode.$tag$ === \"slot\" || newEndVnode.$tag$ === \"slot\")) {\n putBackInOriginalLocation(oldStartVnode.$elm$.parentNode, false);\n }\n patch(oldStartVnode, newEndVnode, isInitialRender);\n insertBefore(parentElm, oldStartVnode.$elm$, oldEndVnode.$elm$.nextSibling);\n oldStartVnode = oldCh[++oldStartIdx];\n newEndVnode = newCh[--newEndIdx];\n } else if (isSameVnode(oldEndVnode, newStartVnode, isInitialRender)) {\n if ((oldStartVnode.$tag$ === \"slot\" || newEndVnode.$tag$ === \"slot\")) {\n putBackInOriginalLocation(oldEndVnode.$elm$.parentNode, false);\n }\n patch(oldEndVnode, newStartVnode, isInitialRender);\n insertBefore(parentElm, oldEndVnode.$elm$, oldStartVnode.$elm$);\n oldEndVnode = oldCh[--oldEndIdx];\n newStartVnode = newCh[++newStartIdx];\n } else {\n idxInOld = -1;\n {\n for (i2 = oldStartIdx; i2 <= oldEndIdx; ++i2) {\n if (oldCh[i2] && oldCh[i2].$key$ !== null && oldCh[i2].$key$ === newStartVnode.$key$) {\n idxInOld = i2;\n break;\n }\n }\n }\n if (idxInOld >= 0) {\n elmToMove = oldCh[idxInOld];\n if (elmToMove.$tag$ !== newStartVnode.$tag$) {\n node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);\n } else {\n patch(elmToMove, newStartVnode, isInitialRender);\n oldCh[idxInOld] = void 0;\n node = elmToMove.$elm$;\n }\n newStartVnode = newCh[++newStartIdx];\n } else {\n node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);\n newStartVnode = newCh[++newStartIdx];\n }\n if (node) {\n {\n insertBefore(\n referenceNode(oldStartVnode.$elm$).parentNode,\n node,\n referenceNode(oldStartVnode.$elm$)\n );\n }\n }\n }\n }\n if (oldStartIdx > oldEndIdx) {\n addVnodes(\n parentElm,\n newCh[newEndIdx + 1] == null ? null : newCh[newEndIdx + 1].$elm$,\n newVNode2,\n newCh,\n newStartIdx,\n newEndIdx\n );\n } else if (newStartIdx > newEndIdx) {\n removeVnodes(oldCh, oldStartIdx, oldEndIdx);\n }\n};\nvar isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {\n if (leftVNode.$tag$ === rightVNode.$tag$) {\n if (leftVNode.$tag$ === \"slot\") {\n return leftVNode.$name$ === rightVNode.$name$;\n }\n if (!isInitialRender) {\n return leftVNode.$key$ === rightVNode.$key$;\n }\n if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {\n leftVNode.$key$ = rightVNode.$key$;\n }\n return true;\n }\n return false;\n};\nvar referenceNode = (node) => node && node[\"s-ol\"] || node;\nvar patch = (oldVNode, newVNode2, isInitialRender = false) => {\n const elm = newVNode2.$elm$ = oldVNode.$elm$;\n const oldChildren = oldVNode.$children$;\n const newChildren = newVNode2.$children$;\n const tag = newVNode2.$tag$;\n const text = newVNode2.$text$;\n let defaultHolder;\n if (text === null) {\n {\n isSvgMode = tag === \"svg\" ? true : tag === \"foreignObject\" ? false : isSvgMode;\n }\n {\n if (tag === \"slot\" && !useNativeShadowDom) ; else {\n updateElement(oldVNode, newVNode2, isSvgMode);\n }\n }\n if (oldChildren !== null && newChildren !== null) {\n updateChildren(elm, oldChildren, newVNode2, newChildren, isInitialRender);\n } else if (newChildren !== null) {\n if (oldVNode.$text$ !== null) {\n elm.textContent = \"\";\n }\n addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);\n } else if (\n // don't do this on initial render as it can cause non-hydrated content to be removed\n !isInitialRender && BUILD.updatable && oldChildren !== null\n ) {\n removeVnodes(oldChildren, 0, oldChildren.length - 1);\n }\n if (isSvgMode && tag === \"svg\") {\n isSvgMode = false;\n }\n } else if ((defaultHolder = elm[\"s-cr\"])) {\n defaultHolder.parentNode.textContent = text;\n } else if (oldVNode.$text$ !== text) {\n elm.data = text;\n }\n};\nvar relocateNodes = [];\nvar markSlotContentForRelocation = (elm) => {\n let node;\n let hostContentNodes;\n let j;\n const children = elm.__childNodes || elm.childNodes;\n for (const childNode of children) {\n if (childNode[\"s-sr\"] && (node = childNode[\"s-cr\"]) && node.parentNode) {\n hostContentNodes = node.parentNode.__childNodes || node.parentNode.childNodes;\n const slotName = childNode[\"s-sn\"];\n for (j = hostContentNodes.length - 1; j >= 0; j--) {\n node = hostContentNodes[j];\n if (!node[\"s-cn\"] && !node[\"s-nr\"] && node[\"s-hn\"] !== childNode[\"s-hn\"] && (!BUILD.experimentalSlotFixes )) {\n if (isNodeLocatedInSlot(node, slotName)) {\n let relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);\n checkSlotFallbackVisibility = true;\n node[\"s-sn\"] = node[\"s-sn\"] || slotName;\n if (relocateNodeData) {\n relocateNodeData.$nodeToRelocate$[\"s-sh\"] = childNode[\"s-hn\"];\n relocateNodeData.$slotRefNode$ = childNode;\n } else {\n node[\"s-sh\"] = childNode[\"s-hn\"];\n relocateNodes.push({\n $slotRefNode$: childNode,\n $nodeToRelocate$: node\n });\n }\n if (node[\"s-sr\"]) {\n relocateNodes.map((relocateNode) => {\n if (isNodeLocatedInSlot(relocateNode.$nodeToRelocate$, node[\"s-sn\"])) {\n relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);\n if (relocateNodeData && !relocateNode.$slotRefNode$) {\n relocateNode.$slotRefNode$ = relocateNodeData.$slotRefNode$;\n }\n }\n });\n }\n } else if (!relocateNodes.some((r) => r.$nodeToRelocate$ === node)) {\n relocateNodes.push({\n $nodeToRelocate$: node\n });\n }\n }\n }\n }\n if (childNode.nodeType === 1 /* ElementNode */) {\n markSlotContentForRelocation(childNode);\n }\n }\n};\nvar insertBefore = (parent, newNode, reference) => {\n {\n return parent == null ? void 0 : parent.insertBefore(newNode, reference);\n }\n};\nvar renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {\n var _a, _b, _c, _d;\n const hostElm = hostRef.$hostElement$;\n const oldVNode = hostRef.$vnode$ || newVNode(null, null);\n const rootVnode = isHost(renderFnResults) ? renderFnResults : h(null, null, renderFnResults);\n hostTagName = hostElm.tagName;\n if (isInitialLoad && rootVnode.$attrs$) {\n for (const key of Object.keys(rootVnode.$attrs$)) {\n if (hostElm.hasAttribute(key) && ![\"key\", \"ref\", \"style\", \"class\"].includes(key)) {\n rootVnode.$attrs$[key] = hostElm[key];\n }\n }\n }\n rootVnode.$tag$ = null;\n rootVnode.$flags$ |= 4 /* isHost */;\n hostRef.$vnode$ = rootVnode;\n rootVnode.$elm$ = oldVNode.$elm$ = hostElm;\n useNativeShadowDom = supportsShadow ;\n {\n contentRef = hostElm[\"s-cr\"];\n checkSlotFallbackVisibility = false;\n }\n patch(oldVNode, rootVnode, isInitialLoad);\n {\n plt.$flags$ |= 1 /* isTmpDisconnected */;\n if (checkSlotRelocate) {\n markSlotContentForRelocation(rootVnode.$elm$);\n for (const relocateData of relocateNodes) {\n const nodeToRelocate = relocateData.$nodeToRelocate$;\n if (!nodeToRelocate[\"s-ol\"]) {\n const orgLocationNode = doc.createTextNode(\"\");\n orgLocationNode[\"s-nr\"] = nodeToRelocate;\n insertBefore(nodeToRelocate.parentNode, nodeToRelocate[\"s-ol\"] = orgLocationNode, nodeToRelocate);\n }\n }\n for (const relocateData of relocateNodes) {\n const nodeToRelocate = relocateData.$nodeToRelocate$;\n const slotRefNode = relocateData.$slotRefNode$;\n if (slotRefNode) {\n const parentNodeRef = slotRefNode.parentNode;\n let insertBeforeNode = slotRefNode.nextSibling;\n {\n let orgLocationNode = (_a = nodeToRelocate[\"s-ol\"]) == null ? void 0 : _a.previousSibling;\n while (orgLocationNode) {\n let refNode = (_b = orgLocationNode[\"s-nr\"]) != null ? _b : null;\n if (refNode && refNode[\"s-sn\"] === nodeToRelocate[\"s-sn\"] && parentNodeRef === (refNode.__parentNode || refNode.parentNode)) {\n refNode = refNode.nextSibling;\n while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode[\"s-sr\"])) {\n refNode = refNode == null ? void 0 : refNode.nextSibling;\n }\n if (!refNode || !refNode[\"s-nr\"]) {\n insertBeforeNode = refNode;\n break;\n }\n }\n orgLocationNode = orgLocationNode.previousSibling;\n }\n }\n const parent = nodeToRelocate.__parentNode || nodeToRelocate.parentNode;\n const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;\n if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {\n if (nodeToRelocate !== insertBeforeNode) {\n if (!nodeToRelocate[\"s-hn\"] && nodeToRelocate[\"s-ol\"]) {\n nodeToRelocate[\"s-hn\"] = nodeToRelocate[\"s-ol\"].parentNode.nodeName;\n }\n insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);\n if (nodeToRelocate.nodeType === 1 /* ElementNode */ && nodeToRelocate.tagName !== \"SLOT-FB\") {\n nodeToRelocate.hidden = (_c = nodeToRelocate[\"s-ih\"]) != null ? _c : false;\n }\n }\n }\n nodeToRelocate && typeof slotRefNode[\"s-rf\"] === \"function\" && slotRefNode[\"s-rf\"](nodeToRelocate);\n } else {\n if (nodeToRelocate.nodeType === 1 /* ElementNode */) {\n if (isInitialLoad) {\n nodeToRelocate[\"s-ih\"] = (_d = nodeToRelocate.hidden) != null ? _d : false;\n }\n nodeToRelocate.hidden = true;\n }\n }\n }\n }\n if (checkSlotFallbackVisibility) {\n updateFallbackSlotVisibility(rootVnode.$elm$);\n }\n plt.$flags$ &= ~1 /* isTmpDisconnected */;\n relocateNodes.length = 0;\n }\n contentRef = void 0;\n};\n\n// src/runtime/update-component.ts\nvar attachToAncestor = (hostRef, ancestorComponent) => {\n if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent[\"s-p\"]) {\n const index = ancestorComponent[\"s-p\"].push(\n new Promise(\n (r) => hostRef.$onRenderResolve$ = () => {\n ancestorComponent[\"s-p\"].splice(index - 1, 1);\n r();\n }\n )\n );\n }\n};\nvar scheduleUpdate = (hostRef, isInitialLoad) => {\n {\n hostRef.$flags$ |= 16 /* isQueuedForUpdate */;\n }\n if (hostRef.$flags$ & 4 /* isWaitingForChildren */) {\n hostRef.$flags$ |= 512 /* needsRerender */;\n return;\n }\n attachToAncestor(hostRef, hostRef.$ancestorComponent$);\n const dispatch = () => dispatchHooks(hostRef, isInitialLoad);\n return writeTask(dispatch) ;\n};\nvar dispatchHooks = (hostRef, isInitialLoad) => {\n const elm = hostRef.$hostElement$;\n const endSchedule = createTime(\"scheduleUpdate\", hostRef.$cmpMeta$.$tagName$);\n const instance = elm;\n if (!instance) {\n throw new Error(\n `Can't render component <${elm.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \\`externalRuntime: true\\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`\n );\n }\n let maybePromise;\n endSchedule();\n return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));\n};\nvar enqueue = (maybePromise, fn) => isPromisey(maybePromise) ? maybePromise.then(fn).catch((err2) => {\n console.error(err2);\n fn();\n}) : fn();\nvar isPromisey = (maybePromise) => maybePromise instanceof Promise || maybePromise && maybePromise.then && typeof maybePromise.then === \"function\";\nvar updateComponent = async (hostRef, instance, isInitialLoad) => {\n var _a;\n const elm = hostRef.$hostElement$;\n const endUpdate = createTime(\"update\", hostRef.$cmpMeta$.$tagName$);\n const rc = elm[\"s-rc\"];\n if (isInitialLoad) {\n attachStyles(hostRef);\n }\n const endRender = createTime(\"render\", hostRef.$cmpMeta$.$tagName$);\n {\n callRender(hostRef, instance, elm, isInitialLoad);\n }\n if (rc) {\n rc.map((cb) => cb());\n elm[\"s-rc\"] = void 0;\n }\n endRender();\n endUpdate();\n {\n const childrenPromises = (_a = elm[\"s-p\"]) != null ? _a : [];\n const postUpdate = () => postUpdateComponent(hostRef);\n if (childrenPromises.length === 0) {\n postUpdate();\n } else {\n Promise.all(childrenPromises).then(postUpdate);\n hostRef.$flags$ |= 4 /* isWaitingForChildren */;\n childrenPromises.length = 0;\n }\n }\n};\nvar callRender = (hostRef, instance, elm, isInitialLoad) => {\n try {\n instance = instance.render() ;\n {\n hostRef.$flags$ &= ~16 /* isQueuedForUpdate */;\n }\n {\n hostRef.$flags$ |= 2 /* hasRendered */;\n }\n {\n {\n {\n renderVdom(hostRef, instance, isInitialLoad);\n }\n }\n }\n } catch (e) {\n consoleError(e, hostRef.$hostElement$);\n }\n return null;\n};\nvar postUpdateComponent = (hostRef) => {\n const tagName = hostRef.$cmpMeta$.$tagName$;\n const elm = hostRef.$hostElement$;\n const endPostUpdate = createTime(\"postUpdate\", tagName);\n const instance = elm;\n const ancestorComponent = hostRef.$ancestorComponent$;\n if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {\n hostRef.$flags$ |= 64 /* hasLoadedComponent */;\n {\n addHydratedFlag(elm);\n }\n {\n safeCall(instance, \"componentDidLoad\", void 0, elm);\n }\n endPostUpdate();\n {\n hostRef.$onReadyResolve$(elm);\n if (!ancestorComponent) {\n appDidLoad();\n }\n }\n } else {\n endPostUpdate();\n }\n {\n if (hostRef.$onRenderResolve$) {\n hostRef.$onRenderResolve$();\n hostRef.$onRenderResolve$ = void 0;\n }\n if (hostRef.$flags$ & 512 /* needsRerender */) {\n nextTick(() => scheduleUpdate(hostRef, false));\n }\n hostRef.$flags$ &= ~(4 /* isWaitingForChildren */ | 512 /* needsRerender */);\n }\n};\nvar appDidLoad = (who) => {\n {\n addHydratedFlag(doc.documentElement);\n }\n nextTick(() => emitEvent(win, \"appload\", { detail: { namespace: NAMESPACE } }));\n};\nvar safeCall = (instance, method, arg, elm) => {\n if (instance && instance[method]) {\n try {\n return instance[method](arg);\n } catch (e) {\n consoleError(e, elm);\n }\n }\n return void 0;\n};\nvar addHydratedFlag = (elm) => {\n var _a;\n return elm.classList.add((_a = BUILD.hydratedSelectorName) != null ? _a : \"hydrated\") ;\n};\n\n// src/runtime/set-value.ts\nvar getValue = (ref, propName) => getHostRef(ref).$instanceValues$.get(propName);\nvar setValue = (ref, propName, newVal, cmpMeta) => {\n const hostRef = getHostRef(ref);\n const elm = ref;\n const oldVal = hostRef.$instanceValues$.get(propName);\n const flags = hostRef.$flags$;\n const instance = elm;\n newVal = parsePropertyValue(newVal, cmpMeta.$members$[propName][0]);\n const areBothNaN = Number.isNaN(oldVal) && Number.isNaN(newVal);\n const didValueChange = newVal !== oldVal && !areBothNaN;\n if (didValueChange) {\n hostRef.$instanceValues$.set(propName, newVal);\n {\n if (cmpMeta.$watchers$ && flags & 128 /* isWatchReady */) {\n const watchMethods = cmpMeta.$watchers$[propName];\n if (watchMethods) {\n watchMethods.map((watchMethodName) => {\n try {\n instance[watchMethodName](newVal, oldVal, propName);\n } catch (e) {\n consoleError(e, elm);\n }\n });\n }\n }\n if ((flags & (2 /* hasRendered */ | 16 /* isQueuedForUpdate */)) === 2 /* hasRendered */) {\n scheduleUpdate(hostRef, false);\n }\n }\n }\n};\n\n// src/runtime/proxy-component.ts\nvar proxyComponent = (Cstr, cmpMeta, flags) => {\n var _a, _b;\n const prototype = Cstr.prototype;\n if (cmpMeta.$members$ || (cmpMeta.$watchers$ || Cstr.watchers)) {\n if (Cstr.watchers && !cmpMeta.$watchers$) {\n cmpMeta.$watchers$ = Cstr.watchers;\n }\n const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});\n members.map(([memberName, [memberFlags]]) => {\n if ((memberFlags & 31 /* Prop */ || memberFlags & 32 /* State */)) {\n const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};\n if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;\n if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;\n if (flags & 1 /* isElementConstructor */ || !origGetter) {\n Object.defineProperty(prototype, memberName, {\n get() {\n {\n return origGetter ? origGetter.apply(this) : getValue(this, memberName);\n }\n },\n configurable: true,\n enumerable: true\n });\n }\n Object.defineProperty(prototype, memberName, {\n set(newValue) {\n const ref = getHostRef(this);\n if (origSetter) {\n const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];\n if (typeof currentValue === \"undefined\" && ref.$instanceValues$.get(memberName)) {\n newValue = ref.$instanceValues$.get(memberName);\n } else if (!ref.$instanceValues$.get(memberName) && currentValue) {\n ref.$instanceValues$.set(memberName, currentValue);\n }\n origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);\n newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];\n setValue(this, memberName, newValue, cmpMeta);\n return;\n }\n {\n setValue(this, memberName, newValue, cmpMeta);\n return;\n }\n }\n });\n }\n });\n {\n const attrNameToPropName = /* @__PURE__ */ new Map();\n prototype.attributeChangedCallback = function(attrName, oldValue, newValue) {\n plt.jmp(() => {\n var _a2;\n const propName = attrNameToPropName.get(attrName);\n if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {\n newValue = this[propName];\n delete this[propName];\n } else if (prototype.hasOwnProperty(propName) && typeof this[propName] === \"number\" && // cast type to number to avoid TS compiler issues\n this[propName] == newValue) {\n return;\n } else if (propName == null) {\n const hostRef = getHostRef(this);\n const flags2 = hostRef == null ? void 0 : hostRef.$flags$;\n if (flags2 && !(flags2 & 8 /* isConstructingInstance */) && flags2 & 128 /* isWatchReady */ && newValue !== oldValue) {\n const elm = this;\n const instance = elm;\n const entry = (_a2 = cmpMeta.$watchers$) == null ? void 0 : _a2[attrName];\n entry == null ? void 0 : entry.forEach((callbackName) => {\n if (instance[callbackName] != null) {\n instance[callbackName].call(instance, newValue, oldValue, attrName);\n }\n });\n }\n return;\n }\n const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);\n newValue = newValue === null && typeof this[propName] === \"boolean\" ? false : newValue;\n if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {\n this[propName] = newValue;\n }\n });\n };\n Cstr.observedAttributes = Array.from(\n /* @__PURE__ */ new Set([\n ...Object.keys((_b = cmpMeta.$watchers$) != null ? _b : {}),\n ...members.filter(([_, m]) => m[0] & 15 /* HasAttribute */).map(([propName, m]) => {\n const attrName = m[1] || propName;\n attrNameToPropName.set(attrName, propName);\n return attrName;\n })\n ])\n );\n }\n }\n return Cstr;\n};\n\n// src/runtime/initialize-component.ts\nvar initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {\n let Cstr;\n if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {\n hostRef.$flags$ |= 32 /* hasInitializedComponent */;\n {\n Cstr = elm.constructor;\n const cmpTag = elm.localName;\n customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);\n }\n if (Cstr && Cstr.style) {\n let style;\n if (typeof Cstr.style === \"string\") {\n style = Cstr.style;\n }\n const scopeId2 = getScopeId(cmpMeta);\n if (!styles.has(scopeId2)) {\n const endRegisterStyles = createTime(\"registerStyles\", cmpMeta.$tagName$);\n registerStyle(scopeId2, style, !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */));\n endRegisterStyles();\n }\n }\n }\n const ancestorComponent = hostRef.$ancestorComponent$;\n const schedule = () => scheduleUpdate(hostRef, true);\n if (ancestorComponent && ancestorComponent[\"s-rc\"]) {\n ancestorComponent[\"s-rc\"].push(schedule);\n } else {\n schedule();\n }\n};\nvar fireConnectedCallback = (instance, elm) => {\n};\n\n// src/runtime/connected-callback.ts\nvar connectedCallback = (elm) => {\n if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {\n const hostRef = getHostRef(elm);\n const cmpMeta = hostRef.$cmpMeta$;\n const endConnected = createTime(\"connectedCallback\", cmpMeta.$tagName$);\n if (!(hostRef.$flags$ & 1 /* hasConnected */)) {\n hostRef.$flags$ |= 1 /* hasConnected */;\n {\n if (// TODO(STENCIL-854): Remove code related to legacy shadowDomShim field\n cmpMeta.$flags$ & (4 /* hasSlotRelocation */ | 8 /* needsShadowDomShim */)) {\n setContentReference(elm);\n }\n }\n {\n let ancestorComponent = elm;\n while (ancestorComponent = ancestorComponent.parentNode || ancestorComponent.host) {\n if (ancestorComponent[\"s-p\"]) {\n attachToAncestor(hostRef, hostRef.$ancestorComponent$ = ancestorComponent);\n break;\n }\n }\n }\n if (cmpMeta.$members$) {\n Object.entries(cmpMeta.$members$).map(([memberName, [memberFlags]]) => {\n if (memberFlags & 31 /* Prop */ && elm.hasOwnProperty(memberName)) {\n const value = elm[memberName];\n delete elm[memberName];\n elm[memberName] = value;\n }\n });\n }\n {\n initializeComponent(elm, hostRef, cmpMeta);\n }\n } else {\n if (hostRef == null ? void 0 : hostRef.$lazyInstance$) ; else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {\n hostRef.$onReadyPromise$.then(() => fireConnectedCallback());\n }\n }\n endConnected();\n }\n};\nvar setContentReference = (elm) => {\n const contentRefElm = elm[\"s-cr\"] = doc.createComment(\n \"\"\n );\n contentRefElm[\"s-cn\"] = true;\n insertBefore(elm, contentRefElm, elm.firstChild);\n};\nvar disconnectedCallback = async (elm) => {\n if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {\n getHostRef(elm);\n }\n if (rootAppliedStyles.has(elm)) {\n rootAppliedStyles.delete(elm);\n }\n if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {\n rootAppliedStyles.delete(elm.shadowRoot);\n }\n};\nvar proxyCustomElement = (Cstr, compactMeta) => {\n const cmpMeta = {\n $flags$: compactMeta[0],\n $tagName$: compactMeta[1]\n };\n {\n cmpMeta.$members$ = compactMeta[2];\n }\n {\n cmpMeta.$watchers$ = Cstr.$watchers$;\n }\n const originalConnectedCallback = Cstr.prototype.connectedCallback;\n const originalDisconnectedCallback = Cstr.prototype.disconnectedCallback;\n Object.assign(Cstr.prototype, {\n __hasHostListenerAttached: false,\n __registerHost() {\n registerHost(this, cmpMeta);\n },\n connectedCallback() {\n if (!this.__hasHostListenerAttached) {\n getHostRef(this);\n this.__hasHostListenerAttached = true;\n }\n connectedCallback(this);\n if (originalConnectedCallback) {\n originalConnectedCallback.call(this);\n }\n },\n disconnectedCallback() {\n disconnectedCallback(this);\n if (originalDisconnectedCallback) {\n originalDisconnectedCallback.call(this);\n }\n plt.raf(() => {\n var _a;\n const hostRef = getHostRef(this);\n if (((_a = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {\n delete hostRef.$vnode$;\n }\n if (this instanceof Node && !this.isConnected) {\n deleteHostRef(this);\n }\n });\n },\n __attachShadow() {\n {\n this.shadowRoot = this;\n }\n }\n });\n Cstr.is = cmpMeta.$tagName$;\n return proxyComponent(Cstr, cmpMeta, 1 /* isElementConstructor */ | 2 /* proxyState */);\n};\n\n// src/runtime/fragment.ts\nvar Fragment = (_, children) => children;\n\n// src/runtime/nonce.ts\nvar setNonce = (nonce) => plt.$nonce$ = nonce;\n\n// src/runtime/platform-options.ts\nvar setPlatformOptions = (opts) => Object.assign(plt, opts);\n\nexport { Fragment as F, H, setNonce as a, setPlatformOptions as b, createEvent as c, getAssetPath as g, h, proxyCustomElement as p, setAssetPath as s };\n\n//# sourceMappingURL=p-6cafd48d.js.map","var zustand = {};\n\nvar vanilla$1 = {};\n\nconst createStoreImpl = (createState) => {\n let state;\n const listeners = /* @__PURE__ */ new Set();\n const setState = (partial, replace) => {\n const nextState = typeof partial === \"function\" ? partial(state) : partial;\n if (!Object.is(nextState, state)) {\n const previousState = state;\n state = (replace != null ? replace : typeof nextState !== \"object\" || nextState === null) ? nextState : Object.assign({}, state, nextState);\n listeners.forEach((listener) => listener(state, previousState));\n }\n };\n const getState = () => state;\n const getInitialState = () => initialState;\n const subscribe = (listener) => {\n listeners.add(listener);\n return () => listeners.delete(listener);\n };\n const api = { setState, getState, getInitialState, subscribe };\n const initialState = state = createState(setState, getState, api);\n return api;\n};\nconst createStore = (createState) => createState ? createStoreImpl(createState) : createStoreImpl;\n\nvanilla$1.createStore = createStore;\n\nvar react$1 = {};\n\nvar react = {exports: {}};\n\nvar react_production = {};\n\n/**\n * @license React\n * react.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n MAYBE_ITERATOR_SYMBOL = Symbol.iterator;\nfunction getIteratorFn(maybeIterable) {\n if (null === maybeIterable || \"object\" !== typeof maybeIterable) return null;\n maybeIterable =\n (MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||\n maybeIterable[\"@@iterator\"];\n return \"function\" === typeof maybeIterable ? maybeIterable : null;\n}\nvar ReactNoopUpdateQueue = {\n isMounted: function () {\n return !1;\n },\n enqueueForceUpdate: function () {},\n enqueueReplaceState: function () {},\n enqueueSetState: function () {}\n },\n assign = Object.assign,\n emptyObject = {};\nfunction Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n}\nComponent.prototype.isReactComponent = {};\nComponent.prototype.setState = function (partialState, callback) {\n if (\n \"object\" !== typeof partialState &&\n \"function\" !== typeof partialState &&\n null != partialState\n )\n throw Error(\n \"takes an object of state variables to update or a function which returns an object of state variables.\"\n );\n this.updater.enqueueSetState(this, partialState, callback, \"setState\");\n};\nComponent.prototype.forceUpdate = function (callback) {\n this.updater.enqueueForceUpdate(this, callback, \"forceUpdate\");\n};\nfunction ComponentDummy() {}\nComponentDummy.prototype = Component.prototype;\nfunction PureComponent(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n}\nvar pureComponentPrototype = (PureComponent.prototype = new ComponentDummy());\npureComponentPrototype.constructor = PureComponent;\nassign(pureComponentPrototype, Component.prototype);\npureComponentPrototype.isPureReactComponent = !0;\nvar isArrayImpl = Array.isArray,\n ReactSharedInternals = { H: null, A: null, T: null, S: null },\n hasOwnProperty = Object.prototype.hasOwnProperty;\nfunction ReactElement(type, key, self, source, owner, props) {\n self = props.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== self ? self : null,\n props: props\n };\n}\nfunction cloneAndReplaceKey(oldElement, newKey) {\n return ReactElement(\n oldElement.type,\n newKey,\n void 0,\n void 0,\n void 0,\n oldElement.props\n );\n}\nfunction isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n}\nfunction escape(key) {\n var escaperLookup = { \"=\": \"=0\", \":\": \"=2\" };\n return (\n \"$\" +\n key.replace(/[=:]/g, function (match) {\n return escaperLookup[match];\n })\n );\n}\nvar userProvidedKeyEscapeRegex = /\\/+/g;\nfunction getElementKey(element, index) {\n return \"object\" === typeof element && null !== element && null != element.key\n ? escape(\"\" + element.key)\n : index.toString(36);\n}\nfunction noop$1() {}\nfunction resolveThenable(thenable) {\n switch (thenable.status) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n default:\n switch (\n (\"string\" === typeof thenable.status\n ? thenable.then(noop$1, noop$1)\n : ((thenable.status = \"pending\"),\n thenable.then(\n function (fulfilledValue) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"fulfilled\"),\n (thenable.value = fulfilledValue));\n },\n function (error) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"rejected\"), (thenable.reason = error));\n }\n )),\n thenable.status)\n ) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n }\n }\n throw thenable;\n}\nfunction mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {\n var type = typeof children;\n if (\"undefined\" === type || \"boolean\" === type) children = null;\n var invokeCallback = !1;\n if (null === children) invokeCallback = !0;\n else\n switch (type) {\n case \"bigint\":\n case \"string\":\n case \"number\":\n invokeCallback = !0;\n break;\n case \"object\":\n switch (children.$$typeof) {\n case REACT_ELEMENT_TYPE:\n case REACT_PORTAL_TYPE:\n invokeCallback = !0;\n break;\n case REACT_LAZY_TYPE:\n return (\n (invokeCallback = children._init),\n mapIntoArray(\n invokeCallback(children._payload),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n )\n );\n }\n }\n if (invokeCallback)\n return (\n (callback = callback(children)),\n (invokeCallback =\n \"\" === nameSoFar ? \".\" + getElementKey(children, 0) : nameSoFar),\n isArrayImpl(callback)\n ? ((escapedPrefix = \"\"),\n null != invokeCallback &&\n (escapedPrefix =\n invokeCallback.replace(userProvidedKeyEscapeRegex, \"$&/\") + \"/\"),\n mapIntoArray(callback, array, escapedPrefix, \"\", function (c) {\n return c;\n }))\n : null != callback &&\n (isValidElement(callback) &&\n (callback = cloneAndReplaceKey(\n callback,\n escapedPrefix +\n (null == callback.key ||\n (children && children.key === callback.key)\n ? \"\"\n : (\"\" + callback.key).replace(\n userProvidedKeyEscapeRegex,\n \"$&/\"\n ) + \"/\") +\n invokeCallback\n )),\n array.push(callback)),\n 1\n );\n invokeCallback = 0;\n var nextNamePrefix = \"\" === nameSoFar ? \".\" : nameSoFar + \":\";\n if (isArrayImpl(children))\n for (var i = 0; i < children.length; i++)\n (nameSoFar = children[i]),\n (type = nextNamePrefix + getElementKey(nameSoFar, i)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (((i = getIteratorFn(children)), \"function\" === typeof i))\n for (\n children = i.call(children), i = 0;\n !(nameSoFar = children.next()).done;\n\n )\n (nameSoFar = nameSoFar.value),\n (type = nextNamePrefix + getElementKey(nameSoFar, i++)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (\"object\" === type) {\n if (\"function\" === typeof children.then)\n return mapIntoArray(\n resolveThenable(children),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n );\n array = String(children);\n throw Error(\n \"Objects are not valid as a React child (found: \" +\n (\"[object Object]\" === array\n ? \"object with keys {\" + Object.keys(children).join(\", \") + \"}\"\n : array) +\n \"). If you meant to render a collection of children, use an array instead.\"\n );\n }\n return invokeCallback;\n}\nfunction mapChildren(children, func, context) {\n if (null == children) return children;\n var result = [],\n count = 0;\n mapIntoArray(children, result, \"\", \"\", function (child) {\n return func.call(context, child, count++);\n });\n return result;\n}\nfunction lazyInitializer(payload) {\n if (-1 === payload._status) {\n var ctor = payload._result;\n ctor = ctor();\n ctor.then(\n function (moduleObject) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 1), (payload._result = moduleObject);\n },\n function (error) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 2), (payload._result = error);\n }\n );\n -1 === payload._status && ((payload._status = 0), (payload._result = ctor));\n }\n if (1 === payload._status) return payload._result.default;\n throw payload._result;\n}\nvar reportGlobalError =\n \"function\" === typeof reportError\n ? reportError\n : function (error) {\n if (\n \"object\" === typeof window &&\n \"function\" === typeof window.ErrorEvent\n ) {\n var event = new window.ErrorEvent(\"error\", {\n bubbles: !0,\n cancelable: !0,\n message:\n \"object\" === typeof error &&\n null !== error &&\n \"string\" === typeof error.message\n ? String(error.message)\n : String(error),\n error: error\n });\n if (!window.dispatchEvent(event)) return;\n } else if (\n \"object\" === typeof process &&\n \"function\" === typeof process.emit\n ) {\n process.emit(\"uncaughtException\", error);\n return;\n }\n console.error(error);\n };\nfunction noop() {}\nreact_production.Children = {\n map: mapChildren,\n forEach: function (children, forEachFunc, forEachContext) {\n mapChildren(\n children,\n function () {\n forEachFunc.apply(this, arguments);\n },\n forEachContext\n );\n },\n count: function (children) {\n var n = 0;\n mapChildren(children, function () {\n n++;\n });\n return n;\n },\n toArray: function (children) {\n return (\n mapChildren(children, function (child) {\n return child;\n }) || []\n );\n },\n only: function (children) {\n if (!isValidElement(children))\n throw Error(\n \"React.Children.only expected to receive a single React element child.\"\n );\n return children;\n }\n};\nreact_production.Component = Component;\nreact_production.Fragment = REACT_FRAGMENT_TYPE;\nreact_production.Profiler = REACT_PROFILER_TYPE;\nreact_production.PureComponent = PureComponent;\nreact_production.StrictMode = REACT_STRICT_MODE_TYPE;\nreact_production.Suspense = REACT_SUSPENSE_TYPE;\nreact_production.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n ReactSharedInternals;\nreact_production.act = function () {\n throw Error(\"act(...) is not supported in production builds of React.\");\n};\nreact_production.cache = function (fn) {\n return function () {\n return fn.apply(null, arguments);\n };\n};\nreact_production.cloneElement = function (element, config, children) {\n if (null === element || void 0 === element)\n throw Error(\n \"The argument must be a React element, but you passed \" + element + \".\"\n );\n var props = assign({}, element.props),\n key = element.key,\n owner = void 0;\n if (null != config)\n for (propName in (void 0 !== config.ref && (owner = void 0),\n void 0 !== config.key && (key = \"\" + config.key),\n config))\n !hasOwnProperty.call(config, propName) ||\n \"key\" === propName ||\n \"__self\" === propName ||\n \"__source\" === propName ||\n (\"ref\" === propName && void 0 === config.ref) ||\n (props[propName] = config[propName]);\n var propName = arguments.length - 2;\n if (1 === propName) props.children = children;\n else if (1 < propName) {\n for (var childArray = Array(propName), i = 0; i < propName; i++)\n childArray[i] = arguments[i + 2];\n props.children = childArray;\n }\n return ReactElement(element.type, key, void 0, void 0, owner, props);\n};\nreact_production.createContext = function (defaultValue) {\n defaultValue = {\n $$typeof: REACT_CONTEXT_TYPE,\n _currentValue: defaultValue,\n _currentValue2: defaultValue,\n _threadCount: 0,\n Provider: null,\n Consumer: null\n };\n defaultValue.Provider = defaultValue;\n defaultValue.Consumer = {\n $$typeof: REACT_CONSUMER_TYPE,\n _context: defaultValue\n };\n return defaultValue;\n};\nreact_production.createElement = function (type, config, children) {\n var propName,\n props = {},\n key = null;\n if (null != config)\n for (propName in (void 0 !== config.key && (key = \"\" + config.key), config))\n hasOwnProperty.call(config, propName) &&\n \"key\" !== propName &&\n \"__self\" !== propName &&\n \"__source\" !== propName &&\n (props[propName] = config[propName]);\n var childrenLength = arguments.length - 2;\n if (1 === childrenLength) props.children = children;\n else if (1 < childrenLength) {\n for (var childArray = Array(childrenLength), i = 0; i < childrenLength; i++)\n childArray[i] = arguments[i + 2];\n props.children = childArray;\n }\n if (type && type.defaultProps)\n for (propName in ((childrenLength = type.defaultProps), childrenLength))\n void 0 === props[propName] &&\n (props[propName] = childrenLength[propName]);\n return ReactElement(type, key, void 0, void 0, null, props);\n};\nreact_production.createRef = function () {\n return { current: null };\n};\nreact_production.forwardRef = function (render) {\n return { $$typeof: REACT_FORWARD_REF_TYPE, render: render };\n};\nreact_production.isValidElement = isValidElement;\nreact_production.lazy = function (ctor) {\n return {\n $$typeof: REACT_LAZY_TYPE,\n _payload: { _status: -1, _result: ctor },\n _init: lazyInitializer\n };\n};\nreact_production.memo = function (type, compare) {\n return {\n $$typeof: REACT_MEMO_TYPE,\n type: type,\n compare: void 0 === compare ? null : compare\n };\n};\nreact_production.startTransition = function (scope) {\n var prevTransition = ReactSharedInternals.T,\n currentTransition = {};\n ReactSharedInternals.T = currentTransition;\n try {\n var returnValue = scope(),\n onStartTransitionFinish = ReactSharedInternals.S;\n null !== onStartTransitionFinish &&\n onStartTransitionFinish(currentTransition, returnValue);\n \"object\" === typeof returnValue &&\n null !== returnValue &&\n \"function\" === typeof returnValue.then &&\n returnValue.then(noop, reportGlobalError);\n } catch (error) {\n reportGlobalError(error);\n } finally {\n ReactSharedInternals.T = prevTransition;\n }\n};\nreact_production.unstable_useCacheRefresh = function () {\n return ReactSharedInternals.H.useCacheRefresh();\n};\nreact_production.use = function (usable) {\n return ReactSharedInternals.H.use(usable);\n};\nreact_production.useActionState = function (action, initialState, permalink) {\n return ReactSharedInternals.H.useActionState(action, initialState, permalink);\n};\nreact_production.useCallback = function (callback, deps) {\n return ReactSharedInternals.H.useCallback(callback, deps);\n};\nreact_production.useContext = function (Context) {\n return ReactSharedInternals.H.useContext(Context);\n};\nreact_production.useDebugValue = function () {};\nreact_production.useDeferredValue = function (value, initialValue) {\n return ReactSharedInternals.H.useDeferredValue(value, initialValue);\n};\nreact_production.useEffect = function (create, deps) {\n return ReactSharedInternals.H.useEffect(create, deps);\n};\nreact_production.useId = function () {\n return ReactSharedInternals.H.useId();\n};\nreact_production.useImperativeHandle = function (ref, create, deps) {\n return ReactSharedInternals.H.useImperativeHandle(ref, create, deps);\n};\nreact_production.useInsertionEffect = function (create, deps) {\n return ReactSharedInternals.H.useInsertionEffect(create, deps);\n};\nreact_production.useLayoutEffect = function (create, deps) {\n return ReactSharedInternals.H.useLayoutEffect(create, deps);\n};\nreact_production.useMemo = function (create, deps) {\n return ReactSharedInternals.H.useMemo(create, deps);\n};\nreact_production.useOptimistic = function (passthrough, reducer) {\n return ReactSharedInternals.H.useOptimistic(passthrough, reducer);\n};\nreact_production.useReducer = function (reducer, initialArg, init) {\n return ReactSharedInternals.H.useReducer(reducer, initialArg, init);\n};\nreact_production.useRef = function (initialValue) {\n return ReactSharedInternals.H.useRef(initialValue);\n};\nreact_production.useState = function (initialState) {\n return ReactSharedInternals.H.useState(initialState);\n};\nreact_production.useSyncExternalStore = function (\n subscribe,\n getSnapshot,\n getServerSnapshot\n) {\n return ReactSharedInternals.H.useSyncExternalStore(\n subscribe,\n getSnapshot,\n getServerSnapshot\n );\n};\nreact_production.useTransition = function () {\n return ReactSharedInternals.H.useTransition();\n};\nreact_production.version = \"19.0.0\";\n\n{\n react.exports = react_production;\n}\n\nvar React = react.exports;\nvar vanilla = vanilla$1;\n\nconst identity = (arg) => arg;\nfunction useStore(api, selector = identity) {\n const slice = React.useSyncExternalStore(\n api.subscribe,\n () => selector(api.getState()),\n () => selector(api.getInitialState())\n );\n React.useDebugValue(slice);\n return slice;\n}\nconst createImpl = (createState) => {\n const api = vanilla.createStore(createState);\n const useBoundStore = (selector) => useStore(api, selector);\n Object.assign(useBoundStore, api);\n return useBoundStore;\n};\nconst create = (createState) => createState ? createImpl(createState) : createImpl;\n\nreact$1.create = create;\nreact$1.useStore = useStore;\n\n(function (exports) {\n\nvar vanilla = vanilla$1;\nvar react = react$1;\n\n\n\nObject.keys(vanilla).forEach(function (k) {\n\tif (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {\n\t\tenumerable: true,\n\t\tget: function () { return vanilla[k]; }\n\t});\n});\nObject.keys(react).forEach(function (k) {\n\tif (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {\n\t\tenumerable: true,\n\t\tget: function () { return react[k]; }\n\t});\n});\n}(zustand));\n\nvar D = Object.defineProperty;\nvar B = (n, t, r) => t in n ? D(n, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : n[t] = r;\nvar m = (n, t, r) => B(n, typeof t != \"symbol\" ? t + \"\" : t, r);\nconst L = \"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict\";\nlet q = (n = 21) => {\n let t = \"\", r = crypto.getRandomValues(new Uint8Array(n |= 0));\n for (; n--; )\n t += L[r[n] & 63];\n return t;\n};\nfunction w(n, t, r, i) {\n return new (r || (r = Promise))(function(s, o) {\n function e(u) {\n try {\n l(i.next(u));\n } catch (a) {\n o(a);\n }\n }\n function c(u) {\n try {\n l(i.throw(u));\n } catch (a) {\n o(a);\n }\n }\n function l(u) {\n var a;\n u.done ? s(u.value) : (a = u.value, a instanceof r ? a : new r(function(p) {\n p(a);\n })).then(e, c);\n }\n l((i = i.apply(n, [])).next());\n });\n}\nfunction y(n, t) {\n var r, i, s, o, e = { label: 0, sent: function() {\n if (1 & s[0]) throw s[1];\n return s[1];\n }, trys: [], ops: [] };\n return o = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == \"function\" && (o[Symbol.iterator] = function() {\n return this;\n }), o;\n function c(l) {\n return function(u) {\n return function(a) {\n if (r) throw new TypeError(\"Generator is already executing.\");\n for (; o && (o = 0, a[0] && (e = 0)), e; ) try {\n if (r = 1, i && (s = 2 & a[0] ? i.return : a[0] ? i.throw || ((s = i.return) && s.call(i), 0) : i.next) && !(s = s.call(i, a[1])).done) return s;\n switch (i = 0, s && (a = [2 & a[0], s.value]), a[0]) {\n case 0:\n case 1:\n s = a;\n break;\n case 4:\n return e.label++, { value: a[1], done: !1 };\n case 5:\n e.label++, i = a[1], a = [0];\n continue;\n case 7:\n a = e.ops.pop(), e.trys.pop();\n continue;\n default:\n if (s = e.trys, !((s = s.length > 0 && s[s.length - 1]) || a[0] !== 6 && a[0] !== 2)) {\n e = 0;\n continue;\n }\n if (a[0] === 3 && (!s || a[1] > s[0] && a[1] < s[3])) {\n e.label = a[1];\n break;\n }\n if (a[0] === 6 && e.label < s[1]) {\n e.label = s[1], s = a;\n break;\n }\n if (s && e.label < s[2]) {\n e.label = s[2], e.ops.push(a);\n break;\n }\n s[2] && e.ops.pop(), e.trys.pop();\n continue;\n }\n a = t.call(n, e);\n } catch (p) {\n a = [6, p], i = 0;\n } finally {\n r = s = 0;\n }\n if (5 & a[0]) throw a[1];\n return { value: a[0] ? a[1] : void 0, done: !0 };\n }([l, u]);\n };\n }\n}\nvar b = { exclude: [] }, P = {}, N = { timeout: \"true\" }, v = function(n, t) {\n typeof window < \"u\" && (P[n] = t);\n}, j = function() {\n return Object.fromEntries(Object.entries(P).filter(function(n) {\n var t, r = n[0];\n return !(!((t = b == null ? void 0 : b.exclude) === null || t === void 0) && t.includes(r));\n }).map(function(n) {\n return [n[0], (0, n[1])()];\n }));\n};\nfunction M(n) {\n return n ^= n >>> 16, n = Math.imul(n, 2246822507), n ^= n >>> 13, n = Math.imul(n, 3266489909), (n ^= n >>> 16) >>> 0;\n}\nvar f = new Uint32Array([597399067, 2869860233, 951274213, 2716044179]);\nfunction g(n, t) {\n return n << t | n >>> 32 - t;\n}\nfunction R(n, t) {\n var r;\n if (t === void 0 && (t = 0), t = t ? 0 | t : 0, typeof n == \"string\" && (r = n, n = new TextEncoder().encode(r).buffer), !(n instanceof ArrayBuffer)) throw new TypeError(\"Expected key to be ArrayBuffer or string\");\n var i = new Uint32Array([t, t, t, t]);\n ((function(o, e) {\n for (var c = o.byteLength / 16 | 0, l = new Uint32Array(o, 0, 4 * c), u = 0; u < c; u++) {\n var a = l.subarray(4 * u, 4 * (u + 1));\n a[0] = Math.imul(a[0], f[0]), a[0] = g(a[0], 15), a[0] = Math.imul(a[0], f[1]), e[0] = e[0] ^ a[0], e[0] = g(e[0], 19), e[0] = e[0] + e[1], e[0] = Math.imul(e[0], 5) + 1444728091, a[1] = Math.imul(a[1], f[1]), a[1] = g(a[1], 16), a[1] = Math.imul(a[1], f[2]), e[1] = e[1] ^ a[1], e[1] = g(e[1], 17), e[1] = e[1] + e[2], e[1] = Math.imul(e[1], 5) + 197830471, a[2] = Math.imul(a[2], f[2]), a[2] = g(a[2], 17), a[2] = Math.imul(a[2], f[3]), e[2] = e[2] ^ a[2], e[2] = g(e[2], 15), e[2] = e[2] + e[3], e[2] = Math.imul(e[2], 5) + 2530024501, a[3] = Math.imul(a[3], f[3]), a[3] = g(a[3], 18), a[3] = Math.imul(a[3], f[0]), e[3] = e[3] ^ a[3], e[3] = g(e[3], 13), e[3] = e[3] + e[0], e[3] = Math.imul(e[3], 5) + 850148119;\n }\n }))(n, i), function(o, e) {\n var c = o.byteLength / 16 | 0, l = o.byteLength % 16, u = new Uint32Array(4), a = new Uint8Array(o, 16 * c, l);\n switch (l) {\n case 15:\n u[3] = u[3] ^ a[14] << 16;\n case 14:\n u[3] = u[3] ^ a[13] << 8;\n case 13:\n u[3] = u[3] ^ a[12] << 0, u[3] = Math.imul(u[3], f[3]), u[3] = g(u[3], 18), u[3] = Math.imul(u[3], f[0]), e[3] = e[3] ^ u[3];\n case 12:\n u[2] = u[2] ^ a[11] << 24;\n case 11:\n u[2] = u[2] ^ a[10] << 16;\n case 10:\n u[2] = u[2] ^ a[9] << 8;\n case 9:\n u[2] = u[2] ^ a[8] << 0, u[2] = Math.imul(u[2], f[2]), u[2] = g(u[2], 17), u[2] = Math.imul(u[2], f[3]), e[2] = e[2] ^ u[2];\n case 8:\n u[1] = u[1] ^ a[7] << 24;\n case 7:\n u[1] = u[1] ^ a[6] << 16;\n case 6:\n u[1] = u[1] ^ a[5] << 8;\n case 5:\n u[1] = u[1] ^ a[4] << 0, u[1] = Math.imul(u[1], f[1]), u[1] = g(u[1], 16), u[1] = Math.imul(u[1], f[2]), e[1] = e[1] ^ u[1];\n case 4:\n u[0] = u[0] ^ a[3] << 24;\n case 3:\n u[0] = u[0] ^ a[2] << 16;\n case 2:\n u[0] = u[0] ^ a[1] << 8;\n case 1:\n u[0] = u[0] ^ a[0] << 0, u[0] = Math.imul(u[0], f[0]), u[0] = g(u[0], 15), u[0] = Math.imul(u[0], f[1]), e[0] = e[0] ^ u[0];\n }\n }(n, i), function(o, e) {\n e[0] = e[0] ^ o.byteLength, e[1] = e[1] ^ o.byteLength, e[2] = e[2] ^ o.byteLength, e[3] = e[3] ^ o.byteLength, e[0] = e[0] + e[1] | 0, e[0] = e[0] + e[2] | 0, e[0] = e[0] + e[3] | 0, e[1] = e[1] + e[0] | 0, e[2] = e[2] + e[0] | 0, e[3] = e[3] + e[0] | 0, e[0] = M(e[0]), e[1] = M(e[1]), e[2] = M(e[2]), e[3] = M(e[3]), e[0] = e[0] + e[1] | 0, e[0] = e[0] + e[2] | 0, e[0] = e[0] + e[3] | 0, e[1] = e[1] + e[0] | 0, e[2] = e[2] + e[0] | 0, e[3] = e[3] + e[0] | 0;\n }(n, i);\n var s = new Uint8Array(i.buffer);\n return Array.from(s).map(function(o) {\n return o.toString(16).padStart(2, \"0\");\n }).join(\"\");\n}\nfunction G(n, t) {\n return new Promise(function(r) {\n setTimeout(function() {\n return r(t);\n }, n);\n });\n}\nfunction W(n, t, r) {\n return Promise.all(n.map(function(i) {\n return Promise.race([i, G(t, r)]);\n }));\n}\nfunction V() {\n return w(this, void 0, void 0, function() {\n var n, t, r, i, s;\n return y(this, function(o) {\n switch (o.label) {\n case 0:\n return o.trys.push([0, 2, , 3]), n = j(), t = Object.keys(n), [4, W(Object.values(n), (b == null ? void 0 : b.timeout) || 1e3, N)];\n case 1:\n return r = o.sent(), i = r.filter(function(e) {\n return e !== void 0;\n }), s = {}, i.forEach(function(e, c) {\n s[t[c]] = e;\n }), [2, _(s, b.exclude || [])];\n case 2:\n throw o.sent();\n case 3:\n return [2];\n }\n });\n });\n}\nfunction _(n, t) {\n var r = {}, i = function(o) {\n if (n.hasOwnProperty(o)) {\n var e = n[o];\n if (typeof e != \"object\" || Array.isArray(e)) t.includes(o) || (r[o] = e);\n else {\n var c = _(e, t.map(function(l) {\n return l.startsWith(o + \".\") ? l.slice(o.length + 1) : l;\n }));\n Object.keys(c).length > 0 && (r[o] = c);\n }\n }\n };\n for (var s in n) i(s);\n return r;\n}\nfunction H(n) {\n return w(this, void 0, void 0, function() {\n var t, r;\n return y(this, function(i) {\n switch (i.label) {\n case 0:\n return i.trys.push([0, 2, , 3]), [4, V()];\n case 1:\n return t = i.sent(), r = R(JSON.stringify(t)), [2, r.toString()];\n case 2:\n throw i.sent();\n case 3:\n return [2];\n }\n });\n });\n}\nfunction $(n) {\n for (var t = 0, r = 0; r < n.length; ++r) t += Math.abs(n[r]);\n return t;\n}\nfunction F(n, t, r) {\n for (var i = [], s = 0; s < n[0].data.length; s++) {\n for (var o = [], e = 0; e < n.length; e++) o.push(n[e].data[s]);\n i.push(K(o));\n }\n var c = new Uint8ClampedArray(i);\n return new ImageData(c, t, r);\n}\nfunction K(n) {\n if (n.length === 0) return 0;\n for (var t = {}, r = 0, i = n; r < i.length; r++)\n t[o = i[r]] = (t[o] || 0) + 1;\n var s = n[0];\n for (var o in t) t[o] > t[s] && (s = parseInt(o, 10));\n return s;\n}\nfunction E() {\n if (typeof navigator > \"u\") return { name: \"unknown\", version: \"unknown\" };\n for (var n = navigator.userAgent, t = { Edg: \"Edge\", OPR: \"Opera\" }, r = 0, i = [/(?<name>Edge|Edg)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>(?:Chrome|Chromium|OPR|Opera|Vivaldi|Brave))\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>(?:Firefox|Waterfox|Iceweasel|IceCat))\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>Safari)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>MSIE|Trident|IEMobile).+?(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>[A-Za-z]+)\\/(?<version>\\d+(?:\\.\\d+)?)/, /(?<name>SamsungBrowser)\\/(?<version>\\d+(?:\\.\\d+)?)/]; r < i.length; r++) {\n var s = i[r], o = n.match(s);\n if (o && o.groups) return { name: t[o.groups.name] || o.groups.name, version: o.groups.version };\n }\n return { name: \"unknown\", version: \"unknown\" };\n}\nv(\"audio\", function() {\n return w(this, void 0, void 0, function() {\n return y(this, function(n) {\n return [2, new Promise(function(t, r) {\n try {\n var i = new (window.OfflineAudioContext || window.webkitOfflineAudioContext)(1, 5e3, 44100), s = i.createBufferSource(), o = i.createOscillator();\n o.frequency.value = 1e3;\n var e, c = i.createDynamicsCompressor();\n c.threshold.value = -50, c.knee.value = 40, c.ratio.value = 12, c.attack.value = 0, c.release.value = 0.2, o.connect(c), c.connect(i.destination), o.start(), i.oncomplete = function(l) {\n e = l.renderedBuffer.getChannelData(0), t({ sampleHash: $(e), oscillator: o.type, maxChannels: i.destination.maxChannelCount, channelCountMode: s.channelCountMode });\n }, i.startRendering();\n } catch (l) {\n console.error(\"Error creating audio fingerprint:\", l), r(l);\n }\n })];\n });\n });\n});\nvar z = E().name !== \"SamsungBrowser\" ? 1 : 3, T = 280, C = 20;\nE().name != \"Firefox\" && v(\"canvas\", function() {\n return document.createElement(\"canvas\").getContext(\"2d\"), new Promise(function(n) {\n var t = Array.from({ length: z }, function() {\n return function() {\n var r = document.createElement(\"canvas\"), i = r.getContext(\"2d\");\n if (!i) return new ImageData(1, 1);\n r.width = T, r.height = C;\n var s = i.createLinearGradient(0, 0, r.width, r.height);\n s.addColorStop(0, \"red\"), s.addColorStop(0.16666666666666666, \"orange\"), s.addColorStop(0.3333333333333333, \"yellow\"), s.addColorStop(0.5, \"green\"), s.addColorStop(0.6666666666666666, \"blue\"), s.addColorStop(0.8333333333333334, \"indigo\"), s.addColorStop(1, \"violet\"), i.fillStyle = s, i.fillRect(0, 0, r.width, r.height);\n var o = \"Random Text WMwmil10Oo\";\n i.font = \"23.123px Arial\", i.fillStyle = \"black\", i.fillText(o, -5, 15), i.fillStyle = \"rgba(0, 0, 255, 0.5)\", i.fillText(o, -3.3, 17.7), i.beginPath(), i.moveTo(0, 0), i.lineTo(2 * r.width / 7, r.height), i.strokeStyle = \"white\", i.lineWidth = 2, i.stroke();\n var e = i.getImageData(0, 0, r.width, r.height);\n return e;\n }();\n });\n n({ commonImageDataHash: R(F(t, T, C).data.toString()).toString() });\n });\n});\nvar A, J = [\"Arial\", \"Arial Black\", \"Arial Narrow\", \"Arial Rounded MT\", \"Arimo\", \"Archivo\", \"Barlow\", \"Bebas Neue\", \"Bitter\", \"Bookman\", \"Calibri\", \"Cabin\", \"Candara\", \"Century\", \"Century Gothic\", \"Comic Sans MS\", \"Constantia\", \"Courier\", \"Courier New\", \"Crimson Text\", \"DM Mono\", \"DM Sans\", \"DM Serif Display\", \"DM Serif Text\", \"Dosis\", \"Droid Sans\", \"Exo\", \"Fira Code\", \"Fira Sans\", \"Franklin Gothic Medium\", \"Garamond\", \"Geneva\", \"Georgia\", \"Gill Sans\", \"Helvetica\", \"Impact\", \"Inconsolata\", \"Indie Flower\", \"Inter\", \"Josefin Sans\", \"Karla\", \"Lato\", \"Lexend\", \"Lucida Bright\", \"Lucida Console\", \"Lucida Sans Unicode\", \"Manrope\", \"Merriweather\", \"Merriweather Sans\", \"Montserrat\", \"Myriad\", \"Noto Sans\", \"Nunito\", \"Nunito Sans\", \"Open Sans\", \"Optima\", \"Orbitron\", \"Oswald\", \"Pacifico\", \"Palatino\", \"Perpetua\", \"PT Sans\", \"PT Serif\", \"Poppins\", \"Prompt\", \"Public Sans\", \"Quicksand\", \"Rajdhani\", \"Recursive\", \"Roboto\", \"Roboto Condensed\", \"Rockwell\", \"Rubik\", \"Segoe Print\", \"Segoe Script\", \"Segoe UI\", \"Sora\", \"Source Sans Pro\", \"Space Mono\", \"Tahoma\", \"Taviraj\", \"Times\", \"Times New Roman\", \"Titillium Web\", \"Trebuchet MS\", \"Ubuntu\", \"Varela Round\", \"Verdana\", \"Work Sans\"], Q = [\"monospace\", \"sans-serif\", \"serif\"];\nfunction k(n, t) {\n if (!n) throw new Error(\"Canvas context not supported\");\n return n.font = \"72px \".concat(t), n.measureText(\"WwMmLli0Oo\").width;\n}\nfunction Y() {\n var n, t = document.createElement(\"canvas\"), r = (n = t.getContext(\"webgl\")) !== null && n !== void 0 ? n : t.getContext(\"experimental-webgl\");\n if (r && \"getParameter\" in r) try {\n var i = (r.getParameter(r.VENDOR) || \"\").toString(), s = (r.getParameter(r.RENDERER) || \"\").toString(), o = { vendor: i, renderer: s, version: (r.getParameter(r.VERSION) || \"\").toString(), shadingLanguageVersion: (r.getParameter(r.SHADING_LANGUAGE_VERSION) || \"\").toString() };\n if (!s.length || !i.length) {\n var e = r.getExtension(\"WEBGL_debug_renderer_info\");\n if (e) {\n var c = (r.getParameter(e.UNMASKED_VENDOR_WEBGL) || \"\").toString(), l = (r.getParameter(e.UNMASKED_RENDERER_WEBGL) || \"\").toString();\n c && (o.vendorUnmasked = c), l && (o.rendererUnmasked = l);\n }\n }\n return o;\n } catch {\n }\n return \"undefined\";\n}\nfunction X() {\n var n = new Float32Array(1), t = new Uint8Array(n.buffer);\n return n[0] = 1 / 0, n[0] = n[0] - n[0], t[3];\n}\nfunction Z(n, t) {\n var r = {};\n return t.forEach(function(i) {\n var s = function(o) {\n if (o.length === 0) return null;\n var e = {};\n o.forEach(function(u) {\n var a = String(u);\n e[a] = (e[a] || 0) + 1;\n });\n var c = o[0], l = 1;\n return Object.keys(e).forEach(function(u) {\n e[u] > l && (c = u, l = e[u]);\n }), c;\n }(n.map(function(o) {\n return i in o ? o[i] : void 0;\n }).filter(function(o) {\n return o !== void 0;\n }));\n s && (r[i] = s);\n }), r;\n}\nfunction ee() {\n var n = [], t = { \"prefers-contrast\": [\"high\", \"more\", \"low\", \"less\", \"forced\", \"no-preference\"], \"any-hover\": [\"hover\", \"none\"], \"any-pointer\": [\"none\", \"coarse\", \"fine\"], pointer: [\"none\", \"coarse\", \"fine\"], hover: [\"hover\", \"none\"], update: [\"fast\", \"slow\"], \"inverted-colors\": [\"inverted\", \"none\"], \"prefers-reduced-motion\": [\"reduce\", \"no-preference\"], \"prefers-reduced-transparency\": [\"reduce\", \"no-preference\"], scripting: [\"none\", \"initial-only\", \"enabled\"], \"forced-colors\": [\"active\", \"none\"] };\n return Object.keys(t).forEach(function(r) {\n t[r].forEach(function(i) {\n matchMedia(\"(\".concat(r, \": \").concat(i, \")\")).matches && n.push(\"\".concat(r, \": \").concat(i));\n });\n }), n;\n}\nfunction te() {\n if (window.location.protocol === \"https:\" && typeof window.ApplePaySession == \"function\") try {\n for (var n = window.ApplePaySession.supportsVersion, t = 15; t > 0; t--) if (n(t)) return t;\n } catch {\n return 0;\n }\n return 0;\n}\nE().name != \"Firefox\" && v(\"fonts\", function() {\n var n = this;\n return new Promise(function(t, r) {\n try {\n (function(i) {\n var s;\n w(this, void 0, void 0, function() {\n var o, e, c;\n return y(this, function(l) {\n switch (l.label) {\n case 0:\n return document.body ? [3, 2] : [4, (u = 50, new Promise(function(p) {\n return setTimeout(p, u, a);\n }))];\n case 1:\n return l.sent(), [3, 0];\n case 2:\n if ((o = document.createElement(\"iframe\")).setAttribute(\"frameBorder\", \"0\"), (e = o.style).setProperty(\"position\", \"fixed\"), e.setProperty(\"display\", \"block\", \"important\"), e.setProperty(\"visibility\", \"visible\"), e.setProperty(\"border\", \"0\"), e.setProperty(\"opacity\", \"0\"), o.src = \"about:blank\", document.body.appendChild(o), !(c = o.contentDocument || ((s = o.contentWindow) === null || s === void 0 ? void 0 : s.document))) throw new Error(\"Iframe document is not accessible\");\n return i({ iframe: c }), setTimeout(function() {\n document.body.removeChild(o);\n }, 0), [2];\n }\n var u, a;\n });\n });\n })(function(i) {\n var s = i.iframe;\n return w(n, void 0, void 0, function() {\n var o, e, c, l;\n return y(this, function(u) {\n return o = s.createElement(\"canvas\"), e = o.getContext(\"2d\"), c = Q.map(function(a) {\n return k(e, a);\n }), l = {}, J.forEach(function(a) {\n var p = k(e, a);\n c.includes(p) || (l[a] = p);\n }), t(l), [2];\n });\n });\n });\n } catch {\n r({ error: \"unsupported\" });\n }\n });\n}), v(\"hardware\", function() {\n return new Promise(function(n, t) {\n var r = navigator.deviceMemory !== void 0 ? navigator.deviceMemory : 0, i = window.performance && window.performance.memory ? window.performance.memory : 0;\n n({ videocard: Y(), architecture: X(), deviceMemory: r.toString() || \"undefined\", jsHeapSizeLimit: i.jsHeapSizeLimit || 0 });\n });\n}), v(\"locales\", function() {\n return new Promise(function(n) {\n n({ languages: navigator.language, timezone: Intl.DateTimeFormat().resolvedOptions().timeZone });\n });\n}), v(\"permissions\", function() {\n return w(this, void 0, void 0, function() {\n var n;\n return y(this, function(t) {\n return A = (b == null ? void 0 : b.permissions_to_check) || [\"accelerometer\", \"accessibility\", \"accessibility-events\", \"ambient-light-sensor\", \"background-fetch\", \"background-sync\", \"bluetooth\", \"camera\", \"clipboard-read\", \"clipboard-write\", \"device-info\", \"display-capture\", \"gyroscope\", \"geolocation\", \"local-fonts\", \"magnetometer\", \"microphone\", \"midi\", \"nfc\", \"notifications\", \"payment-handler\", \"persistent-storage\", \"push\", \"speaker\", \"storage-access\", \"top-level-storage-access\", \"window-management\", \"query\"], n = Array.from({ length: (b == null ? void 0 : b.retries) || 3 }, function() {\n return function() {\n return w(this, void 0, void 0, function() {\n var r, i, s, o, e;\n return y(this, function(c) {\n switch (c.label) {\n case 0:\n r = {}, i = 0, s = A, c.label = 1;\n case 1:\n if (!(i < s.length)) return [3, 6];\n o = s[i], c.label = 2;\n case 2:\n return c.trys.push([2, 4, , 5]), [4, navigator.permissions.query({ name: o })];\n case 3:\n return e = c.sent(), r[o] = e.state.toString(), [3, 5];\n case 4:\n return c.sent(), [3, 5];\n case 5:\n return i++, [3, 1];\n case 6:\n return [2, r];\n }\n });\n });\n }();\n }), [2, Promise.all(n).then(function(r) {\n return Z(r, A);\n })];\n });\n });\n}), v(\"plugins\", function() {\n var n = [];\n if (navigator.plugins) for (var t = 0; t < navigator.plugins.length; t++) {\n var r = navigator.plugins[t];\n n.push([r.name, r.filename, r.description].join(\"|\"));\n }\n return new Promise(function(i) {\n i({ plugins: n });\n });\n}), v(\"screen\", function() {\n return new Promise(function(n) {\n n({ is_touchscreen: navigator.maxTouchPoints > 0, maxTouchPoints: navigator.maxTouchPoints, colorDepth: screen.colorDepth, mediaMatches: ee() });\n });\n}), v(\"system\", function() {\n return new Promise(function(n) {\n var t = E();\n n({ platform: window.navigator.platform, cookieEnabled: window.navigator.cookieEnabled, productSub: navigator.productSub, product: navigator.product, useragent: navigator.userAgent, hardwareConcurrency: navigator.hardwareConcurrency, browser: { name: t.name, version: t.version }, applePayVersion: te() });\n });\n});\nvar h, ne = E().name !== \"SamsungBrowser\" ? 1 : 3, d = null;\nv(\"webgl\", function() {\n return w(this, void 0, void 0, function() {\n var n;\n return y(this, function(t) {\n typeof document < \"u\" && ((h = document.createElement(\"canvas\")).width = 200, h.height = 100, d = h.getContext(\"webgl\"));\n try {\n if (!d) throw new Error(\"WebGL not supported\");\n return n = Array.from({ length: ne }, function() {\n return function() {\n try {\n if (!d) throw new Error(\"WebGL not supported\");\n var r = `\n attribute vec2 position;\n void main() {\n gl_Position = vec4(position, 0.0, 1.0);\n }\n `, i = `\n precision mediump float;\n void main() {\n gl_FragColor = vec4(0.812, 0.195, 0.553, 0.921); // Set line color\n }\n `, s = d.createShader(d.VERTEX_SHADER), o = d.createShader(d.FRAGMENT_SHADER);\n if (!s || !o) throw new Error(\"Failed to create shaders\");\n if (d.shaderSource(s, r), d.shaderSource(o, i), d.compileShader(s), !d.getShaderParameter(s, d.COMPILE_STATUS)) throw new Error(\"Vertex shader compilation failed: \" + d.getShaderInfoLog(s));\n if (d.compileShader(o), !d.getShaderParameter(o, d.COMPILE_STATUS)) throw new Error(\"Fragment shader compilation failed: \" + d.getShaderInfoLog(o));\n var e = d.createProgram();\n if (!e) throw new Error(\"Failed to create shader program\");\n if (d.attachShader(e, s), d.attachShader(e, o), d.linkProgram(e), !d.getProgramParameter(e, d.LINK_STATUS)) throw new Error(\"Shader program linking failed: \" + d.getProgramInfoLog(e));\n d.useProgram(e);\n for (var c = 137, l = new Float32Array(4 * c), u = 2 * Math.PI / c, a = 0; a < c; a++) {\n var p = a * u;\n l[4 * a] = 0, l[4 * a + 1] = 0, l[4 * a + 2] = Math.cos(p) * (h.width / 2), l[4 * a + 3] = Math.sin(p) * (h.height / 2);\n }\n var U = d.createBuffer();\n d.bindBuffer(d.ARRAY_BUFFER, U), d.bufferData(d.ARRAY_BUFFER, l, d.STATIC_DRAW);\n var x = d.getAttribLocation(e, \"position\");\n d.enableVertexAttribArray(x), d.vertexAttribPointer(x, 2, d.FLOAT, !1, 0, 0), d.viewport(0, 0, h.width, h.height), d.clearColor(0, 0, 0, 1), d.clear(d.COLOR_BUFFER_BIT), d.drawArrays(d.LINES, 0, 2 * c);\n var I = new Uint8ClampedArray(h.width * h.height * 4);\n return d.readPixels(0, 0, h.width, h.height, d.RGBA, d.UNSIGNED_BYTE, I), new ImageData(I, h.width, h.height);\n } catch {\n return new ImageData(1, 1);\n } finally {\n d && (d.bindBuffer(d.ARRAY_BUFFER, null), d.useProgram(null), d.viewport(0, 0, d.drawingBufferWidth, d.drawingBufferHeight), d.clearColor(0, 0, 0, 0));\n }\n }();\n }), [2, { commonImageHash: R(F(n, h.width, h.height).data.toString()).toString() }];\n } catch {\n return [2, { webgl: \"unsupported\" }];\n }\n return [2];\n });\n });\n});\nvar S = function(n, t, r, i) {\n for (var s = (r - t) / i, o = 0, e = 0; e < i; e++)\n o += n(t + (e + 0.5) * s);\n return o * s;\n};\nv(\"math\", function() {\n return w(void 0, void 0, void 0, function() {\n return y(this, function(n) {\n return [2, { acos: Math.acos(0.5), asin: S(Math.asin, -1, 1, 97), atan: S(Math.atan, -1, 1, 97), cos: S(Math.cos, 0, Math.PI, 97), cosh: Math.cosh(9 / 7), e: Math.E, largeCos: Math.cos(1e20), largeSin: Math.sin(1e20), largeTan: Math.tan(1e20), log: Math.log(1e3), pi: Math.PI, sin: S(Math.sin, -Math.PI, Math.PI, 97), sinh: S(Math.sinh, -9 / 7, 7 / 9, 97), sqrt: Math.sqrt(2), tan: S(Math.tan, 0, 2 * Math.PI, 97), tanh: S(Math.tanh, -9 / 7, 7 / 9, 97) }];\n });\n });\n});\nconst re = 500;\nclass ae {\n constructor(t, r) {\n m(this, \"config\");\n m(this, \"sdkInfo\");\n m(this, \"userId\");\n m(this, \"sessionId\");\n m(this, \"searchRequestTimeout\");\n m(this, \"measureRequestTimeout\");\n m(this, \"measureRequestsBatched\", []);\n /**\n * Performs a search operation.\n * @param {SearchParams} searchParams - The parameters for the search.\n * @returns {Promise<SearchcraftResponse>} - Returns the search response or throws an error.\n */\n m(this, \"search\", (t, r) => {\n const i = async () => {\n if (this.sendMeasureEvent(\"search_requested\", {\n search_term: t.query\n }), (t.query.match(/\"/g) || []).length % 2 !== 0)\n throw new Error(\n \"The search term contains an uneven number of quote characters.\"\n );\n try {\n const o = {\n query: this.buildQueryObject(t),\n limit: t.limit ?? 20\n // Default to 20 if not provided\n };\n t.offset !== void 0 && (o.offset = t.offset), t.order_by && (o.order_by = t.order_by, o.sort = t.sort === \"desc\" || t.sort === \"asc\" ? t.sort : \"asc\");\n const e = {\n method: \"POST\",\n headers: {\n Authorization: this.config.readKey,\n \"Content-Type\": \"application/json\",\n \"X-Sc-User-Id\": this.userId\n },\n body: JSON.stringify(o)\n }, c = await fetch(this.baseSearchUrl, e);\n if (!c.ok)\n throw new Error(\n `Error: ${c.statusText} (Status: ${c.status})`\n );\n const l = await c.json();\n this.sendMeasureEvent(\"search_response_received\", {\n search_term: t.query,\n number_of_documents: l.data.count\n }), r(l);\n } catch (o) {\n throw console.error(\"Error parsing response:\", o), o;\n }\n };\n clearTimeout(this.searchRequestTimeout), this.config.searchDebounceDelay ? this.searchRequestTimeout = setTimeout(\n i,\n this.config.searchDebounceDelay\n ) : i();\n });\n /**\n * Sends a measure event to the `/measure/event` endpoint for analytics purposes.\n *\n * @param {MeasureEventName} eventName - Name of the event.\n * @param {Partial<MeasureRequestProperties>} properties - Additional properties to send with the event.\n * @param {Partial<MeasureRequestUser>} user - Additional user properites to send with the event.\n */\n m(this, \"sendMeasureEvent\", (t, r = {}, i = {}) => {\n const s = {\n event_name: t,\n properties: {\n searchcraft_index_names: this.config.index,\n ...r\n },\n user: {\n ...this.measureRequestUser,\n ...i\n }\n };\n this.measureRequestsBatched.push(s), clearTimeout(this.measureRequestTimeout), this.measureRequestTimeout = setTimeout(async () => {\n const o = JSON.stringify({ items: this.measureRequestsBatched }), e = `${this.baseMeasureUrl}/batch`;\n try {\n const c = await fetch(e, {\n method: \"POST\",\n headers: {\n \"Content-Type\": \"application/json\",\n Authorization: this.config.readKey,\n \"X-Sc-User-Id\": this.userId\n },\n body: o,\n keepalive: !0\n });\n if (!c.ok)\n throw new Error(\n `Failed to send request: ${c.status} ${c.statusText}`\n );\n this.measureRequestsBatched = [];\n return;\n } catch (c) {\n throw console.error(\"Error sending MeasureRequest:\", c), c;\n }\n }, re);\n });\n if (!t.endpointURL || !t.index || !t.readKey)\n throw new Error(\n \"Endpoint URL, Index value(s), and Read Key must be provided\"\n );\n this.config = t, this.sdkInfo = r, this.userId = t.userId || \"\", this.sessionId = \"\", setTimeout(() => {\n this.sessionId = q(), this.initMeasure();\n }, 300);\n }\n /**\n * Initializes this.userId based on config & sends the `sdk_innitialized` event.\n */\n async initMeasure() {\n if (!this.config.userId) {\n const t = await H();\n this.userId = t;\n }\n this.sendMeasureEvent(\"sdk_initialized\");\n }\n /**\n * Getter for the base url used by the /search endpoint.\n */\n get baseSearchUrl() {\n return `${this.config.endpointURL}/index/${this.config.index.join(\",\")}/search`;\n }\n /**\n * Getter for the base url used by the /measure endpoints.\n */\n get baseMeasureUrl() {\n return `${this.config.endpointURL}/measure`;\n }\n /**\n * Getter for the measure request user. Uses config values + navigator values.\n */\n get measureRequestUser() {\n return {\n user_id: this.userId,\n locale: navigator.language || \"en-US\",\n os: navigator.userAgent.includes(\"Windows\") ? \"Windows\" : navigator.userAgent.includes(\"Mac\") ? \"Mac\" : navigator.userAgent.includes(\"Linux\") ? \"Linux\" : \"Unknown\",\n platform: navigator.platform || \"Unknown\",\n sdk_name: this.sdkInfo.sdkName,\n sdk_version: this.sdkInfo.sdkVersion,\n user_agent: navigator.userAgent || \"Unknown\"\n };\n }\n /**\n * Builds a query object for the search request.\n * @param {SearchParams} searchParams - The parameters for the search.\n * @returns {QueryObject} - A properly formatted query object.\n */\n buildQueryObject(t) {\n const r = [];\n let i = \"should\";\n return t.facetPathsForIndexFields && Object.keys(t.facetPathsForIndexFields).forEach(\n (s) => {\n var e;\n const o = (e = t.facetPathsForIndexFields) == null ? void 0 : e[s];\n o && (i = \"must\", r.push({\n occur: i,\n exact: {\n ctx: o.value\n }\n }));\n }\n ), t.rangeValueForIndexFields && Object.keys(t.rangeValueForIndexFields).forEach(\n (s) => {\n var e;\n const o = (e = t.rangeValueForIndexFields) == null ? void 0 : e[s];\n o && (i = \"must\", r.push({\n occur: i,\n exact: {\n ctx: o.value\n }\n }));\n }\n ), t.sort === \"desc\" ? t.order_by = \"date_published\" : t.order_by = \"\", r.push({\n occur: i,\n // Valid, as 'occur' is a required property in QueryItem\n [t.mode]: { ctx: t.query }\n // Ensure dynamic mode is inside queryType\n }), r;\n }\n}\nvar O = /* @__PURE__ */ ((n) => (n[n.DEBUG = 0] = \"DEBUG\", n[n.INFO = 1] = \"INFO\", n[n.WARN = 2] = \"WARN\", n[n.ERROR = 3] = \"ERROR\", n))(O || {});\nclass se {\n constructor(t) {\n m(this, \"logLevel\");\n m(this, \"logFormatter\");\n this.logLevel = t.logLevel || 1, this.logFormatter = t.logFormatter || this.defaultFormatter;\n }\n defaultFormatter(t, r) {\n return `[${O[t]}] ${( new Date()).toISOString()}: ${r}`;\n }\n debug(t) {\n this.logLevel <= 0 && console.log(this.logFormatter(0, t));\n }\n info(t) {\n this.logLevel <= 1 && console.info(this.logFormatter(1, t));\n }\n warn(t) {\n this.logLevel <= 2 && console.warn(this.logFormatter(2, t));\n }\n error(t) {\n this.logLevel <= 3 && console.error(this.logFormatter(3, t));\n }\n}\n\n// Zustand store for Searchcraft state\nconst useSearchcraftStore = zustand.create((set, get) => {\n let searchcraft = null;\n let debuggerInstance = null;\n const log = (level, message) => {\n if (debuggerInstance) {\n switch (level) {\n case O.DEBUG:\n debuggerInstance.debug(message);\n break;\n case O.INFO:\n debuggerInstance.info(message);\n break;\n case O.WARN:\n debuggerInstance.warn(message);\n break;\n case O.ERROR:\n debuggerInstance.error(message);\n break;\n }\n }\n };\n return {\n setPopoverVisibility: (isVisible) => {\n set({\n isPopoverVisible: isVisible,\n });\n },\n isPopoverVisible: false,\n resetFacetPaths: () => {\n set({\n facetPathsForIndexFields: {},\n });\n },\n addFacetPathsForIndexField: (data) => set((state) => ({\n facetPathsForIndexFields: Object.assign(Object.assign({}, state.facetPathsForIndexFields), { [data.fieldName]: data }),\n })),\n removeFacetPathsForIndexField: (fieldName) => set((state) => {\n const currentPaths = state.facetPathsForIndexFields;\n delete currentPaths[fieldName];\n return {\n facetPathsForIndexFields: Object.assign({}, currentPaths),\n };\n }),\n addRangeValueForIndexField: (data) => set((state) => ({\n rangeValueForIndexFields: Object.assign(Object.assign({}, state.rangeValueForIndexFields), { [data.fieldName]: data }),\n })),\n removeRangeValueForIndexField: (fieldName) => set((state) => {\n const currentValues = state.rangeValueForIndexFields;\n delete currentValues[fieldName];\n return {\n rangeValueForIndexFields: Object.assign({}, currentValues),\n };\n }),\n setSearchMode: (mode) => set({ searchMode: mode }),\n setSortType: (type) => set({ sortType: type }),\n searchMode: 'fuzzy',\n sortType: 'asc',\n facetPathsForIndexFields: {},\n rangeValueForIndexFields: {},\n query: '',\n isRequesting: false,\n searchResults: null,\n facets: null,\n getSearchcraftInstance: () => searchcraft,\n setQuery: (query) => {\n /**\n * When a new query is set, also reset the sort type, search mode, and facet paths.\n */\n set(Object.assign({ query, facetPathsForIndexFields: {} }, (query.trim().length === 0 && {\n searchMode: 'fuzzy',\n sortType: 'asc',\n })));\n },\n setSearchResults: (results) => set({ searchResults: results }),\n setFacets: (facets) => set({ facets }),\n setIsRequesting: (isRequesting) => set({ isRequesting }),\n search: async () => {\n const state = get();\n log(O.INFO, `Starting search with search term: \"${state.query}\"`);\n if (!searchcraft) {\n throw new Error('Searchcraft instance is not initialized.');\n }\n if (!state.query.trim()) {\n log(O.INFO, 'No search request was made: search term was empty.');\n state.setSearchResults(null);\n return;\n }\n state.setIsRequesting(true);\n searchcraft.search({\n query: state.query,\n mode: state.searchMode,\n sort: state.sortType,\n facetPathsForIndexFields: state.facetPathsForIndexFields,\n rangeValueForIndexFields: state.rangeValueForIndexFields,\n }, (results) => {\n const updatedFacets = results.data.facets || null;\n state.setSearchResults(results);\n state.setFacets(updatedFacets);\n log(O.DEBUG, `Search results: ${JSON.stringify(results)}`);\n log(O.DEBUG, `Updated facets: ${JSON.stringify(updatedFacets)}`);\n state.setIsRequesting(false);\n });\n },\n initialize: (searchcraftInstance, debug = false) => {\n searchcraft = searchcraftInstance;\n debuggerInstance = debug\n ? new se({ logLevel: O.DEBUG })\n : null;\n log(O.INFO, 'Searchcraft store initialized.');\n },\n };\n});\nconst useThemeStore = zustand.create((set) => ({\n theme: 'light',\n toggleTheme: () => set((state) => ({ theme: state.theme === 'light' ? 'dark' : 'light' })),\n}));\n\nexport { useThemeStore as a, ae as b, useSearchcraftStore as u };\n\n//# sourceMappingURL=p-01dc5b3b.js.map","import { p as proxyCustomElement, H, h, F as Fragment } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\n\nconst searchcraftBaseSearchResultModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-search-result-container{all:unset;align-items:flex-start;border-radius:16px;display:flex;flex-direction:column;gap:16px;padding:8px;color:inherit;background-color:var(--sc-surface-neutral-primary)}@media (min-width: 768px){.searchcraft-search-result-container{flex-direction:row}}a.searchcraft-search-result-container{cursor:pointer;transition:background-color 100ms}.searchcraft-base-search-result-content-container{flex:1;display:flex;flex-direction:column;gap:8px}.searchcraft-search-result-image{border-radius:var(--sc-image-border-radius);width:100%}@media (min-width: 768px){.searchcraft-search-result-image{width:200px}}.searchcraft-base-search-result-title{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-bold-font-size);font-weight:var(--sc-body-bold-font-weight);line-height:var(--sc-body-bold-line-height);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-base-search-result-subtitle{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);margin:0;color:var(--sc-content-disabled)}.searchcraft-base-search-result-body-content{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-base-search-result-footer-content{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-disabled)}\";\nconst SearchcraftBaseSearchResultStyle0 = searchcraftBaseSearchResultModuleCss;\n\nconst SearchcraftBaseSearchResult = /*@__PURE__*/ proxyCustomElement(class SearchcraftBaseSearchResult extends H {\n constructor() {\n super();\n this.__registerHost();\n /**\n * Where to open the link for the button rendered when containerHref is not present.\n */\n this.buttonTarget = '_blank';\n /**\n * Where to open the link for the containing element.\n */\n this.containerTarget = '_blank';\n /**\n * The position in the document. Used with the \"document_clicked\" measure event.\n */\n this.documentPosition = 0;\n this.searchcraftStore = useSearchcraftStore.getState();\n this.recordMeasureEvent = () => {\n var _a, _b, _c;\n const searchcraft = this.searchcraftStore.getSearchcraftInstance();\n if (searchcraft) {\n const document_position = this.documentPosition;\n const search_term = this.searchcraftStore.query;\n const number_of_documents = ((_c = (_b = (_a = this.searchcraftStore.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;\n searchcraft.sendMeasureEvent('document_clicked', {\n document_position,\n number_of_documents,\n search_term,\n });\n }\n };\n this.parseStyles = () => {\n if (this.customStyles) {\n try {\n return JSON.parse(this.customStyles);\n }\n catch (error) {\n console.error('Error parsing custom styles:', error);\n return {};\n }\n }\n return {};\n };\n }\n render() {\n const styles = this.parseStyles();\n const imageContainer = this.imageSrc && (h(\"img\", { alt: this.imageAlt, class: 'searchcraft-search-result-image', src: this.imageSrc, style: styles.image || {} }));\n const contentContainer = (h(Fragment, null, this.imageSrc && this.imagePlacement === 'left' && imageContainer, h(\"div\", { class: 'searchcraft-base-search-result-content-container' }, this.titleContent && (h(\"h2\", { class: 'searchcraft-base-search-result-title', style: styles.title || {} }, this.titleContent)), this.subtitleContent && (h(\"h3\", { class: 'searchcraft-base-search-result-subtitle', style: styles.subtitle || {} }, this.subtitleContent)), this.bodyContent && (h(\"p\", { class: 'searchcraft-base-search-result-body-content', style: styles.primaryContent || {} }, this.bodyContent)), this.footerContent && (h(\"p\", { class: 'searchcraft-base-search-result-footer-content', style: styles.secondaryContent || {} }, this.footerContent)), this.buttonHref && !this.containerHref && this.buttonLabel && (h(\"a\", { class: 'searchcraft-search-result-button', href: this.buttonHref, style: styles.button || {}, target: this.buttonTarget, rel: this.buttonRel }, this.buttonLabel))), this.imageSrc && this.imagePlacement === 'right' && imageContainer));\n /** Render as an anchor tag if the containerHref prop is present. */\n if (this.containerHref) {\n return (h(\"a\", { class: 'searchcraft-search-result-container', onClick: this.recordMeasureEvent, href: this.containerHref, rel: this.containerRel, style: styles.container || {}, tabindex: '0', target: this.containerTarget }, contentContainer));\n }\n /** Render as a div if no href prop. */\n return (h(\"div\", { class: 'searchcraft-search-result-container', style: styles.container || {} }, contentContainer));\n }\n static get style() { return SearchcraftBaseSearchResultStyle0; }\n}, [0, \"searchcraft-base-search-result\", {\n \"titleContent\": [1, \"title-content\"],\n \"subtitleContent\": [1, \"subtitle-content\"],\n \"bodyContent\": [1, \"body-content\"],\n \"footerContent\": [1, \"footer-content\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"buttonHref\": [1, \"button-href\"],\n \"buttonTarget\": [1, \"button-target\"],\n \"buttonRel\": [1, \"button-rel\"],\n \"containerHref\": [1, \"container-href\"],\n \"containerTarget\": [1, \"container-target\"],\n \"containerRel\": [1, \"container-rel\"],\n \"imageSrc\": [1, \"image-src\"],\n \"imageAlt\": [1, \"image-alt\"],\n \"imagePlacement\": [1, \"image-placement\"],\n \"customStyles\": [1, \"custom-styles\"],\n \"documentPosition\": [2, \"document-position\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-base-search-result\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-base-search-result\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftBaseSearchResult);\n }\n break;\n } });\n}\n\nexport { SearchcraftBaseSearchResult as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-87d1611b.js.map","import { S as SearchcraftBaseSearchResult$1, d as defineCustomElement$1 } from './p-87d1611b.js';\n\nconst SearchcraftBaseSearchResult = SearchcraftBaseSearchResult$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftBaseSearchResult, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-base-search-result.js.map","/**\n * Given a document and a SearchResultMapping, return a mapped value from the document.\n *\n * Applies formatting based on the values specified in the `SearchResultFieldName` values.\n *\n * @param document\n * @param {SearchResultMapping} mapping\n * @returns {string | undefined}\n */\nfunction getDocumentValueFromSearchResultMapping(document, mapping) {\n if (document && mapping) {\n return mapping.fieldNames\n .map((fieldNameDetails) => {\n let valueFound = document[fieldNameDetails.fieldName];\n if (valueFound) {\n switch (fieldNameDetails.dataType) {\n case 'date': {\n // TODO: Use fieldNameDetails.DateFormatOptions to format the date\n valueFound = getFormattedTimeFromNow(valueFound);\n break;\n }\n case 'number': {\n valueFound = Intl.NumberFormat(fieldNameDetails.numberFormatLocale, fieldNameDetails.numberFormatOptions).format(valueFound * (fieldNameDetails.numberScale || 1));\n break;\n }\n }\n }\n return valueFound;\n })\n .filter((value) => !!value)\n .join(mapping.delimiter || ' ');\n }\n}\nfunction getMillis(unit) {\n const millisInHour = 60 * 60 * 1000;\n const millisInDay = 24 * millisInHour;\n const millisInMonth = 30 * millisInDay;\n const millisInYear = 365 * millisInDay;\n switch (unit) {\n case 'hour':\n return millisInHour;\n case 'day':\n return millisInDay;\n case 'month':\n return millisInMonth;\n case 'year':\n return millisInYear;\n default:\n return 3600000;\n }\n}\nfunction formatNumberWithCommas(number) {\n return number.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n}\n/**\n * Given a timestamp value, returns a formatted time string for the time\n * since now.\n *\n * @param timestamp\n * @returns {string} Formatted string value\n */\nfunction getFormattedTimeFromNow(timestamp) {\n const now = new Date();\n const inputTime = new Date(timestamp);\n const diffInSeconds = Math.floor((now.getTime() - inputTime.getTime()) / 1000);\n const minutes = Math.floor(diffInSeconds / 60);\n const hours = Math.floor(minutes / 60);\n const days = Math.floor(hours / 24);\n const years = Math.floor(days / 365);\n if (minutes < 60) {\n return `${minutes}m ago`;\n }\n if (hours < 24) {\n return `${hours}h ago`;\n }\n if (days < 365) {\n return `${days}d ago`;\n }\n return `${years}y ago`;\n}\n\nexport { getMillis as a, formatNumberWithCommas as f, getDocumentValueFromSearchResultMapping as g };\n\n//# sourceMappingURL=p-755f491b.js.map","function parseCustomStyles(styles) {\n if (typeof styles === 'string') {\n try {\n return JSON.parse(styles);\n }\n catch (error) {\n console.error('Invalid customStyles format:', styles);\n return {};\n }\n }\n return styles || {};\n}\nfunction serializeStyles(styles) {\n try {\n return JSON.stringify(styles);\n }\n catch (error) {\n console.error('Error serializing styles:', error);\n return '{}';\n }\n}\n\nexport { parseCustomStyles as p, serializeStyles as s };\n\n//# sourceMappingURL=p-d9551738.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\n\nconst searchcraftErrorMessageModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-error-message{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);color:var(--sc-content-danger);margin:0}\";\nconst SearchcraftErrorMessageStyle0 = searchcraftErrorMessageModuleCss;\n\nconst SearchcraftErrorMessage = /*@__PURE__*/ proxyCustomElement(class SearchcraftErrorMessage extends H {\n constructor() {\n super();\n this.__registerHost();\n }\n render() {\n return (h(\"p\", { key: '5bdc428adf6f239d66a9b0f946ee6e582de41e86', class: 'searchcraft-error-message' }, this.errorMessage || 'Search term is required.'));\n }\n static get style() { return SearchcraftErrorMessageStyle0; }\n}, [0, \"searchcraft-error-message\", {\n \"errorMessage\": [1, \"error-message\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-error-message\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftErrorMessage);\n }\n break;\n } });\n}\n\nexport { SearchcraftErrorMessage as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-f5a06210.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\nimport { g as getDocumentValueFromSearchResultMapping } from './p-755f491b.js';\nimport { s as serializeStyles } from './p-d9551738.js';\nimport { d as defineCustomElement$3 } from './p-87d1611b.js';\nimport { d as defineCustomElement$2 } from './p-f5a06210.js';\n\nconst searchcraftBaseSearchResultsModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-search-results-container{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-ad-section{align-items:center;background-color:#F1F1F1;border-radius:16px;display:flex;flex-direction:column;font-size:16px;justify-content:center;min-height:176px;text-align:center}.searchcraft-ad-section p{margin:0;color:var(--sc-content-disabled)}.searchcraft-search-results-empty-state-container{text-align:center}.searchcraft-search-results-error-message-container{text-align:center}\";\nconst SearchcraftBaseSearchResultsStyle0 = searchcraftBaseSearchResultsModuleCss;\n\nconst SearchcraftBaseSearchResults$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftBaseSearchResults extends H {\n constructor() {\n super();\n this.__registerHost();\n this.noResults = createEvent(this, \"noResults\", 7);\n /**\n * How often ads are injected.\n */\n this.adInterval = 4;\n /**\n * Should an ad be placed at the end of the results.\n */\n this.placeAdAtEnd = false;\n /**\n * Should an ad be placed at the start of the results.\n */\n this.placeAdAtStart = true;\n /**\n * The placement of the image for each result.\n */\n this.resultImagePlacement = 'right';\n /**\n * Where to open the link for the button rendered when containerHref is not present for each result.\n */\n this.buttonTarget = '_blank';\n /**\n * Where to open the link for the containing element for each result.\n */\n this.containerTarget = '_blank';\n this.hasSearched = false;\n this.query = '';\n this.searchResults = null;\n }\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query.length > 0) {\n this.hasSearched = true;\n }\n else {\n this.hasSearched = false;\n }\n this.searchResults = Object.assign({}, state.searchResults);\n this.query = state.query;\n });\n const { searchResults, query } = useSearchcraftStore.getState();\n this.searchResults = searchResults;\n this.query = query;\n }\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n renderDocument(document, index) {\n /**\n * Index field values -> Result container props mappings.\n */\n const titleContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.title);\n const subtitleContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.subtitle);\n const bodyContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.body);\n const containerHref = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.containerHref);\n const buttonHref = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.buttonHref);\n const imageSource = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.imageSource);\n const footerContent = getDocumentValueFromSearchResultMapping(document, this.searchResultMappings.footer);\n const serializedStyles = typeof this.customStylesForResults === 'string'\n ? this.customStylesForResults\n : serializeStyles(this.customStylesForResults);\n return (h(\"searchcraft-base-search-result\", { key: `${document.document_id}-${index}`, \"custom-styles\": serializedStyles, \"image-placement\": this.resultImagePlacement, \"container-rel\": this.containerRel, \"container-target\": this.containerTarget, \"button-label\": this.buttonLabel || 'View more', \"button-rel\": this.buttonRel, \"button-target\": this.buttonTarget, \"document-position\": index, \"title-content\": titleContent, \"subtitle-content\": subtitleContent, \"body-content\": bodyContent, \"footer-content\": footerContent, \"container-href\": containerHref, \"button-href\": buttonHref, \"image-src\": imageSource }));\n }\n render() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;\n if (this.query.trim() === '') {\n return (h(\"div\", { class: 'searchcraft-search-results-empty-state-container' }, h(\"slot\", { name: 'empty-search' })));\n }\n if (!((_a = this.searchResults) === null || _a === void 0 ? void 0 : _a.data)) {\n return;\n }\n const documents = (_d = (_c = (_b = this.searchResults) === null || _b === void 0 ? void 0 : _b.data) === null || _c === void 0 ? void 0 : _c.hits) === null || _d === void 0 ? void 0 : _d.map((data, _index) => {\n const { doc: result } = data;\n return result;\n });\n const finalComponents = [];\n if (this.placeAdAtStart) {\n finalComponents.push(h(\"div\", { key: 'ad-section-start', class: 'searchcraft-ad-section' }, h(\"p\", null, \"Ad Section\")));\n }\n if (this.adInterval > 0) {\n documents.forEach((document, index) => {\n finalComponents.push(this.renderDocument(document, index));\n if ((index + 1) % this.adInterval === 0) {\n finalComponents.push(h(\"div\", { key: `ad-section-${index + 1}`, class: 'searchcraft-ad-section ' }, h(\"p\", null, \"Ad Section\")));\n }\n });\n }\n else {\n const documentElements = documents.map((document, index) => this.renderDocument(document, index));\n finalComponents.push(...documentElements);\n }\n if (this.placeAdAtEnd) {\n finalComponents.push(h(\"div\", { key: 'ad-section-end', class: 'searchcraft-ad-section' }, h(\"p\", null, \"Ad Section\")));\n }\n if (this.query.length > 0 && ((_g = (_f = (_e = this.searchResults) === null || _e === void 0 ? void 0 : _e.data) === null || _f === void 0 ? void 0 : _f.hits) === null || _g === void 0 ? void 0 : _g.length) === 0) {\n this.noResults.emit();\n }\n return (h(\"div\", { class: 'searchcraft-search-results-container' }, finalComponents, this.query.length > 0 &&\n ((_k = (_j = (_h = this.searchResults) === null || _h === void 0 ? void 0 : _h.data) === null || _j === void 0 ? void 0 : _j.hits) === null || _k === void 0 ? void 0 : _k.length) === 0 && (h(\"div\", { class: 'searchcraft-search-results-error-message-container' }, h(\"searchcraft-error-message\", { \"error-message\": `No search results found for \"${this.query}\" query` })))));\n }\n static get style() { return SearchcraftBaseSearchResultsStyle0; }\n}, [4, \"searchcraft-base-search-results\", {\n \"adInterval\": [2, \"ad-interval\"],\n \"customStylesForResults\": [1, \"custom-styles-for-results\"],\n \"searchResultMappings\": [16],\n \"placeAdAtEnd\": [4, \"place-ad-at-end\"],\n \"placeAdAtStart\": [4, \"place-ad-at-start\"],\n \"resultImagePlacement\": [1, \"result-image-placement\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"buttonTarget\": [1, \"button-target\"],\n \"buttonRel\": [1, \"button-rel\"],\n \"containerTarget\": [1, \"container-target\"],\n \"containerRel\": [1, \"container-rel\"],\n \"hasSearched\": [32],\n \"query\": [32],\n \"searchResults\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-base-search-results\", \"searchcraft-base-search-result\", \"searchcraft-error-message\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-base-search-results\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftBaseSearchResults$1);\n }\n break;\n case \"searchcraft-base-search-result\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftBaseSearchResults = SearchcraftBaseSearchResults$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftBaseSearchResults, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-base-search-results.js.map","var classnames = {exports: {}};\n\n/*!\n\tCopyright (c) 2018 Jed Watson.\n\tLicensed under the MIT License (MIT), see\n\thttp://jedwatson.github.io/classnames\n*/\n\n(function (module) {\n/* global define */\n\n(function () {\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames () {\n\t\tvar classes = '';\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (arg) {\n\t\t\t\tclasses = appendClass(classes, parseValue(arg));\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction parseValue (arg) {\n\t\tif (typeof arg === 'string' || typeof arg === 'number') {\n\t\t\treturn arg;\n\t\t}\n\n\t\tif (typeof arg !== 'object') {\n\t\t\treturn '';\n\t\t}\n\n\t\tif (Array.isArray(arg)) {\n\t\t\treturn classNames.apply(null, arg);\n\t\t}\n\n\t\tif (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes('[native code]')) {\n\t\t\treturn arg.toString();\n\t\t}\n\n\t\tvar classes = '';\n\n\t\tfor (var key in arg) {\n\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\tclasses = appendClass(classes, key);\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction appendClass (value, newClass) {\n\t\tif (!newClass) {\n\t\t\treturn value;\n\t\t}\n\t\n\t\tif (value) {\n\t\t\treturn value + ' ' + newClass;\n\t\t}\n\t\n\t\treturn value + newClass;\n\t}\n\n\tif (module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n}(classnames));\n\nconst classNames = classnames.exports;\n\nexport { classNames as c };\n\n//# sourceMappingURL=p-5cdc6210.js.map","import { p as proxyCustomElement, H, c as createEvent, h, F as Fragment } from './p-6cafd48d.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftButtonModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-button{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-bold-font-size);font-weight:var(--sc-body-bold-font-weight);line-height:var(--sc-body-bold-line-height);border-radius:8px;display:flex;padding:12px 20px;position:relative;background-color:var(--sc-surface-brand-primary);border:1px solid var(--sc-border-primary);color:var(--sc-content-brand-on-primary)}.searchcraft-button:hover{cursor:pointer;background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button:focus{outline:2px solid var(--sc-surface-brand-primary)}.buttonLabel{position:relative}\";\nconst SearchcraftButtonStyle0 = searchcraftButtonModuleCss;\n\nconst SearchcraftButton = /*@__PURE__*/ proxyCustomElement(class SearchcraftButton extends H {\n constructor() {\n super();\n this.__registerHost();\n this.buttonClick = createEvent(this, \"buttonClick\", 7);\n /**\n * Should the button only display an icon.\n */\n this.iconOnly = false;\n /**\n * The position of the icon.\n */\n this.iconPosition = 'left';\n /**\n * The label for the button.\n */\n this.label = 'Search';\n this.isRequesting = false;\n this.handleClick = () => {\n this.buttonClick.emit();\n };\n }\n render() {\n return (h(Fragment, { key: '52b95f09f5da9f281b250285623e150c5d952dce' }, this.iconOnly ? (h(\"button\", { class: classNames('searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.isRequesting ? (h(\"searchcraft-spinner-dark\", null)) : (this.iconElement))) : (h(\"button\", { class: classNames('searchcraft-button'), onClick: this.handleClick, type: 'submit' }, this.iconPosition === 'left' && this.iconElement, h(\"span\", { class: classNames('buttonLabel', 'searchcraft-button-label') }, this.label)))));\n }\n static get style() { return SearchcraftButtonStyle0; }\n}, [0, \"searchcraft-button\", {\n \"iconElement\": [16],\n \"iconOnly\": [4, \"icon-only\"],\n \"iconPosition\": [1, \"icon-position\"],\n \"label\": [1],\n \"isRequesting\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-button\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftButton);\n }\n break;\n } });\n}\n\nexport { SearchcraftButton as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-cf096782.js.map","import { S as SearchcraftButton$1, d as defineCustomElement$1 } from './p-cf096782.js';\n\nconst SearchcraftButton = SearchcraftButton$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftButton, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-button.js.map","import { S as SearchcraftErrorMessage$1, d as defineCustomElement$1 } from './p-f5a06210.js';\n\nconst SearchcraftErrorMessage = SearchcraftErrorMessage$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftErrorMessage, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-error-message.js.map","import { p as proxyCustomElement, H, c as createEvent, h, F as Fragment } from './p-6cafd48d.js';\nimport { c as classNames } from './p-5cdc6210.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\n\nfunction deepMergeWithSpread(obj1, obj2) {\n const result = Object.assign({}, obj1);\n for (const key in obj2) {\n // biome-ignore lint/suspicious/noPrototypeBuiltins: <explanation>\n if (obj2.hasOwnProperty(key)) {\n if (obj2[key] instanceof Object && obj1[key] instanceof Object) {\n result[key] = deepMergeWithSpread(obj1[key], obj2[key]);\n }\n else {\n result[key] = obj2[key];\n }\n }\n }\n return result;\n}\n/**\n * Given an array of facet paths, removes parent facet paths.\n */\nfunction removeSubstringMatches(arr) {\n return arr.filter((entry, index, array) => !array.some((otherEntry, otherIndex) => otherIndex !== index && otherEntry.includes(entry)));\n}\nfunction facetToRecord(facet) {\n const records = {};\n const traverseAndAddToFragments = (facetChild) => {\n var _a;\n records[facetChild.path] = {\n count: facetChild.count,\n path: facetChild.path,\n };\n (_a = facetChild.children) === null || _a === void 0 ? void 0 : _a.forEach((child) => {\n traverseAndAddToFragments(child);\n });\n };\n traverseAndAddToFragments(facet);\n return records;\n}\nfunction recordToObject(record) {\n const root = {\n count: 0,\n path: '/',\n children: {},\n };\n Object.keys(record).forEach((key) => {\n const fragment = record[key];\n if (fragment.path === '/') {\n return;\n }\n const pathParts = fragment.path.substring(1).split('/');\n let currentRoot = root;\n let currentPath = '';\n pathParts.forEach((part, index) => {\n const nextPath = `${currentPath}/${part}`;\n if (!currentRoot.children[nextPath]) {\n currentRoot.children[nextPath] = {\n count: 0,\n path: nextPath,\n children: {},\n };\n }\n if (index === pathParts.length - 1) {\n currentRoot.children[nextPath].count = fragment.count;\n }\n currentPath = nextPath;\n currentRoot = currentRoot.children[nextPath];\n });\n });\n return root;\n}\nfunction objectToFacet(childObject) {\n const transformed = {\n count: childObject.count,\n path: childObject.path,\n children: [],\n };\n if (Object.keys(childObject.children).length > 0) {\n transformed.children = Object.values(childObject.children).map((subChildObject) => objectToFacet(subChildObject));\n }\n return transformed;\n}\n/**\n * Filters records with the parent paths from record2 OUT of record1\n */\nfunction filterRecordByParentPaths(record1, record2) {\n // Extract all paths (keys) both records\n const paths1 = Object.keys(record1);\n const paths2 = Object.keys(record2);\n // Find all parent paths in record2\n const parentPaths = new Set(paths2\n .filter((path) => path.split('/').length > 2) // Only consider paths with more than one level\n .map((path) => path.substring(0, path.lastIndexOf('/'))));\n // Filter out keys in record1 that share a parent path with any of the identified parent paths\n const filteredRecord = Object.fromEntries(paths1\n .filter((path) => !parentPaths.has(path.substring(0, path.lastIndexOf('/'))))\n .map((path) => [path, record1[path]]));\n return filteredRecord;\n}\nfunction mergeFacetRoots(fieldName, currentRoot, incomingRoot) {\n const currentArray = currentRoot[fieldName];\n const incomingArray = incomingRoot[fieldName];\n const currentRootFacetChild = {\n count: 0,\n path: '/',\n children: currentArray,\n };\n const incomingRootFacetChild = {\n count: 0,\n path: '/',\n children: incomingArray,\n };\n // Flatten them into records\n const currentRecord = facetToRecord(currentRootFacetChild);\n const incomingRecord = facetToRecord(incomingRootFacetChild);\n // Filter out the records from record1 (the current set of records)\n // that share a parent path with record2 (the incoming records)\n const filteredCurrentRecord = filterRecordByParentPaths(currentRecord, incomingRecord);\n // Deep merge the records together\n const mergedRecord = deepMergeWithSpread(filteredCurrentRecord, incomingRecord);\n // Convert into a heirarchical object\n const mergedObject = recordToObject(mergedRecord);\n // Convert the heirarchical object back to the Facet child structure\n const mergedFacetChild = objectToFacet(mergedObject);\n return {\n [fieldName]: mergedFacetChild.children,\n };\n}\n\nconst searchcraftFacetListModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.filtersListContainer{width:100%}.filterCheckboxLabel{align-items:center;color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);font-size:14px;font-weight:600;gap:14px;position:relative;-webkit-font-smoothing:antialiased}.filterCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:var(--sc-surface-brand-secondary-hover);border:1px solid var(--sc-surface-disabled);border-radius:8px;cursor:pointer;display:flex;height:24px;justify-content:center;width:24px}.filterCheckboxLabel input[type=checkbox]:focus{outline:2px solid var(--sc-surface-brand-primary)}.filterCheckboxLabel input[type=checkbox]:checked{background-color:var(--sc-surface-brand-primary);position:relative}.filterCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.filterCheckboxLabel input[type=checkbox]:checked+.dashContainer{display:block}.childFilterCheckboxLabel{align-items:center;color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);font-size:14px;font-weight:600;gap:12px;margin-left:24px;position:relative}.childFilterCheckboxLabel input[type=checkbox]{align-items:center;appearance:none;background-color:var(--sc-surface-brand-secondary-hover);border:1px solid var(--sc-surface-disabled);border-radius:8px;cursor:pointer;display:flex;height:24px;justify-content:center;position:relative;width:24px;-webkit-font-smoothing:antialiased}.childFilterCheckboxLabel input[type=checkbox]:focus{outline:2px solid var(--sc-surface-brand-primary)}.childFilterCheckboxLabel input[type=checkbox]:checked{background-color:var(--sc-surface-brand-primary);position:relative}.childFilterCheckboxLabel input[type=checkbox]:checked+.checkContainer{display:block}.childFilterCheckboxLabel input[type=checkbox]:checked+.dashContainer{display:block}.checkContainer{display:none;height:16px;width:16px;position:absolute;top:9px;left:8px}.dashContainer{display:none;height:3px;width:14px;position:absolute;top:3px;left:9px}.searchcraft-facet-message{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);color:var(--sc-content-disabled);text-align:center}\";\nconst SearchcraftFacetListStyle0 = searchcraftFacetListModuleCss;\n\nconst SearchcraftFacetList = /*@__PURE__*/ proxyCustomElement(class SearchcraftFacetList extends H {\n constructor() {\n super();\n this.__registerHost();\n this.facetSelectionUpdated = createEvent(this, \"facetSelectionUpdated\", 7);\n this.selectedPaths = {};\n this.hasNewSearchTerm = false;\n this.searchStore = useSearchcraftStore.getState();\n this.formatLabel = (facetChild) => {\n const label = facetChild.path.replace(/^\\//, '');\n const count = facetChild.count;\n return `${label.replace(/-/g, ' ').replace(/\\b\\w/g, (char) => char.toUpperCase())} (${count})`;\n };\n this.formatSubLabel = (facetChild, facetChildAncestor) => {\n const facetChildPath = facetChild.path.substring(facetChildAncestor.path.length);\n const label = facetChildPath.replace(/^\\//, '');\n const count = facetChild.count;\n return `${label.replace(/-/g, ' ').replace(/\\b\\w/g, (char) => char.toUpperCase())} (${count})`;\n };\n }\n handleStateUpdate(state) {\n var _a, _b;\n const facetPrime = (_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data.facets;\n const timeTaken = (_b = state.searchResults) === null || _b === void 0 ? void 0 : _b.data.time_taken;\n /** Things to do when the state's search term has changed, but before the response received */\n if (state.query !== this.lastQuery ||\n state.searchMode !== this.lastSearchMode ||\n state.sortType !== this.lastSortType) {\n this.selectedPaths = {};\n this.hasNewSearchTerm = true;\n }\n /** Things to do when a new response with a new facet prime has been received */\n if (timeTaken !== this.lastTimeTaken && facetPrime) {\n this.facetRoot = undefined;\n const incomingFacetRoot = facetPrime.find((facet) => this.fieldName === Object.keys(facet)[0]);\n /** Data is from a new search term: completely override our facets */\n if (this.hasNewSearchTerm) {\n this.baseFacetRoot = incomingFacetRoot;\n this.facetRoot = incomingFacetRoot;\n this.hasNewSearchTerm = false;\n }\n else if (this.baseFacetRoot) {\n /** Data is from an existing search term, merge the facets together */\n this.facetRoot = mergeFacetRoots(this.fieldName, this.baseFacetRoot, incomingFacetRoot);\n }\n }\n this.lastQuery = state.query;\n this.lastSearchMode = state.searchMode;\n this.lastSortType = state.sortType;\n this.lastTimeTaken = timeTaken;\n }\n connectedCallback() {\n this.handleStateUpdate(this.searchStore);\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.handleStateUpdate(state);\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n handleCheckboxChange(path) {\n const isCheckboxChecked = !this.selectedPaths[path];\n if (isCheckboxChecked) {\n /**\n * Checkbox Checked: Add to the selectedPaths record\n * Uses spread operator here so UI updates.\n */\n this.selectedPaths = Object.assign(Object.assign({}, this.selectedPaths), { [path]: true });\n }\n else {\n /**\n * Checkbox Uncheck: Remove any paths and sub-paths\n */\n const updatedPaths = Object.keys(this.selectedPaths).filter((testPath) => !testPath.includes(path));\n this.selectedPaths = updatedPaths.reduce((acc, str) => {\n acc[str] = true;\n return acc;\n }, {});\n }\n /**\n * Emit the paths array, with parent paths removed.\n */\n const paths = Object.keys(this.selectedPaths).filter((path) => this.selectedPaths[path]);\n const pathsWithParentPathsRemoved = removeSubstringMatches(paths);\n this.facetSelectionUpdated.emit({ paths: pathsWithParentPathsRemoved });\n }\n render() {\n var _a;\n const firstFacet = (_a = this.facetRoot) === null || _a === void 0 ? void 0 : _a[this.fieldName];\n return (h(\"div\", { key: '709834d9f86b75257ae0c67e9340c0fea4131035', class: classNames('filtersListContainer', 'searchcraft-filters-list-container') }, !firstFacet && (h(\"p\", { key: 'a6e2ced40fcc0762ae8ea835c9d6c573aceeb1f1', class: 'searchcraft-facet-message' }, \"Enter a search to view facets.\")), firstFacet === null || firstFacet === void 0 ? void 0 :\n firstFacet.map((facetChild) => {\n var _a;\n const isChildSelected = facetChild.children\n ? (_a = facetChild.children) === null || _a === void 0 ? void 0 : _a.some((child) => this.selectedPaths[child.path])\n : false;\n return (h(\"div\", { key: facetChild.path, class: classNames('searchcraft-filters-list-item') }, h(\"label\", { class: classNames('filterCheckboxLabel', 'searchcraft-filters-list-checkbox-label') }, h(\"input\", { checked: this.selectedPaths[facetChild.path], onChange: (_event) => this.handleCheckboxChange(facetChild.path), type: 'checkbox' }), isChildSelected ? (h(\"div\", { class: classNames('dashContainer', 'searchcraft-filter-list-dash-container') }, h(\"searchcraft-dash-icon\", null))) : (h(\"div\", { class: classNames('checkContainer', 'searchcraft-filter-list-check-container') }, h(\"searchcraft-check-icon\", null))), this.formatLabel(facetChild)), facetChild.children && facetChild.children.length > 0 && (h(Fragment, null, facetChild.children.map((grandchild) => (h(\"label\", { key: grandchild.path, class: classNames('childFilterCheckboxLabel', 'searchcraft-child-filter-checkbox-label'), style: {\n display: this.selectedPaths[facetChild.path]\n ? 'flex'\n : 'none',\n } }, h(\"input\", { checked: this.selectedPaths[grandchild.path], onChange: (_event) => {\n this.handleCheckboxChange(grandchild.path);\n }, type: 'checkbox' }), h(\"div\", { class: classNames('checkContainer', 'searchcraft-filter-list-check-container') }, h(\"searchcraft-check-icon\", null)), this.formatSubLabel(grandchild, facetChild))))))));\n })));\n }\n static get style() { return SearchcraftFacetListStyle0; }\n}, [0, \"searchcraft-facet-list\", {\n \"fieldName\": [1, \"field-name\"],\n \"baseFacetRoot\": [32],\n \"facetRoot\": [32],\n \"selectedPaths\": [32],\n \"lastTimeTaken\": [32],\n \"hasNewSearchTerm\": [32],\n \"lastQuery\": [32],\n \"lastSearchMode\": [32],\n \"lastSortType\": [32],\n \"unsubscribe\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-facet-list\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-facet-list\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftFacetList);\n }\n break;\n } });\n}\n\nexport { SearchcraftFacetList as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-649654b5.js.map","import { S as SearchcraftFacetList$1, d as defineCustomElement$1 } from './p-649654b5.js';\n\nconst SearchcraftFacetList = SearchcraftFacetList$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftFacetList, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-facet-list.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-6cafd48d.js';\nimport { a as getMillis } from './p-755f491b.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftSliderModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-slider-container{align-items:center;display:flex;flex-direction:column;gap:10px;width:100%}.searchcraft-slider-range-container{align-items:center;background-color:var(--sc-surface-disabled);border-radius:999px;display:flex;position:relative;height:4px;width:100%}.searchcraft-slider-range-container::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-active-range{background-color:var(--sc-surface-brand-primary);border-radius:2px;height:4px;position:absolute;top:50%;transform:translateY(-50%);z-index:0}.searchcraft-slider-range-container .searchcraft-slider-active-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-active-range::-moz-range-track{pointer-events:none}.searchcraft-slider-range-container .searchcraft-slider-input{appearance:none;background:transparent;border-radius:2px;height:4px;margin:0;outline:none;pointer-events:none;position:absolute;width:100%;-webkit-appearance:none}.searchcraft-slider-range-container .searchcraft-slider-input::-webkit-slider-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:2px solid var(--sc-border-neutral);cursor:pointer;height:20px;pointer-events:all;width:20px;-webkit-appearance:none}.searchcraft-slider-range-container .searchcraft-slider-input::-moz-range-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:2px solid var(--sc-border-neutral);cursor:pointer;height:20px;pointer-events:all;width:20px}.searchcraft-slider-label-container{color:var(--sc-content-primary);display:flex;font-family:\\\"Source Sans Pro\\\", sans-serif;font-size:15px;font-weight:600;justify-content:space-between;margin-top:10px;width:100%}.searchcraft-slider-label{min-width:30px;text-align:center}\";\nconst SearchcraftSliderStyle0 = searchcraftSliderModuleCss;\n\nconst SearchcraftSlider = /*@__PURE__*/ proxyCustomElement(class SearchcraftSlider extends H {\n constructor() {\n super();\n this.__registerHost();\n this.rangeChanged = createEvent(this, \"rangeChanged\", 7);\n /**\n * The maximum value allowed.\n */\n this.max = 100;\n /**\n * The minimum value allowed.\n */\n this.min = 0;\n /**\n * The granularity that the value must adhere to.\n */\n this.granularity = getMillis('month');\n /** The type of data allowed. */\n this.dataType = 'number';\n this.endValue = this.max;\n this.startValue = this.min;\n this.lastFocusedHandle = 'max';\n this.emitUpdate = async () => {\n this.rangeChanged.emit({\n startValue: this.startValue,\n endValue: this.endValue,\n });\n };\n this.handleStartValueChange = (event) => {\n const inputElement = event.target;\n const value = Number.parseInt(inputElement.value, 10);\n this.lastFocusedHandle = 'min';\n if (value <= this.endValue) {\n this.startValue = value;\n this.emitUpdate();\n }\n else {\n this.startValue = this.endValue;\n inputElement.value = `${this.endValue}`;\n }\n };\n this.handleEndValueChange = (event) => {\n const inputElement = event.target;\n const value = Number.parseInt(inputElement.value, 10);\n this.lastFocusedHandle = 'max';\n if (value >= this.startValue) {\n this.endValue = value;\n this.emitUpdate();\n }\n else {\n this.endValue = this.startValue;\n inputElement.value = `${this.startValue}`;\n }\n };\n }\n componentDidLoad() {\n this.startValue = this.min;\n this.endValue = this.max;\n }\n render() {\n const rangeMin = this.min;\n const rangeMax = this.max;\n const startPercent = ((this.startValue - rangeMin) / (rangeMax - rangeMin)) * 100;\n const endPercent = ((this.endValue - rangeMin) / (rangeMax - rangeMin)) * 100;\n const startLabel = this.dataType === 'number'\n ? this.startValue\n : new Date(this.startValue).getFullYear();\n const endLabel = this.dataType === 'number'\n ? this.endValue\n : new Date(this.endValue).getFullYear();\n return (h(\"div\", { key: 'd03f03307d560048eff499afabb4171421c9b5cd', class: 'searchcraft-slider-container' }, h(\"div\", { key: '986b2fb47def38024b256cb093546ee7db9ccf5c', class: 'searchcraft-slider-range-container' }, h(\"div\", { key: '4c4f71c218f65acbfa25ec220cdeb581ef0e6c0d', class: 'searchcraft-slider-active-range', style: {\n left: `${startPercent}%`,\n width: `${endPercent - startPercent}%`,\n } }), h(\"input\", { key: '8968b1925f83480561a460b5f7da64499ec220c0', class: classNames('searchcraft-slider-input', 'searchcraft-slider-input-min-handle'), max: this.max, min: this.min, onInput: this.handleStartValueChange.bind(this), step: this.granularity, style: { zIndex: this.lastFocusedHandle === 'min' ? '2' : '1' }, type: 'range', value: this.startValue }), h(\"input\", { key: '1ec4b397eb5ca6834719b0c09811d2b11e70c6d0', class: classNames('searchcraft-slider-input', 'searchcraft-slider-input-max-handle'), max: this.max, min: this.min, onInput: this.handleEndValueChange.bind(this), step: this.granularity, style: { zIndex: this.lastFocusedHandle === 'max' ? '2' : '1' }, type: 'range', value: this.endValue })), h(\"div\", { key: 'abc788f7398c68aefcd12468280ef07fcf2ae673', class: 'searchcraft-slider-label-container' }, h(\"span\", { key: 'f09f772f95c21fc4dfcd58d6eed7ff6901d329b8', class: 'searchcraft-slider-label' }, startLabel), h(\"span\", { key: '251cecce58bb785d9478e80edfe429a1e18ef274', class: 'searchcraft-slider-label' }, endLabel))));\n }\n static get style() { return SearchcraftSliderStyle0; }\n}, [0, \"searchcraft-slider\", {\n \"max\": [2],\n \"min\": [2],\n \"granularity\": [2],\n \"dataType\": [1, \"data-type\"],\n \"endValue\": [32],\n \"startValue\": [32],\n \"lastFocusedHandle\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-slider\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-slider\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftSlider);\n }\n break;\n } });\n}\n\nexport { SearchcraftSlider as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-cc9f8c61.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftToggleButtonModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-toggle-button-container{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}.searchcraft-toggle-button-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-toggle-button-background{transition:background-color 0.2s;background:var(--sc-surface-disabled);border:none;border-radius:16px;cursor:pointer;height:26px;position:relative;width:44px;flex-shrink:0}.searchcraft-toggle-button-background.active{background:var(--sc-surface-brand-primary);box-shadow:0px 0px 0px 1px rgba(0, 0, 0, 0.05)}.searchcraft-toggle-button-handle{background:var(--sc-surface-neutral-light);border-radius:50%;height:18px;left:4px;position:absolute;top:calc(50% - 9px);transition:transform 0.3s ease;width:18px}.searchcraft-toggle-button-handle.active{transform:translateX(16px)}\";\nconst SearchcraftToggleButtonStyle0 = searchcraftToggleButtonModuleCss;\n\nconst SearchcraftToggleButton = /*@__PURE__*/ proxyCustomElement(class SearchcraftToggleButton extends H {\n constructor() {\n super();\n this.__registerHost();\n this.toggleUpdated = createEvent(this, \"toggleUpdated\", 7);\n /**\n * The label.\n */\n this.label = 'Toggle';\n this.isActive = false;\n this.handleToggle = async () => {\n this.isActive = !this.isActive;\n this.toggleUpdated.emit(this.isActive);\n };\n }\n connectedCallback() {\n /** When the query changes, sets toggle button state back to inactive. */\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (state.query !== this.lastQuery && state.query.trim().length === 0) {\n this.isActive = false;\n }\n this.lastQuery = state.query;\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n render() {\n return (h(\"div\", { key: '607bbc1adc109ec918effb25c6b91052227a2f7b', class: 'searchcraft-toggle-button-container' }, h(\"div\", { key: 'b452e1690c617020866f6bf3e591f62cc3fce111' }, h(\"p\", { key: '1bd8fa345516e412ea57bdbeac37dc8e26f2feaa', class: 'searchcraft-toggle-button-label' }, this.label), this.subLabel && (h(\"p\", { key: 'fce324a14721bab5f6173838f677ecb290200c8f', class: 'searchcraft-toggle-button-sub-label' }, this.subLabel))), h(\"button\", { key: '7b293a3ef64da88f463e5e6e303dabcbc63589bd', class: classNames('searchcraft-toggle-button-background', {\n active: this.isActive,\n }), onClick: this.handleToggle, type: 'button' }, h(\"div\", { key: '6afd68afeea5bb15ce1bde486ac59f7a958f6752', class: classNames('searchcraft-toggle-button-handle', {\n active: this.isActive,\n }) }))));\n }\n static get style() { return SearchcraftToggleButtonStyle0; }\n}, [0, \"searchcraft-toggle-button\", {\n \"label\": [1],\n \"subLabel\": [1, \"sub-label\"],\n \"isActive\": [32],\n \"unsubscribe\": [32],\n \"lastQuery\": [32]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-toggle-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-toggle-button\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftToggleButton);\n }\n break;\n } });\n}\n\nexport { SearchcraftToggleButton as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-662cb490.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\nimport { a as getMillis } from './p-755f491b.js';\nimport { d as defineCustomElement$4 } from './p-649654b5.js';\nimport { d as defineCustomElement$3 } from './p-cc9f8c61.js';\nimport { d as defineCustomElement$2 } from './p-662cb490.js';\n\nconst searchcraftFilterPanelModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-filter-panel{display:flex;flex-direction:column;gap:16px}.searchcraft-filter-panel-section{display:flex;flex-direction:column;gap:8px}.searchcraft-filter-panel-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-bold-font-size);font-weight:var(--sc-body-small-bold-font-weight);line-height:var(--sc-body-small-bold-line-height)}\";\nconst SearchcraftFilterPanelStyle0 = searchcraftFilterPanelModuleCss;\n\nconst SearchcraftFilterPanel$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftFilterPanel extends H {\n constructor() {\n super();\n this.__registerHost();\n /**\n * The items to filter.\n */\n this.items = [];\n this.searchStore = useSearchcraftStore.getState();\n }\n componentDidLoad() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n this.lastQuery = state.query || '';\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n }\n handleDateRangeChanged(fieldName, min, max) {\n const start = new Date(min);\n const end = new Date(max);\n this.searchStore.addRangeValueForIndexField({\n fieldName,\n value: `${fieldName}:[${start.toISOString()} TO ${end.toISOString()}]`,\n });\n this.searchStore.search();\n }\n handleNumericRangeChanged(fieldName, min, max) {\n this.searchStore.addRangeValueForIndexField({\n fieldName,\n value: `${fieldName}:[${min} TO ${max}]`,\n });\n this.searchStore.search();\n }\n handleFacetSelectionUpdated(fieldName, paths) {\n if (paths.length > 0) {\n this.searchStore.addFacetPathsForIndexField({\n fieldName,\n value: `${fieldName}: IN [${paths.join(' ')}]`,\n });\n }\n else {\n this.searchStore.removeFacetPathsForIndexField(fieldName);\n }\n this.searchStore.search();\n }\n handleExactMatchToggleUpdated(isActive) {\n this.searchStore.setSearchMode(isActive ? 'exact' : 'fuzzy');\n this.searchStore.search();\n }\n handleMostRecentToggleUpdated(isActive) {\n this.searchStore.setSortType(isActive ? 'desc' : 'asc');\n this.searchStore.search();\n }\n /**\n * Iterate through `items` and render them based on `type`\n */\n render() {\n return (h(\"div\", { key: '43bb83b1616c00f46727c7baff2cbc013f88e111', class: 'searchcraft-filter-panel' }, this.items.map((filterItem) => {\n switch (filterItem.type) {\n case 'dateRange': {\n const item = filterItem;\n const min = new Date(item.options.minDate).getTime();\n const max = new Date(item.options.maxDate).getTime();\n const granularityValue = getMillis(item.options.granularity);\n // return date range slider\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-slider\", { min: min, max: max, granularity: granularityValue, dataType: 'date', onRangeChanged: (event) => {\n this.handleDateRangeChanged(item.fieldName, event.detail.startValue, event.detail.endValue);\n } })));\n }\n case 'numericRange': {\n const item = filterItem;\n // return date range slider\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-slider\", { min: item.options.min, max: item.options.max, granularity: item.options.granularity, onRangeChanged: (event) => {\n this.handleNumericRangeChanged(item.fieldName, event.detail.startValue, event.detail.endValue);\n } })));\n }\n case 'facets': {\n const item = filterItem;\n // return \"filters-list\"\n return (h(\"div\", { class: 'searchcraft-filter-panel-section' }, h(\"p\", { class: 'searchcraft-filter-panel-label' }, filterItem.label), h(\"searchcraft-facet-list\", { fieldName: item.fieldName, onFacetSelectionUpdated: (event) => {\n this.handleFacetSelectionUpdated(item.fieldName, event.detail.paths);\n } })));\n }\n case 'exactMatchToggle': {\n const item = filterItem;\n return (h(\"searchcraft-toggle-button\", { label: item.label, subLabel: item.options.subLabel, onToggleUpdated: (event) => {\n this.handleExactMatchToggleUpdated(event.detail);\n } }));\n }\n case 'mostRecentToggle': {\n const item = filterItem;\n return (h(\"searchcraft-toggle-button\", { label: item.label, subLabel: item.options.subLabel, onToggleUpdated: (event) => {\n this.handleMostRecentToggleUpdated(event.detail);\n } }));\n }\n }\n })));\n }\n static get style() { return SearchcraftFilterPanelStyle0; }\n}, [0, \"searchcraft-filter-panel\", {\n \"items\": [16],\n \"unsubscribe\": [32],\n \"lastQuery\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-filter-panel\", \"searchcraft-facet-list\", \"searchcraft-slider\", \"searchcraft-toggle-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-filter-panel\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftFilterPanel$1);\n }\n break;\n case \"searchcraft-facet-list\":\n if (!customElements.get(tagName)) {\n defineCustomElement$4();\n }\n break;\n case \"searchcraft-slider\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-toggle-button\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftFilterPanel = SearchcraftFilterPanel$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftFilterPanel, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-filter-panel.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { c as classNames } from './p-5cdc6210.js';\n\nconst searchcraftInputLabelModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-input-label{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-bold-font-size);font-weight:var(--sc-body-small-bold-font-weight);line-height:var(--sc-body-small-bold-line-height);color:var(--sc-content-neutral-primary);margin-top:4px;margin-bottom:4px}\";\nconst SearchcraftInputLabelStyle0 = searchcraftInputLabelModuleCss;\n\nconst SearchcraftInputLabel = /*@__PURE__*/ proxyCustomElement(class SearchcraftInputLabel extends H {\n constructor() {\n super();\n this.__registerHost();\n /**\n * The classname applied to the label element.\n */\n this.inputLabelClassName = '';\n }\n render() {\n return (h(\"label\", { key: '4f913c1d9027ff781725a01e71e241cb5767eadb', class: classNames('searchcraft-input-label', this.inputLabelClassName), htmlFor: 'searchcraft-input-id' }, this.label));\n }\n static get style() { return SearchcraftInputLabelStyle0; }\n}, [0, \"searchcraft-input-label\", {\n \"inputLabelClassName\": [1, \"input-label-class-name\"],\n \"label\": [1]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-input-label\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-input-label\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftInputLabel);\n }\n break;\n } });\n}\n\nexport { SearchcraftInputLabel as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-c273e43d.js.map","import { p as proxyCustomElement, H, c as createEvent, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore, b as ae } from './p-01dc5b3b.js';\nimport { p as parseCustomStyles } from './p-d9551738.js';\nimport { c as classNames } from './p-5cdc6210.js';\nimport { d as defineCustomElement$3 } from './p-cf096782.js';\nimport { d as defineCustomElement$2 } from './p-f5a06210.js';\nimport { d as defineCustomElement$1 } from './p-c273e43d.js';\n\nconst name = \"@searchcraft/javascript-sdk\";\nconst version = \"0.7.0\";\nconst description = \"Searchcraft Javascript SDK\";\nconst author = \"Searchcraft\";\nconst license = \"Apache-2.0\";\nconst main = \"dist/index.cjs.js\";\nconst module = \"dist/index.js\";\nconst types = \"dist/types/index.d.ts\";\nconst collection = \"dist/collection/collection-manifest.json\";\nconst unpkg = \"dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js\";\nconst exports = {\n\t\".\": {\n\t\t\"import\": \"./dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.esm.js\",\n\t\trequire: \"./dist/searchcraft-javascript-sdk/searchcraft-javascript-sdk.cjs.js\",\n\t\ttypes: \"./dist/types/index.d.ts\"\n\t},\n\t\"./components\": {\n\t\t\"import\": \"./dist/components/index.js\",\n\t\ttypes: \"./dist/components/index.d.ts\"\n\t},\n\t\"./loader\": {\n\t\t\"import\": \"./dist/loader/index.js\",\n\t\trequire: \"./dist/loader/index.cjs\",\n\t\ttypes: \"./dist/loader/index.d.ts\"\n\t},\n\t\"./dist/components/*\": {\n\t\t\"import\": \"./dist/components/*\",\n\t\ttypes: \"./dist/components/*\"\n\t}\n};\nconst repository = {\n\ttype: \"git\",\n\turl: \"https://bitbucket.org/madebychalk/searchcraft-javascript-sdks/\"\n};\nconst files = [\n\t\"dist/\"\n];\nconst scripts = {\n\tbuild: \"stencil build\",\n\tdev: \"stencil build --dev --watch\",\n\ttest: \"stencil test --spec --e2e\",\n\t\"test.watch\": \"stencil test --spec --e2e --watchAll\",\n\tgenerate: \"stencil generate\"\n};\nconst dependencies = {\n\t\"@stencil/vue-output-target\": \"^0.9.2\",\n\tclassnames: \"^2.3.2\"\n};\nconst devDependencies = {\n\t\"@searchcraft/core\": \"^0.7.0\",\n\t\"@searchcraft/javascript-sdk\": \"*\",\n\t\"@stencil/core\": \"^4.7.0\",\n\t\"@stencil/react-output-target\": \"^0.8.2\",\n\t\"@stencil/sass\": \"^3.0.12\",\n\t\"@types/node\": \"^16.18.11\",\n\tzustand: \"^5.0.1\"\n};\nconst packageJson = {\n\tname: name,\n\t\"private\": false,\n\tversion: version,\n\tdescription: description,\n\tauthor: author,\n\tlicense: license,\n\tmain: main,\n\tmodule: module,\n\ttypes: types,\n\tcollection: collection,\n\t\"collection:main\": \"dist/collection/index.js\",\n\tunpkg: unpkg,\n\texports: exports,\n\trepository: repository,\n\tfiles: files,\n\tscripts: scripts,\n\tdependencies: dependencies,\n\tdevDependencies: devDependencies\n};\n\nconst searchcraftInputFormModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-input-grid{display:grid;gap:4px 8px}.searchcraft-input-grid-buttonLeft{grid-template-rows:repeat(3, auto);grid-template-columns:auto 1fr}.searchcraft-input-grid-buttonLeft .searchcraft-input-button-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-label-wrapper{grid-column:2/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-error-wrapper{grid-column:2/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonLeft .searchcraft-input-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonRight{grid-template-rows:repeat(3, auto);grid-template-columns:1fr auto}.searchcraft-input-grid-buttonRight .searchcraft-input-button-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-label-wrapper{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-error-wrapper{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonRight .searchcraft-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-grid-buttonNone{grid-template-rows:repeat(3, auto);grid-template-columns:auto}.searchcraft-input-grid-buttonNone .searchcraft-input-button-wrapper{display:none}.searchcraft-input-grid-buttonNone .searchcraft-input-label-wrapper{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-grid-buttonNone .searchcraft-input-error-wrapper{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-grid-buttonNone .searchcraft-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-wrapper{position:relative;display:flex}.searchcraft-input{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);background-color:var(--sc-surface-neutral-secondary);border-radius:var(--sc-input-border-radius);border:none;color:var(--sc-content-neutral-primary);outline:none;padding-left:var(--sc-input-padding-left);padding-right:var(--sc-input-padding-right);padding-top:12px;padding-bottom:12px;flex:1}.searchcraft-input::placeholder{color:var(--sc-content-disabled)}.searchcraft-input:focus{outline:var(--sc-border-brand) solid 2px}.searchcraft-input:focus::placeholder{opacity:0}.searchcraft-input.error{color:var(--sc-content-danger);outline:var(--sc-border-danger) solid 2px}.searchcraft-input.error:focus{outline:var(--sc-border-danger) solid 2px}.searchcraft-input-search-icon-wrapper{align-items:center;justify-content:center;display:flex;position:absolute;pointer-events:none;bottom:0;left:0;top:0;width:var(--sc-input-padding-left)}.searchcraft-input-search-icon{pointer-events:none;width:var(--sc-input-search-icon-size);height:var(--sc-input-search-icon-size)}.searchcraft-input-clear-button{all:unset;align-items:center;justify-content:center;cursor:pointer;display:flex;position:absolute;border:none;outline:none;bottom:0;right:0;top:0;width:var(--sc-input-padding-right)}.searchcraft-input-clear-icon{width:var(--sc-input-clear-icon-size);height:var(--sc-input-clear-icon-size)}\";\nconst SearchcraftInputFormStyle0 = searchcraftInputFormModuleCss;\n\nconst SearchcraftInput = /*@__PURE__*/ proxyCustomElement(class SearchcraftInput extends H {\n constructor() {\n super();\n this.__registerHost();\n this.inputCleared = createEvent(this, \"inputCleared\", 7);\n this.noResultsReceived = createEvent(this, \"noResultsReceived\", 7);\n this.inputFocus = createEvent(this, \"inputFocus\", 7);\n this.inputBlur = createEvent(this, \"inputBlur\", 7);\n this.inputInit = createEvent(this, \"inputInit\", 7);\n this.querySubmit = createEvent(this, \"querySubmit\", 7);\n /**\n * Whether or not to automatically submit the search term when the input changes.\n */\n this.autoSearch = true;\n /**\n * Where to place the search button.\n */\n this.buttonPlacement = 'none';\n /**\n * A custom styles object to be applied to the input element.\n */\n this.customStyles = {};\n /**\n * The input element's placeholder value.\n */\n this.placeholderValue = 'Enter Search';\n /**\n * The starting value of the input element.\n */\n this.searchTerm = '';\n this.inputValue = this.searchTerm;\n this.error = false;\n this.isSearchcraftInitialized = false;\n this.searchStore = useSearchcraftStore.getState();\n this.handleOnInput = (event) => {\n const input = event.target;\n this.inputValue = input.value;\n if (input.value.trim() === '') {\n this.inputCleared.emit();\n this.searchTerm = '';\n this.searchStore.setQuery('');\n this.searchStore.setSearchResults(null);\n return;\n }\n if (!this.autoSearch) {\n return;\n }\n this.performSearch(input.value);\n };\n this.performSearch = async (value) => {\n if (value === useSearchcraftStore.getState().query) {\n return;\n }\n this.searchTerm = value.trim();\n this.error = false;\n this.searchStore.setQuery(this.searchTerm);\n this.querySubmit.emit(this.searchTerm);\n try {\n await this.searchStore.search();\n }\n catch (error) {\n this.error = true;\n this.inputCleared.emit();\n }\n };\n this.handleClearInput = () => {\n this.inputValue = '';\n this.searchTerm = '';\n this.searchStore.setQuery('');\n this.searchStore.setSearchResults(null);\n this.error = false;\n if (this.inputCleared) {\n this.inputCleared.emit();\n }\n };\n this.handleFormSubmit = async (event) => {\n event.preventDefault();\n await this.performSearch(this.searchTerm);\n };\n }\n init() {\n if (this.config && !this.isSearchcraftInitialized) {\n const searchcraft = new ae(this.config, {\n sdkName: packageJson.name,\n sdkVersion: packageJson.version,\n });\n this.searchStore.initialize(searchcraft, true);\n this.isSearchcraftInitialized = true;\n this.inputInit.emit();\n }\n }\n componentDidLoad() {\n this.init();\n }\n onConfigChange() {\n this.init();\n }\n render() {\n const validatedCustomStyles = parseCustomStyles(this.customStyles);\n const isShowingClearButton = this.inputValue.length > 0;\n const inputGridClassNames = classNames('searchcraft-input-grid', {\n 'searchcraft-input-grid-buttonLeft': this.buttonPlacement === 'left',\n 'searchcraft-input-grid-buttonRight': this.buttonPlacement === 'right',\n 'searchcraft-input-grid-buttonNone': this.buttonPlacement === 'none',\n });\n const shouldHaveVerticalGap = this.inputLabel || this.error;\n const inputGridStyles = {\n gap: shouldHaveVerticalGap ? '4px 8px' : '0px 8px',\n };\n return (h(\"form\", { key: 'd257962d56a583e66bdf8b55786d5dfbae231965', class: 'searchcraft-input-form', onSubmit: this.handleFormSubmit }, h(\"div\", { key: 'd9a8467a4d76433bc473941bd4583d991ae38040', class: inputGridClassNames, style: inputGridStyles }, h(\"div\", { key: 'a94eacc99593ed6a30006532c51cdd38c692c93f', class: 'searchcraft-input-button-wrapper' }, h(\"searchcraft-button\", { key: '43de9d2cd538bbdf2a2bbc9f5165bfb969943831', onButtonClick: this.handleFormSubmit, label: this.buttonLabel })), this.inputLabel && (h(\"div\", { key: 'b3554f81577d4526023d8b67de6837386789e9f3', class: 'searchcraft-input-label-wrapper' }, h(\"searchcraft-input-label\", { key: '5cda67f38d0914dfe7e1ea71bee60b69524e9d5c', label: this.inputLabel }))), this.error && (h(\"div\", { key: '22b82da9420159ebaf00fe3bb790d6b07341a79e', class: 'searchcraft-input-error-wrapper' }, h(\"searchcraft-error-message\", { key: '2cc5c322408b976a7043ef9640c812036468435d', errorMessage: 'Something went wrong.' }))), h(\"div\", { key: 'f2741bd0d20604327fa4661c3213e48df7a58249', class: 'searchcraft-input-wrapper' }, h(\"input\", { key: '692822c6a38001ba4c71289b6b7fba13767742b5', autoComplete: 'off', class: 'searchcraft-input', onFocus: () => this.inputFocus.emit(), onBlur: () => this.inputBlur.emit(), onInput: (event) => {\n this.handleOnInput(event);\n }, placeholder: this.placeholderValue, style: validatedCustomStyles, type: 'text', value: this.inputValue }), h(\"div\", { key: '58af613c048e7c072e4a976f71ea1bd7b3632a62', class: 'searchcraft-input-search-icon-wrapper' }, h(\"svg\", { key: 'e6cf67405b45703ca7ddaf46a59adbf5ff926f0e', class: 'searchcraft-input-search-icon', viewBox: '0 0 20 20', fill: 'none', xmlns: 'http://www.w3.org/2000/svg', \"aria-labelledby\": 'searchcraft-title' }, h(\"title\", { key: 'fa510c85900d9a716076ba79866f5bbe4f1a20ed', id: 'searchcraft-title' }, \"Searchcraft Search Icon Light\"), h(\"path\", { key: 'ac9d166c19e6644adcbc00fe665e17fcf5449b73', 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' }))), isShowingClearButton && (h(\"button\", { key: '992cf037b6b75200c64c21809915b5ce6f970f5c', type: 'button', class: 'searchcraft-input-clear-button', onClick: this.handleClearInput }, h(\"svg\", { key: 'f09a5f2c1007cc11d89b2df06ec189d923bc634f', class: 'searchcraft-input-clear-icon', viewBox: '0 0 22 22', fill: 'none', xmlns: 'http://www.w3.org/2000/svg', \"aria-labelledby\": 'icon-title' }, h(\"title\", { key: '92bd5162ae636aaf6c8051959ff16cd26ee98660', id: 'icon-title' }, \"Searchcraft Clear Input Icon Light\"), h(\"path\", { key: '9b5a8a4113a3162035d48895f0facf6f6045f266', 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' }))))))));\n }\n static get watchers() { return {\n \"config\": [\"onConfigChange\"]\n }; }\n static get style() { return SearchcraftInputFormStyle0; }\n}, [0, \"searchcraft-input-form\", {\n \"config\": [16],\n \"autoSearch\": [4, \"auto-search\"],\n \"buttonPlacement\": [1, \"button-placement\"],\n \"buttonLabel\": [1, \"button-label\"],\n \"inputLabel\": [1, \"input-label\"],\n \"customStyles\": [1, \"custom-styles\"],\n \"placeholderValue\": [1, \"placeholder-value\"],\n \"searchTerm\": [1, \"search-term\"],\n \"inputValue\": [32],\n \"error\": [32],\n \"isSearchcraftInitialized\": [32]\n }, undefined, {\n \"config\": [\"onConfigChange\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-input-form\", \"searchcraft-button\", \"searchcraft-error-message\", \"searchcraft-input-label\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-input-form\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftInput);\n }\n break;\n case \"searchcraft-button\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n case \"searchcraft-input-label\":\n if (!customElements.get(tagName)) {\n defineCustomElement$1();\n }\n break;\n } });\n}\n\nexport { SearchcraftInput as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-da5b92ef.js.map","import { S as SearchcraftInput, d as defineCustomElement$1 } from './p-da5b92ef.js';\n\nconst SearchcraftInputForm = SearchcraftInput;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftInputForm, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-input-form.js.map","import { S as SearchcraftInputLabel$1, d as defineCustomElement$1 } from './p-c273e43d.js';\n\nconst SearchcraftInputLabel = SearchcraftInputLabel$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftInputLabel, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-input-label.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\n\nconst searchcraftPopoverButtonModuleCss = \"\";\nconst SearchcraftPopoverButtonStyle0 = searchcraftPopoverButtonModuleCss;\n\nconst SearchcraftPopoverButton$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftPopoverButton extends H {\n constructor() {\n super();\n this.__registerHost();\n }\n handleOnClick() {\n useSearchcraftStore.getState().setPopoverVisibility(true);\n }\n render() {\n return (h(\"button\", { key: '7885ca44b5ce619d572194d60c3b7e9d9f6666be', type: 'button', onClick: this.handleOnClick.bind(this) }, h(\"slot\", { key: '0a8dc506eadbc725e3ed4c7c6987e02dfcecc229' })));\n }\n static get style() { return SearchcraftPopoverButtonStyle0; }\n}, [4, \"searchcraft-popover-button\"]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-popover-button\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-popover-button\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftPopoverButton$1);\n }\n break;\n } });\n}\n\nconst SearchcraftPopoverButton = SearchcraftPopoverButton$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftPopoverButton, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-popover-button.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\n\nconst searchcraftPopoverListItemModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-popover-list-item{all:unset;display:flex;flex-direction:row;cursor:pointer;gap:8px;padding-right:var(--sc-popover-list-item-padding-horizontal);padding-left:var(--sc-popover-list-item-padding-horizontal);padding-top:var(--sc-popover-list-item-padding-vertical);padding-bottom:var(--sc-popover-list-item-padding-vertical)}.searchcraft-popover-list-item:focus{background-color:var(--sc-surface-neutral-secondary-active);color:var(--sc-content-neutral-secondary)}.searchcraft-popover-list-item:hover{background-color:var(--sc-surface-neutral-secondary-hover);color:var(--sc-content-neutral-secondary)}.searchcraft-popover-list-item-title{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);margin:0;color:inherit}.searchcraft-popover-list-item-subtitle{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-body-small-font-weight);line-height:var(--sc-body-small-line-height);margin:0;color:inherit}.searchcraft-popover-list-item-image-wrapper{width:var(--sc-popover-list-item-image-size);height:var(--sc-popover-list-item-image-size);display:flex;align-items:center;justify-content:center;flex-shrink:0}.searchcraft-popover-list-item-image{max-width:var(--sc-popover-list-item-image-size);max-height:var(--sc-popover-list-item-image-size)}.searchcraft-popover-list-item-info-wrapper{display:flex;flex-direction:column;gap:8px;justify-content:center}\";\nconst SearchcraftPopoverListItemStyle0 = searchcraftPopoverListItemModuleCss;\n\nconst SearchcraftPopoverListItem = /*@__PURE__*/ proxyCustomElement(class SearchcraftPopoverListItem extends H {\n constructor() {\n super();\n this.__registerHost();\n }\n componentDidLoad() { }\n connectedCallback() { }\n disconnectedCallback() { }\n handleButtonClick() { }\n render() {\n return (h(\"a\", { key: 'b7a590e92994869477825dd17545e8d4e05d1d07', class: 'searchcraft-popover-list-item', href: this.href }, this.imageSrc && (h(\"div\", { key: '129525e50ec17dce052f503af318b56e06c900ef', class: 'searchcraft-popover-list-item-image-wrapper' }, h(\"img\", { key: '4ba701f35cbf7e167e7edd63ba19e3576e620c26', alt: this.imageAlt, src: this.imageSrc, class: 'searchcraft-popover-list-item-image' }))), h(\"div\", { key: '6a6ab09451f5d9d4e554dc1f1fcd57ec13adf2f2', class: 'searchcraft-popover-list-item-info-wrapper' }, h(\"p\", { key: '476fdefff6cb35167fb00f24cdf03b9f8d826ba5', class: 'searchcraft-popover-list-item-title' }, this.titleContent), h(\"p\", { key: 'b43fd584bfcc8efc7d50d7220b649fafc8bba244', class: 'searchcraft-popover-list-item-subtitle' }, this.subtitleContent))));\n }\n static get style() { return SearchcraftPopoverListItemStyle0; }\n}, [0, \"searchcraft-popover-list-item\", {\n \"titleContent\": [1, \"title-content\"],\n \"subtitleContent\": [1, \"subtitle-content\"],\n \"imageSrc\": [1, \"image-src\"],\n \"imageAlt\": [1, \"image-alt\"],\n \"href\": [1],\n \"documentPosition\": [2, \"document-position\"]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-popover-list-item\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-popover-list-item\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftPopoverListItem);\n }\n break;\n } });\n}\n\nexport { SearchcraftPopoverListItem as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-1ae87308.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { g as getDocumentValueFromSearchResultMapping } from './p-755f491b.js';\nimport { d as defineCustomElement$1 } from './p-1ae87308.js';\n\nconst searchcraftPopoverListViewModuleCss = \"\";\nconst SearchcraftPopoverListViewStyle0 = searchcraftPopoverListViewModuleCss;\n\nconst SearchcraftPopoverListView = /*@__PURE__*/ proxyCustomElement(class SearchcraftPopoverListView extends H {\n constructor() {\n super();\n this.__registerHost();\n }\n renderDocument(document, index) {\n /**\n * Index field values -> Result container props mappings.\n */\n const titleContent = getDocumentValueFromSearchResultMapping(document, this.popoverResultMappings.title);\n const subtitleContent = getDocumentValueFromSearchResultMapping(document, this.popoverResultMappings.subtitle);\n const href = getDocumentValueFromSearchResultMapping(document, this.popoverResultMappings.href);\n const imageSource = getDocumentValueFromSearchResultMapping(document, this.popoverResultMappings.imageSource);\n const imageAlt = getDocumentValueFromSearchResultMapping(document, this.popoverResultMappings.imageAlt);\n return (h(\"searchcraft-popover-list-item\", { key: `${document.document_id}-${index}`, \"title-content\": titleContent, \"subtitle-content\": subtitleContent, \"image-src\": imageSource, \"image-alt\": imageAlt, href: href, \"document-position\": index }));\n }\n render() {\n var _a;\n return (h(\"div\", { key: '6e9017370d7079412d6d31fb439be599d689c9c2', class: 'searchcraft-popover-list-view' }, (_a = this.documents) === null || _a === void 0 ? void 0 : _a.map((document, index) => this.renderDocument(document, index))));\n }\n static get style() { return SearchcraftPopoverListViewStyle0; }\n}, [0, \"searchcraft-popover-list-view\", {\n \"popoverResultMappings\": [16],\n \"documents\": [16]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-popover-list-view\", \"searchcraft-popover-list-item\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-popover-list-view\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftPopoverListView);\n }\n break;\n case \"searchcraft-popover-list-item\":\n if (!customElements.get(tagName)) {\n defineCustomElement$1();\n }\n break;\n } });\n}\n\nexport { SearchcraftPopoverListView as S, defineCustomElement as d };\n\n//# sourceMappingURL=p-e1cf5f9d.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { c as classNames } from './p-5cdc6210.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\nimport { d as defineCustomElement$7 } from './p-cf096782.js';\nimport { d as defineCustomElement$6 } from './p-f5a06210.js';\nimport { d as defineCustomElement$5 } from './p-da5b92ef.js';\nimport { d as defineCustomElement$4 } from './p-c273e43d.js';\nimport { d as defineCustomElement$3 } from './p-1ae87308.js';\nimport { d as defineCustomElement$2 } from './p-e1cf5f9d.js';\n\nconst searchcraftPopoverFormModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-popover-form{display:flex;flex-direction:column;flex:1}.searchcraft-popover-form .searchcraft-popover-form-input-wrapper{padding:12px;background-color:var(--sc-surface-neutral-secondary);display:flex;flex-direction:row;gap:4px}.searchcraft-popover-form .searchcraft-popover-form-input-wrapper>searchcraft-input-form{flex:1}.searchcraft-popover-form .searchcraft-popover-form-cancel-button{font-family:var(--sc-font-family);-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-body-font-weight);line-height:var(--sc-body-line-height);border:0;outline:0;padding:0;flex-shrink:0;background:none;cursor:pointer;padding-left:12px;padding-right:12px;border-radius:calc(var(--sc-popover-form-border-radius) * 0.8)}.searchcraft-popover-form .searchcraft-popover-form-cancel-button:hover{background-color:var(--sc-surface-brand-secondary-hover)}.searchcraft-popover-form .searchcraft-popover-form-cancel-button:focus{background-color:var(--sc-surface-brand-secondary-active)}.searchcraft-popover-form-inline .searchcraft-input{border-top-left-radius:var(--sc-popover-form-border-radius);border-top-right-radius:var(--sc-popover-form-border-radius);border-bottom-left-radius:var(--sc-popover-form-border-radius);border-bottom-right-radius:var(--sc-popover-form-border-radius);border:none;outline:none}.searchcraft-popover-form-inline.searchcraft-popover-form-active .searchcraft-input{border-top-left-radius:var(--sc-popover-form-border-radius);border-top-right-radius:var(--sc-popover-form-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.searchcraft-popover-form-inline .searchcraft-popover-inline-wrapper-outer{position:relative}.searchcraft-popover-form-inline .searchcraft-popover-inline-wrapper-inner{position:absolute;height:var(--sc-popover-list-view-height);z-index:1000;width:100%}.searchcraft-popover-form-inline .searchcraft-popover-list-view{display:flex;flex-direction:column;overflow:auto;background-color:var(--sc-surface-neutral-secondary);border-bottom-left-radius:var(--sc-popover-form-border-radius);border-bottom-right-radius:var(--sc-popover-form-border-radius);max-height:var(--sc-popover-list-view-height)}.searchcraft-popover-form-modal{position:fixed;inset:0;z-index:1000;display:flex;align-items:flex-start;justify-content:center;padding:0;background-color:var(--sc-surface-neutral-secondary)}@media (min-width: 576px){.searchcraft-popover-form-modal{padding:16px;background-color:transparent}}.searchcraft-popover-form-modal .searchcraft-input{border-radius:calc(var(--sc-popover-form-border-radius) * 0.8);outline-width:1px;outline-color:var(--sc-border-neutral)}.searchcraft-popover-form-modal .searchcraft-popover-form-modal-backdrop{position:absolute;inset:0;background-color:rgba(0, 0, 0, 0.5);display:none}@media (min-width: 576px){.searchcraft-popover-form-modal .searchcraft-popover-form-modal-backdrop{display:block}}.searchcraft-popover-form-modal .searchcraft-popover-form-modal-inner{position:absolute;inset:0;z-index:1002;margin-top:0px;display:flex;border-radius:var(--sc-popover-form-border-radius);overflow:hidden}@media (min-width: 576px){.searchcraft-popover-form-modal .searchcraft-popover-form-modal-inner{inset:auto;position:relative;width:100%;margin-top:100px;max-width:var(--sc-popover-modal-max-width)}}.searchcraft-popover-form-modal .searchcraft-popover-list-view{display:flex;flex-direction:column;overflow:auto;background-color:var(--sc-surface-neutral-secondary);border-bottom-left-radius:0;border-bottom-right-radius:0}@media (min-width: 576px){.searchcraft-popover-form-modal .searchcraft-popover-list-view{max-height:var(--sc-popover-list-view-height)}}.searchcraft-popover-form-modal searchcraft-popover-list-view{overflow:scroll}@media (min-width: 576px){.searchcraft-popover-form-modal searchcraft-popover-list-view{overflow:auto}}.searchcraft-popover-form-fullscreen{position:fixed;inset:0;z-index:1000;background-color:var(--sc-surface-neutral-secondary)}.searchcraft-popover-form-fullscreen .searchcraft-popover-form{position:absolute;inset:0}.searchcraft-popover-form-fullscreen .searchcraft-input{border-radius:calc(var(--sc-popover-form-border-radius) * 0.8);outline-width:1px;outline-color:var(--sc-border-neutral)}.searchcraft-popover-form-fullscreen searchcraft-popover-list-view{overflow:scroll}\";\nconst SearchcraftPopoverFormStyle0 = searchcraftPopoverFormModuleCss;\n\nconst SearchcraftPopoverForm$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftPopoverForm extends H {\n constructor() {\n super();\n this.__registerHost();\n /**\n * The type of popover form to render.\n *\n * - `inline` - Renders inline with the rest of the content on the page. The search results pop over the page content.\n * - `fullscreen` - Renders in fullscreen view. Used together with the `searchcraft-popover-button` component.\n * - `modal` - Renders in a modal view. Used together with the `searchcraft-popover-button` component.\n */\n this.type = 'inline';\n /**\n * The hotkey that activates the popover.\n */\n this.hotkey = 'k';\n /**\n * The hotkey modifier that activates the popover. Used together with the `hotkey` prop.\n */\n this.hotkeyModifier = 'meta';\n this.isPopoverVisibleInState = false;\n this.isFocused = false;\n this.breakpointSm = 576;\n this.breakpointMd = 768;\n this.breakpointLg = 992;\n this.handleDocumentClick = (event) => {\n if (!this.hostElement.contains(event.target)) {\n this.isFocused = false;\n }\n };\n /**\n * Actions to perform when various keys are pressed within the popover form.\n */\n this.handleDocumentKeyDown = (event) => {\n // Document-scoped actions\n if (event.key === this.hotkey) {\n this.handleHotkeyPressed(event);\n }\n // Document-scoped -> Popover-scoped keyboard event boundary\n if (!this.hostElement.contains(document.activeElement)) {\n return;\n }\n // Popover-scoped actions\n switch (event.key) {\n case 'ArrowDown':\n case 'ArrowUp':\n event.preventDefault();\n this.focusOnNextListItem(event.key);\n break;\n case 'Escape':\n useSearchcraftStore.getState().setPopoverVisibility(false);\n break;\n default:\n return;\n }\n };\n this.handleInputInit = () => {\n const input = this.hostElement.querySelector('.searchcraft-input');\n input === null || input === void 0 ? void 0 : input.focus();\n };\n }\n componentDidLoad() {\n // Loads the breakpoint values into state\n const computedStyle = getComputedStyle(document.documentElement);\n this.breakpointSm = Number.parseFloat(computedStyle.getPropertyValue('--sc-breakpoint-sm').trim());\n this.breakpointMd = Number.parseFloat(computedStyle.getPropertyValue('--sc-breakpoint-md').trim());\n this.breakpointLg = Number.parseFloat(computedStyle.getPropertyValue('--sc-breakpoint-lg').trim());\n // Set popover visiblity in state\n this.isPopoverVisibleInState =\n useSearchcraftStore.getState().isPopoverVisible;\n // Add event listeners\n document.addEventListener('click', this.handleDocumentClick);\n document.addEventListener('keydown', this.handleDocumentKeyDown);\n // Subscribe to state events\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n if (this.isPopoverVisibleInState !== state.isPopoverVisible) {\n this.handlePopoverVisibilityChange(state.isPopoverVisible);\n }\n this.searchResults = Object.assign({}, state.searchResults);\n this.searchTerm = state.query;\n });\n }\n disconnectedCallback() {\n var _a;\n (_a = this.unsubscribe) === null || _a === void 0 ? void 0 : _a.call(this);\n document.removeEventListener('click', this.handleDocumentClick);\n document.removeEventListener('keydown', this.handleDocumentKeyDown);\n }\n /**\n * Handles when popover visibility is changed in state\n */\n handlePopoverVisibilityChange(isVisible) {\n this.isPopoverVisibleInState = isVisible;\n document.body.style.overflow = isVisible ? 'hidden' : 'auto';\n }\n /**\n * When popover is `inline` and the viewport is at the smallest breakpoint,\n * focusing on the input will open a modal version of the popover form.\n */\n handleInputFocus() {\n this.isFocused = true;\n if (this.type === 'inline' &&\n window.visualViewport.width < this.breakpointSm) {\n useSearchcraftStore.getState().setPopoverVisibility(true);\n // Appends a popover form of type=`modal` to the body\n if (!this.modalElement) {\n this.modalElement = document.createElement('searchcraft-popover-form');\n this.modalElement.config = this.config;\n this.modalElement.popoverResultMappings = this.popoverResultMappings;\n this.modalElement.setAttribute('type', 'fullscreen');\n document.body.appendChild(this.modalElement);\n }\n }\n }\n handleModalBackdropClick(_event) {\n useSearchcraftStore.getState().setPopoverVisibility(false);\n }\n /**\n * When a hotkey is pressed, tests if the modifiers also match.\n * If modifiers match, toggles visibility of the popover modal.\n */\n handleHotkeyPressed(event) {\n if ((event.ctrlKey && this.hotkeyModifier === 'ctrl') ||\n (event.altKey && this.hotkeyModifier === 'alt') ||\n (event.metaKey && this.hotkeyModifier === 'meta')) {\n event.preventDefault();\n if (this.type === 'inline' && !this.isPopoverVisibleInState) {\n const hostElementInput = this.hostElement.querySelector('.searchcraft-input');\n hostElementInput === null || hostElementInput === void 0 ? void 0 : hostElementInput.focus();\n }\n else {\n useSearchcraftStore\n .getState()\n .setPopoverVisibility(!this.isPopoverVisibleInState);\n }\n }\n }\n handleCancelButtonClick() {\n useSearchcraftStore.getState().setPopoverVisibility(false);\n }\n /**\n * Moves focus to the next/previous list item in the list view. If you are at the top\n * of the list view, it moves focus back to the input.\n *\n * @param direction\n */\n focusOnNextListItem(direction) {\n var _a, _b;\n const listItems = Array.from(document.querySelectorAll('a.searchcraft-popover-list-item')).filter((el) => !el.hasAttribute('disabled') && el.offsetParent !== null);\n const currentIndex = listItems.indexOf(document.activeElement);\n if (direction === 'ArrowDown') {\n (_a = listItems[(currentIndex + 1) % listItems.length]) === null || _a === void 0 ? void 0 : _a.focus();\n }\n else if (direction === 'ArrowUp') {\n if (currentIndex >= 1) {\n (_b = listItems[currentIndex - 1]) === null || _b === void 0 ? void 0 : _b.focus();\n }\n else {\n const input = document.querySelector('.searchcraft-input');\n if (input) {\n input.focus();\n requestAnimationFrame(() => {\n input.selectionEnd = input.value.length;\n input.selectionStart = input.value.length;\n });\n }\n }\n }\n }\n get hasResultsToShow() {\n var _a, _b, _c, _d, _e;\n return (((_b = (_a = this.searchTerm) === null || _a === void 0 ? void 0 : _a.trim()) === null || _b === void 0 ? void 0 : _b.length) > 0 &&\n ((_e = (_d = (_c = this.searchResults) === null || _c === void 0 ? void 0 : _c.data) === null || _d === void 0 ? void 0 : _d.hits) === null || _e === void 0 ? void 0 : _e.length) > 0);\n }\n renderInlinePopover(documents) {\n const isListViewVisible = this.hasResultsToShow && this.isFocused;\n const popoverFormClassNames = classNames('searchcraft-popover-form searchcraft-popover-form-inline', {\n 'searchcraft-popover-form-active': isListViewVisible,\n });\n return (h(\"div\", { class: popoverFormClassNames }, h(\"searchcraft-input-form\", { config: this.config, onInputFocus: this.handleInputFocus.bind(this) }), isListViewVisible && (h(\"div\", { class: 'searchcraft-popover-inline-wrapper-outer' }, h(\"div\", { class: 'searchcraft-popover-inline-wrapper-inner' }, h(\"searchcraft-popover-list-view\", { popoverResultMappings: this.popoverResultMappings, documents: documents }))))));\n }\n renderModalPopover(documents) {\n if (this.isPopoverVisibleInState) {\n const popoverFormClassNames = classNames('searchcraft-popover-form', {\n 'searchcraft-popover-form-active': this.hasResultsToShow,\n });\n return (h(\"div\", { class: 'searchcraft-popover-form-modal' }, h(\"div\", { class: 'searchcraft-popover-form-modal-backdrop', onClick: this.handleModalBackdropClick }), h(\"div\", { class: 'searchcraft-popover-form-modal-inner' }, h(\"div\", { class: popoverFormClassNames }, h(\"div\", { class: 'searchcraft-popover-form-input-wrapper' }, h(\"searchcraft-input-form\", { config: this.config, onInputFocus: this.handleInputFocus.bind(this), onInputInit: this.handleInputInit.bind(this) }), h(\"button\", { type: 'button', class: 'searchcraft-popover-form-cancel-button', onClick: this.handleCancelButtonClick.bind(this) }, \"Cancel\")), this.hasResultsToShow && (h(\"searchcraft-popover-list-view\", { popoverResultMappings: this.popoverResultMappings, documents: documents }))))));\n }\n }\n renderFullscreenPopover(documents) {\n if (this.isPopoverVisibleInState) {\n return (h(\"div\", { class: 'searchcraft-popover-form-fullscreen' }, h(\"div\", { class: 'searchcraft-popover-form' }, h(\"div\", { class: 'searchcraft-popover-form-input-wrapper' }, h(\"searchcraft-input-form\", { config: this.config, onInputFocus: this.handleInputFocus.bind(this), onInputInit: this.handleInputInit.bind(this) }), h(\"button\", { type: 'button', class: 'searchcraft-popover-form-cancel-button', onClick: this.handleCancelButtonClick.bind(this) }, \"Cancel\")), this.hasResultsToShow && (h(\"searchcraft-popover-list-view\", { popoverResultMappings: this.popoverResultMappings, documents: documents })))));\n }\n }\n render() {\n var _a, _b, _c;\n const documents = (_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.map((data, _index) => {\n const { doc: result } = data;\n return result;\n });\n switch (this.type) {\n case 'inline':\n return this.renderInlinePopover(documents);\n case 'modal':\n return this.renderModalPopover(documents);\n case 'fullscreen':\n return this.renderFullscreenPopover(documents);\n }\n }\n get hostElement() { return this; }\n static get style() { return SearchcraftPopoverFormStyle0; }\n}, [0, \"searchcraft-popover-form\", {\n \"config\": [16],\n \"type\": [1],\n \"popoverResultMappings\": [16],\n \"hotkey\": [1],\n \"hotkeyModifier\": [1, \"hotkey-modifier\"],\n \"isPopoverVisibleInState\": [32],\n \"unsubscribe\": [32],\n \"searchResults\": [32],\n \"searchTerm\": [32],\n \"isFocused\": [32],\n \"breakpointSm\": [32],\n \"breakpointMd\": [32],\n \"breakpointLg\": [32],\n \"modalElement\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-popover-form\", \"searchcraft-button\", \"searchcraft-error-message\", \"searchcraft-input-form\", \"searchcraft-input-label\", \"searchcraft-popover-form\", \"searchcraft-popover-list-item\", \"searchcraft-popover-list-view\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-popover-form\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftPopoverForm$1);\n }\n break;\n case \"searchcraft-button\":\n if (!customElements.get(tagName)) {\n defineCustomElement$7();\n }\n break;\n case \"searchcraft-error-message\":\n if (!customElements.get(tagName)) {\n defineCustomElement$6();\n }\n break;\n case \"searchcraft-input-form\":\n if (!customElements.get(tagName)) {\n defineCustomElement$5();\n }\n break;\n case \"searchcraft-input-label\":\n if (!customElements.get(tagName)) {\n defineCustomElement$4();\n }\n break;\n case \"searchcraft-popover-form\":\n if (!customElements.get(tagName)) {\n defineCustomElement$1();\n }\n break;\n case \"searchcraft-popover-list-item\":\n if (!customElements.get(tagName)) {\n defineCustomElement$3();\n }\n break;\n case \"searchcraft-popover-list-view\":\n if (!customElements.get(tagName)) {\n defineCustomElement$2();\n }\n break;\n } });\n}\n\nconst SearchcraftPopoverForm = SearchcraftPopoverForm$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftPopoverForm, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-popover-form.js.map","import { p as proxyCustomElement, H, h } from './p-6cafd48d.js';\nimport { u as useSearchcraftStore } from './p-01dc5b3b.js';\nimport { f as formatNumberWithCommas } from './p-755f491b.js';\n\nconst searchcraftResultsInfoModuleCss = \":root{--sc-input-border-radius:8px;--sc-input-search-icon-size:20px;--sc-input-clear-icon-size:20px;--sc-input-padding-left:44px;--sc-input-padding-right:44px;--sc-image-border-radius:8px;--sc-popover-form-border-radius:8px;--sc-popover-list-view-height:400px;--sc-popover-list-item-image-size:60px;--sc-popover-list-item-padding-horizontal:8px;--sc-popover-list-item-padding-vertical:8px;--sc-popover-modal-max-width:570px}:root{--sc-surface-disabled:#D9D9D9;--sc-surface-neutral-primary:#FFFFFF;--sc-surface-neutral-secondary:#F3F3F3;--sc-surface-neutral-light:#FFFFFF;--sc-surface-neutral-primary-hover:#FAFAFA;--sc-surface-neutral-primary-active:#F7F7F7;--sc-surface-neutral-secondary-hover:#EDEDED;--sc-surface-neutral-secondary-active:#E6E6E6;--sc-surface-brand-primary:#000000;--sc-surface-brand-secondary:#E6E6E6;--sc-surface-brand-primary-hover:#2E2E2E;--sc-surface-brand-primary-active:#292929;--sc-surface-brand-secondary-hover:#EBEBEB;--sc-surface-brand-secondary-active:#E0E0E0;--sc-surface-success-primary:#008000;--sc-surface-success-secondary:#CCFFCC;--sc-surface-success-primary-hover:#009900;--sc-surface-success-primary-active:#006600;--sc-surface-success-secondary-hover:#E6FFE6;--sc-surface-success-secondary-active:#E6FFE6;--sc-surface-caution-primary:#CC6600;--sc-surface-caution-secondary:#FFD9B3;--sc-surface-caution-primary-hover:#E57300;--sc-surface-caution-primary-active:#B25A00;--sc-surface-caution-secondary-hover:#FFE5CC;--sc-surface-caution-secondary-active:#FFCC99;--sc-surface-danger-primary:#CC0000;--sc-surface-danger-secondary:#FFCCCC;--sc-surface-danger-primary-hover:#E50000;--sc-surface-danger-primary-active:#B30000;--sc-surface-danger-secondary-hover:#FFE7E7;--sc-surface-danger-secondary-active:#FFB3B3;--sc-content-brand:#000000;--sc-content-success:#008000;--sc-content-caution:#994D00;--sc-content-danger:#990000;--sc-content-disabled:#737373;--sc-content-neutral-primary:#292929;--sc-content-neutral-secondary:#404040;--sc-content-brand-on-primary:#FFFFFF;--sc-content-success-on-primary:#FFFFFF;--sc-content-caution-on-primary:#FFFFFF;--sc-content-danger-on-primary:#FFFFFF;--sc-content-disabled-on-disabled:#737373;--sc-border-neutral:rgba(0,0,0, 0.1);--sc-border-brand:#000000;--sc-border-success:#008000;--sc-border-caution:#CC6600;--sc-border-danger:#CC0000;--sc-border-disabled:#737373}:root{--sc-font-family:sans-serif;--sc-heading-1-font-size:32px;--sc-heading-1-line-height:36px;--sc-heading-1-font-weight:700;--sc-heading-2-font-size:29px;--sc-heading-2-line-height:32px;--sc-heading-2-font-weight:700;--sc-heading-3-font-size:26px;--sc-heading-3-line-height:28px;--sc-heading-3-font-weight:700;--sc-heading-4-font-size:23px;--sc-heading-4-line-height:24px;--sc-heading-4-font-weight:700;--sc-heading-5-font-size:20px;--sc-heading-5-line-height:24px;--sc-heading-5-font-weight:700;--sc-heading-6-font-size:10px;--sc-heading-6-line-height:12px;--sc-heading-6-font-weight:700;--sc-body-bold-font-size:16px;--sc-body-bold-line-height:20px;--sc-body-bold-font-weight:700;--sc-body-font-size:16px;--sc-body-line-height:20px;--sc-body-font-weight:400;--sc-body-small-bold-font-size:12px;--sc-body-small-bold-line-height:16px;--sc-body-small-bold-font-weight:700;--sc-body-small-font-size:12px;--sc-body-small-line-height:16px;--sc-body-small-font-weight:400}:root{--sc-breakpoint-sm:576px;--sc-breakpoint-md:768px;--sc-breakpoint-lg:992px}.searchcraft-results-info-container{border-bottom:1px solid var(--sc-surface-disabled);display:flex;justify-content:flex-start}.searchcraft-results-info-content{color:var(--sc-content-primary);font-family:var(--sc-font-family);font-size:18px;font-weight:600;line-height:20px;margin:0px 0 8px}@media (max-width: 768px){.searchcraft-results-info-content{margin:0;margin-bottom:8px}}\";\nconst SearchcraftResultsInfoStyle0 = searchcraftResultsInfoModuleCss;\n\nconst SearchcraftResultsInfo$1 = /*@__PURE__*/ proxyCustomElement(class SearchcraftResultsInfo extends H {\n constructor() {\n super();\n this.__registerHost();\n this.isRequesting = false;\n this.resultsCount = 0;\n this.responseTime = '';\n this.query = '';\n }\n connectedCallback() {\n this.unsubscribe = useSearchcraftStore.subscribe((state) => {\n var _a, _b, _c, _d;\n this.isRequesting = state.isRequesting;\n this.resultsCount = ((_b = (_a = state.searchResults) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.count) || 0;\n this.responseTime = ((((_d = (_c = state.searchResults) === null || _c === void 0 ? void 0 : _c.data) === null || _d === void 0 ? void 0 : _d.time_taken) || 0) * 1000).toFixed(2);\n this.query = state.query || '';\n });\n }\n disconnectedCallback() {\n if (this.unsubscribe) {\n this.unsubscribe();\n }\n }\n render() {\n if (!this.query || this.resultsCount === 0) {\n return null;\n }\n const formattedResults = formatNumberWithCommas(this.resultsCount);\n return (h(\"div\", { class: 'searchcraft-results-info-container' }, h(\"p\", { class: 'searchcraft-results-info-content' }, formattedResults, \" results found in \", this.responseTime, \"ms\")));\n }\n static get style() { return SearchcraftResultsInfoStyle0; }\n}, [0, \"searchcraft-results-info\", {\n \"isRequesting\": [32],\n \"resultsCount\": [32],\n \"responseTime\": [32],\n \"query\": [32]\n }]);\nfunction defineCustomElement$1() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"searchcraft-results-info\"];\n components.forEach(tagName => { switch (tagName) {\n case \"searchcraft-results-info\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, SearchcraftResultsInfo$1);\n }\n break;\n } });\n}\n\nconst SearchcraftResultsInfo = SearchcraftResultsInfo$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftResultsInfo, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-results-info.js.map","import { S as SearchcraftSlider$1, d as defineCustomElement$1 } from './p-cc9f8c61.js';\n\nconst SearchcraftSlider = SearchcraftSlider$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftSlider, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-slider.js.map","import { S as SearchcraftToggleButton$1, d as defineCustomElement$1 } from './p-662cb490.js';\n\nconst SearchcraftToggleButton = SearchcraftToggleButton$1;\nconst defineCustomElement = defineCustomElement$1;\n\nexport { SearchcraftToggleButton, defineCustomElement };\n\n//# sourceMappingURL=searchcraft-toggle-button.js.map","/**\n * @license\n * Copyright 2018 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nconst e=new Set([\"children\",\"localName\",\"ref\",\"style\",\"className\"]),n=new WeakMap,t=(e,t,o,l,a)=>{const s=a?.[t];void 0===s?(e[t]=o,null==o&&t in HTMLElement.prototype&&e.removeAttribute(t)):o!==l&&((e,t,o)=>{let l=n.get(e);void 0===l&&n.set(e,l=new Map);let a=l.get(t);void 0!==o?void 0===a?(l.set(t,a={handleEvent:o}),e.addEventListener(t,a)):a.handleEvent=o:void 0!==a&&(l.delete(t),e.removeEventListener(t,a))})(e,s,o)},o=({react:n,tagName:o,elementClass:l,events:a,displayName:s})=>{const c=new Set(Object.keys(a??{})),r=n.forwardRef(((s,r)=>{const i=n.useRef(new Map),d=n.useRef(null),f={},u={};for(const[n,t]of Object.entries(s))e.has(n)?f[\"className\"===n?\"class\":n]=t:c.has(n)||n in l.prototype?u[n]=t:f[n]=t;return n.useLayoutEffect((()=>{if(null===d.current)return;const e=new Map;for(const n in u)t(d.current,n,s[n],i.current.get(n),a),i.current.delete(n),e.set(n,s[n]);for(const[e,n]of i.current)t(d.current,e,void 0,n,a);i.current=e})),n.useLayoutEffect((()=>{d.current?.removeAttribute(\"defer-hydration\")}),[]),f.suppressHydrationWarning=!0,n.createElement(o,{...f,ref:n.useCallback((e=>{d.current=e,\"function\"==typeof r?r(e):null!==r&&(r.current=e)}),[r])})}));return r.displayName=s??l.name,r};export{o as createComponent};\n//# sourceMappingURL=create-component.js.map\n","import { createComponent as a } from \"@lit/react\";\nconst i = ({\n defineCustomElement: e,\n ...r\n}) => (typeof e < \"u\" && e(), a(r)), p = ({\n hydrateModule: e,\n properties: r,\n tagName: n\n}) => async (t) => {\n const { createComponentForServerSideRendering: o } = await import(\"./ssr.js\");\n return o({\n tagName: n,\n properties: r,\n renderToString: (await e).renderToString\n })(t);\n};\nexport {\n i as createComponent,\n p as createSSRComponent\n};\n","'use client';\n\n/**\n * This file was automatically generated by the Stencil React Output Target.\n * Changes to this file may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\n/* eslint-disable */\n\nimport { SearchcraftBaseSearchResult as SearchcraftBaseSearchResultElement, defineCustomElement as defineSearchcraftBaseSearchResult } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-base-search-result.js\";\nimport { SearchcraftBaseSearchResults as SearchcraftBaseSearchResultsElement, defineCustomElement as defineSearchcraftBaseSearchResults } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-base-search-results.js\";\nimport { SearchcraftButton as SearchcraftButtonElement, defineCustomElement as defineSearchcraftButton } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-button.js\";\nimport { SearchcraftErrorMessage as SearchcraftErrorMessageElement, defineCustomElement as defineSearchcraftErrorMessage } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-error-message.js\";\nimport { SearchcraftFacetList as SearchcraftFacetListElement, defineCustomElement as defineSearchcraftFacetList } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-facet-list.js\";\nimport { SearchcraftFilterPanel as SearchcraftFilterPanelElement, defineCustomElement as defineSearchcraftFilterPanel } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-filter-panel.js\";\nimport { SearchcraftInputForm as SearchcraftInputFormElement, defineCustomElement as defineSearchcraftInputForm } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-input-form.js\";\nimport { SearchcraftInputLabel as SearchcraftInputLabelElement, defineCustomElement as defineSearchcraftInputLabel } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-input-label.js\";\nimport { SearchcraftPopoverButton as SearchcraftPopoverButtonElement, defineCustomElement as defineSearchcraftPopoverButton } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-button.js\";\nimport { SearchcraftPopoverForm as SearchcraftPopoverFormElement, defineCustomElement as defineSearchcraftPopoverForm } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-form.js\";\nimport { SearchcraftPopoverListItem as SearchcraftPopoverListItemElement, defineCustomElement as defineSearchcraftPopoverListItem } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-list-item.js\";\nimport { SearchcraftPopoverListView as SearchcraftPopoverListViewElement, defineCustomElement as defineSearchcraftPopoverListView } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-popover-list-view.js\";\nimport { SearchcraftResultsInfo as SearchcraftResultsInfoElement, defineCustomElement as defineSearchcraftResultsInfo } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-results-info.js\";\nimport { SearchcraftSlider as SearchcraftSliderElement, defineCustomElement as defineSearchcraftSlider } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-slider.js\";\nimport { SearchcraftToggleButton as SearchcraftToggleButtonElement, defineCustomElement as defineSearchcraftToggleButton } from \"@searchcraft/javascript-sdk/dist/components/searchcraft-toggle-button.js\";\nimport type { EventName, StencilReactComponent } from '@stencil/react-output-target/runtime';\nimport { createComponent } from '@stencil/react-output-target/runtime';\nimport React from 'react';\n\ntype SearchcraftBaseSearchResultEvents = NonNullable<unknown>;\n\nexport const SearchcraftBaseSearchResult: StencilReactComponent<SearchcraftBaseSearchResultElement, SearchcraftBaseSearchResultEvents> = /*@__PURE__*/ createComponent<SearchcraftBaseSearchResultElement, SearchcraftBaseSearchResultEvents>({\n tagName: 'searchcraft-base-search-result',\n elementClass: SearchcraftBaseSearchResultElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftBaseSearchResultEvents,\n defineCustomElement: defineSearchcraftBaseSearchResult\n});\n\ntype SearchcraftBaseSearchResultsEvents = { onNoResults: EventName<CustomEvent<void>> };\n\nexport const SearchcraftBaseSearchResults: StencilReactComponent<SearchcraftBaseSearchResultsElement, SearchcraftBaseSearchResultsEvents> = /*@__PURE__*/ createComponent<SearchcraftBaseSearchResultsElement, SearchcraftBaseSearchResultsEvents>({\n tagName: 'searchcraft-base-search-results',\n elementClass: SearchcraftBaseSearchResultsElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onNoResults: 'noResults' } as SearchcraftBaseSearchResultsEvents,\n defineCustomElement: defineSearchcraftBaseSearchResults\n});\n\ntype SearchcraftButtonEvents = { onButtonClick: EventName<CustomEvent<void>> };\n\nexport const SearchcraftButton: StencilReactComponent<SearchcraftButtonElement, SearchcraftButtonEvents> = /*@__PURE__*/ createComponent<SearchcraftButtonElement, SearchcraftButtonEvents>({\n tagName: 'searchcraft-button',\n elementClass: SearchcraftButtonElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onButtonClick: 'buttonClick' } as SearchcraftButtonEvents,\n defineCustomElement: defineSearchcraftButton\n});\n\ntype SearchcraftErrorMessageEvents = NonNullable<unknown>;\n\nexport const SearchcraftErrorMessage: StencilReactComponent<SearchcraftErrorMessageElement, SearchcraftErrorMessageEvents> = /*@__PURE__*/ createComponent<SearchcraftErrorMessageElement, SearchcraftErrorMessageEvents>({\n tagName: 'searchcraft-error-message',\n elementClass: SearchcraftErrorMessageElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftErrorMessageEvents,\n defineCustomElement: defineSearchcraftErrorMessage\n});\n\ntype SearchcraftFacetListEvents = { onFacetSelectionUpdated: EventName<CustomEvent<{ paths: string[] }>> };\n\nexport const SearchcraftFacetList: StencilReactComponent<SearchcraftFacetListElement, SearchcraftFacetListEvents> = /*@__PURE__*/ createComponent<SearchcraftFacetListElement, SearchcraftFacetListEvents>({\n tagName: 'searchcraft-facet-list',\n elementClass: SearchcraftFacetListElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onFacetSelectionUpdated: 'facetSelectionUpdated' } as SearchcraftFacetListEvents,\n defineCustomElement: defineSearchcraftFacetList\n});\n\ntype SearchcraftFilterPanelEvents = NonNullable<unknown>;\n\nexport const SearchcraftFilterPanel: StencilReactComponent<SearchcraftFilterPanelElement, SearchcraftFilterPanelEvents> = /*@__PURE__*/ createComponent<SearchcraftFilterPanelElement, SearchcraftFilterPanelEvents>({\n tagName: 'searchcraft-filter-panel',\n elementClass: SearchcraftFilterPanelElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftFilterPanelEvents,\n defineCustomElement: defineSearchcraftFilterPanel\n});\n\ntype SearchcraftInputFormEvents = {\n onInputCleared: EventName<CustomEvent<void>>,\n onNoResultsReceived: EventName<CustomEvent<void>>,\n onInputFocus: EventName<CustomEvent<void>>,\n onInputBlur: EventName<CustomEvent<void>>,\n onInputInit: EventName<CustomEvent<void>>,\n onQuerySubmit: EventName<CustomEvent<string>>\n};\n\nexport const SearchcraftInputForm: StencilReactComponent<SearchcraftInputFormElement, SearchcraftInputFormEvents> = /*@__PURE__*/ createComponent<SearchcraftInputFormElement, SearchcraftInputFormEvents>({\n tagName: 'searchcraft-input-form',\n elementClass: SearchcraftInputFormElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {\n onInputCleared: 'inputCleared',\n onNoResultsReceived: 'noResultsReceived',\n onInputFocus: 'inputFocus',\n onInputBlur: 'inputBlur',\n onInputInit: 'inputInit',\n onQuerySubmit: 'querySubmit'\n } as SearchcraftInputFormEvents,\n defineCustomElement: defineSearchcraftInputForm\n});\n\ntype SearchcraftInputLabelEvents = NonNullable<unknown>;\n\nexport const SearchcraftInputLabel: StencilReactComponent<SearchcraftInputLabelElement, SearchcraftInputLabelEvents> = /*@__PURE__*/ createComponent<SearchcraftInputLabelElement, SearchcraftInputLabelEvents>({\n tagName: 'searchcraft-input-label',\n elementClass: SearchcraftInputLabelElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftInputLabelEvents,\n defineCustomElement: defineSearchcraftInputLabel\n});\n\ntype SearchcraftPopoverButtonEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverButton: StencilReactComponent<SearchcraftPopoverButtonElement, SearchcraftPopoverButtonEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverButtonElement, SearchcraftPopoverButtonEvents>({\n tagName: 'searchcraft-popover-button',\n elementClass: SearchcraftPopoverButtonElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverButtonEvents,\n defineCustomElement: defineSearchcraftPopoverButton\n});\n\ntype SearchcraftPopoverFormEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverForm: StencilReactComponent<SearchcraftPopoverFormElement, SearchcraftPopoverFormEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverFormElement, SearchcraftPopoverFormEvents>({\n tagName: 'searchcraft-popover-form',\n elementClass: SearchcraftPopoverFormElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverFormEvents,\n defineCustomElement: defineSearchcraftPopoverForm\n});\n\ntype SearchcraftPopoverListItemEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverListItem: StencilReactComponent<SearchcraftPopoverListItemElement, SearchcraftPopoverListItemEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverListItemElement, SearchcraftPopoverListItemEvents>({\n tagName: 'searchcraft-popover-list-item',\n elementClass: SearchcraftPopoverListItemElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverListItemEvents,\n defineCustomElement: defineSearchcraftPopoverListItem\n});\n\ntype SearchcraftPopoverListViewEvents = NonNullable<unknown>;\n\nexport const SearchcraftPopoverListView: StencilReactComponent<SearchcraftPopoverListViewElement, SearchcraftPopoverListViewEvents> = /*@__PURE__*/ createComponent<SearchcraftPopoverListViewElement, SearchcraftPopoverListViewEvents>({\n tagName: 'searchcraft-popover-list-view',\n elementClass: SearchcraftPopoverListViewElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftPopoverListViewEvents,\n defineCustomElement: defineSearchcraftPopoverListView\n});\n\ntype SearchcraftResultsInfoEvents = NonNullable<unknown>;\n\nexport const SearchcraftResultsInfo: StencilReactComponent<SearchcraftResultsInfoElement, SearchcraftResultsInfoEvents> = /*@__PURE__*/ createComponent<SearchcraftResultsInfoElement, SearchcraftResultsInfoEvents>({\n tagName: 'searchcraft-results-info',\n elementClass: SearchcraftResultsInfoElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: {} as SearchcraftResultsInfoEvents,\n defineCustomElement: defineSearchcraftResultsInfo\n});\n\ntype SearchcraftSliderEvents = { onRangeChanged: EventName<CustomEvent<{ startValue: number; endValue: number }>> };\n\nexport const SearchcraftSlider: StencilReactComponent<SearchcraftSliderElement, SearchcraftSliderEvents> = /*@__PURE__*/ createComponent<SearchcraftSliderElement, SearchcraftSliderEvents>({\n tagName: 'searchcraft-slider',\n elementClass: SearchcraftSliderElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onRangeChanged: 'rangeChanged' } as SearchcraftSliderEvents,\n defineCustomElement: defineSearchcraftSlider\n});\n\ntype SearchcraftToggleButtonEvents = { onToggleUpdated: EventName<CustomEvent<boolean>> };\n\nexport const SearchcraftToggleButton: StencilReactComponent<SearchcraftToggleButtonElement, SearchcraftToggleButtonEvents> = /*@__PURE__*/ createComponent<SearchcraftToggleButtonElement, SearchcraftToggleButtonEvents>({\n tagName: 'searchcraft-toggle-button',\n elementClass: SearchcraftToggleButtonElement,\n // @ts-ignore - React type of Stencil Output Target may differ from the React version used in the Nuxt.js project, this can be ignored.\n react: React,\n events: { onToggleUpdated: 'toggleUpdated' } as SearchcraftToggleButtonEvents,\n defineCustomElement: defineSearchcraftToggleButton\n});\n","import type { FC } from 'react';\n\nimport { SearchcraftBaseSearchResult as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftBaseSearchResultProps\n extends Components.SearchcraftBaseSearchResult {}\n\nconst SearchcraftBaseSearchResult: FC<SearchcraftBaseSearchResultProps> = (\n props,\n) => <Component {...props} />;\n\nexport { SearchcraftBaseSearchResult };\nexport type { SearchcraftBaseSearchResultProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftBaseSearchResults as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftBaseSearchResultsProps\n extends Components.SearchcraftBaseSearchResults {}\n\nconst SearchcraftBaseSearchResults: FC<SearchcraftBaseSearchResultsProps> = (\n props,\n) => <Component {...props} />;\n\nexport { SearchcraftBaseSearchResults };\nexport type { SearchcraftBaseSearchResultsProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftButton as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftButtonProps extends Components.SearchcraftButton {}\n\nconst SearchcraftButton: FC<SearchcraftButtonProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftButton };\nexport type { SearchcraftButtonProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftErrorMessage as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftErrorMessageProps\n extends Components.SearchcraftErrorMessage {}\n\nconst SearchcraftErrorMessage: FC<SearchcraftErrorMessageProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftErrorMessage };\nexport type { SearchcraftErrorMessageProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftFacetList as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftFacetListProps extends Components.SearchcraftFacetList {}\n\nconst SearchcraftFacetList: FC<SearchcraftFacetListProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftFacetList };\nexport type { SearchcraftFacetListProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftFilterPanel as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftFilterPanelProps\n extends Components.SearchcraftFilterPanel {}\n\nconst SearchcraftFilterPanel: FC<SearchcraftFilterPanelProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftFilterPanel };\nexport type { SearchcraftFilterPanelProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftInputForm as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftInputFormProps extends Components.SearchcraftInputForm {}\n\nconst SearchcraftInputForm: FC<SearchcraftInputFormProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftInputForm };\nexport type { SearchcraftInputFormProps };\n","import type { FC } from 'react';\n\nimport type { Components } from '@searchcraft/javascript-sdk';\nimport { SearchcraftInputLabel as Component } from '../stencil-web-components/components';\n\ninterface SearchcraftInputLabelProps extends Components.SearchcraftInputLabel { }\n\nconst SearchcraftInputLabel: FC<SearchcraftInputLabelProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftInputLabel };\nexport type { SearchcraftInputLabelProps };\n","import type { FC } from 'react';\n\nimport type { Components } from '@searchcraft/javascript-sdk';\nimport { SearchcraftPopoverButton as Component } from '../stencil-web-components/components';\n\ninterface SearchcraftPopoverButtonProps extends Components.SearchcraftPopoverButton { }\n\nconst SearchcraftPopoverButton: FC<SearchcraftPopoverButtonProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftPopoverButton };\nexport type { SearchcraftPopoverButtonProps };\n","import type { FC } from 'react';\n\nimport type { Components } from '@searchcraft/javascript-sdk';\nimport { SearchcraftPopoverForm as Component } from '../stencil-web-components/components';\n\ninterface SearchcraftPopoverFormProps extends Components.SearchcraftPopoverForm { }\n\nconst SearchcraftPopoverForm: FC<SearchcraftPopoverFormProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftPopoverForm };\nexport type { SearchcraftPopoverFormProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftResultsInfo as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftResultsInfoProps\n extends Components.SearchcraftResultsInfo {}\n\nconst SearchcraftResultsInfo: FC<SearchcraftResultsInfoProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftResultsInfo };\nexport type { SearchcraftResultsInfoProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftSlider as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftSliderProps extends Components.SearchcraftSlider {}\n\nconst SearchcraftSlider: FC<SearchcraftSliderProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftSlider };\nexport type { SearchcraftSliderProps };\n","import type { FC } from 'react';\n\nimport { SearchcraftToggleButton as Component } from '../stencil-web-components/components';\nimport type { Components } from '@searchcraft/javascript-sdk';\n\ninterface SearchcraftToggleButtonProps\n extends Components.SearchcraftToggleButton {}\n\nconst SearchcraftToggleButton: FC<SearchcraftToggleButtonProps> = (props) => (\n <Component {...props} />\n);\n\nexport { SearchcraftToggleButton };\nexport type { SearchcraftToggleButtonProps };\n"],"names":["NAMESPACE","BUILD","__defProp","__export","target","all","name","SVG_NS","HTML_NS","hostRefs","deleteHostRef","ref","getHostRef","registerHost","hostElement","cmpMeta","hostRef","r","isMemberInElement","elm","memberName","consoleError","el","styles","HYDRATED_STYLE_ID","SLOT_FB_CSS","win","doc","H","plt","h2","eventName","listener","opts","supportsShadow","promiseResolve","v","supportsConstructableStylesheets","queuePending","queueDomReads","queueDomWrites","queueTask","queue","write","cb","nextTick","flush","consume","i2","e","writeTask","isComplexType","o","queryNonceMetaTagContent","doc2","_a","_b","_c","result_exports","err","map","ok","unwrap","unwrapErr","value","result","fn","val","newVal","updateFallbackSlotVisibility","childNodes","getHostSlotNodes","slotNode","getHostSlotChildNodes","childNode","hostName","slotName","slottedNodes","node","includeSlot","isNodeLocatedInSlot","nodeToRelocate","createTime","fnName","tagName","h","nodeName","vnodeData","children","child","key","simple","lastSimple","vNodeChildren","walk","c","newVNode","classData","k","vdomFnUtils","vnode","tag","text","Host","isHost","convertToPublic","convertToPrivate","parsePropertyValue","propValue","propType","getElement","createEvent","flags","detail","emitEvent","ev","rootAppliedStyles","registerStyle","scopeId2","cssText","allowCS","style","addStyle","styleContainerNode","mode","getScopeId","appliedStyles","styleElm","nonce","preconnectLinks","referenceNode2","stylesheet","existingStyleContainer","attachStyles","endAttachStyles","cmp","setAccessor","oldValue","newValue","isSvg","isProp","ln","classList","oldClasses","parseClassList","newClasses","prop","capture","CAPTURE_EVENT_SUFFIX","CAPTURE_EVENT_REGEX","isComplex","n","parseClassListRegex","updateElement","oldVnode","newVnode","isSvgMode2","oldVnodeAttrs","newVnodeAttrs","sortedAttrNames","attrNames","attr","contentRef","hostTagName","useNativeShadowDom","checkSlotFallbackVisibility","checkSlotRelocate","isSvgMode","createElm","oldParentVNode","newParentVNode","childIndex","newVNode2","oldVNode","putBackInOriginalLocation","parentElm","recursive","oldSlotChildNodes","insertBefore","referenceNode","addVnodes","before","parentVNode","vnodes","startIdx","endIdx","containerElm","removeVnodes","index","updateChildren","oldCh","newCh","isInitialRender","oldStartIdx","newStartIdx","idxInOld","oldEndIdx","oldStartVnode","oldEndVnode","newEndIdx","newStartVnode","newEndVnode","elmToMove","isSameVnode","patch","leftVNode","rightVNode","oldChildren","newChildren","defaultHolder","relocateNodes","markSlotContentForRelocation","hostContentNodes","j","relocateNodeData","relocateNode","parent","newNode","reference","renderVdom","renderFnResults","isInitialLoad","_d","hostElm","rootVnode","relocateData","orgLocationNode","slotRefNode","parentNodeRef","insertBeforeNode","refNode","nextSibling","attachToAncestor","ancestorComponent","scheduleUpdate","dispatchHooks","endSchedule","instance","maybePromise","enqueue","updateComponent","isPromisey","err2","endUpdate","rc","endRender","callRender","childrenPromises","postUpdate","postUpdateComponent","endPostUpdate","addHydratedFlag","safeCall","appDidLoad","who","method","arg","getValue","propName","setValue","oldVal","areBothNaN","watchMethods","watchMethodName","proxyComponent","Cstr","prototype","members","memberFlags","origGetter","origSetter","currentValue","attrNameToPropName","attrName","_a2","flags2","entry","callbackName","propDesc","_","m","initializeComponent","hmrVersionId","cmpTag","endRegisterStyles","schedule","fireConnectedCallback","connectedCallback","endConnected","setContentReference","contentRefElm","disconnectedCallback","proxyCustomElement","compactMeta","originalConnectedCallback","originalDisconnectedCallback","Fragment","zustand","vanilla$1","createStoreImpl","createState","state","listeners","setState","partial","replace","nextState","previousState","getState","api","initialState","createStore","react$1","react","react_production","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_CONSUMER_TYPE","REACT_CONTEXT_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","MAYBE_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","ReactNoopUpdateQueue","assign","emptyObject","Component","props","context","updater","partialState","callback","ComponentDummy","PureComponent","pureComponentPrototype","isArrayImpl","ReactSharedInternals","hasOwnProperty","ReactElement","type","self","source","owner","cloneAndReplaceKey","oldElement","newKey","isValidElement","object","escape","escaperLookup","match","userProvidedKeyEscapeRegex","getElementKey","element","noop$1","resolveThenable","thenable","fulfilledValue","error","mapIntoArray","array","escapedPrefix","nameSoFar","invokeCallback","nextNamePrefix","i","mapChildren","func","count","lazyInitializer","payload","ctor","moduleObject","reportGlobalError","event","noop","forEachFunc","forEachContext","config","childArray","defaultValue","childrenLength","render","compare","scope","prevTransition","currentTransition","returnValue","onStartTransitionFinish","usable","action","permalink","deps","Context","initialValue","create","passthrough","reducer","initialArg","init","subscribe","getSnapshot","getServerSnapshot","React","vanilla","identity","useStore","selector","slice","createImpl","useBoundStore","exports","D","B","L","q","w","s","u","l","a","p","y","b","P","N","M","f","g","R","G","W","V","$","F","K","E","z","T","C","A","J","Q","Y","X","Z","ee","te","ne","d","U","x","I","S","re","ae","t","O","se","useSearchcraftStore","set","get","searchcraft","debuggerInstance","log","level","message","isVisible","data","fieldName","currentPaths","currentValues","query","results","facets","isRequesting","updatedFacets","searchcraftInstance","debug","searchcraftBaseSearchResultModuleCss","SearchcraftBaseSearchResultStyle0","SearchcraftBaseSearchResult","document_position","search_term","number_of_documents","imageContainer","contentContainer","defineCustomElement","SearchcraftBaseSearchResult$1","defineCustomElement$1","getDocumentValueFromSearchResultMapping","document","mapping","fieldNameDetails","valueFound","getFormattedTimeFromNow","getMillis","unit","formatNumberWithCommas","number","timestamp","now","inputTime","diffInSeconds","minutes","hours","days","years","parseCustomStyles","serializeStyles","searchcraftErrorMessageModuleCss","SearchcraftErrorMessageStyle0","SearchcraftErrorMessage","searchcraftBaseSearchResultsModuleCss","SearchcraftBaseSearchResultsStyle0","SearchcraftBaseSearchResults$1","searchResults","titleContent","subtitleContent","bodyContent","containerHref","buttonHref","imageSource","footerContent","serializedStyles","_e","_f","_g","_h","_j","_k","documents","_index","finalComponents","documentElements","defineCustomElement$3","defineCustomElement$2","SearchcraftBaseSearchResults","classnames","module","hasOwn","classNames","classes","appendClass","parseValue","newClass","searchcraftButtonModuleCss","SearchcraftButtonStyle0","SearchcraftButton","SearchcraftButton$1","SearchcraftErrorMessage$1","deepMergeWithSpread","obj1","obj2","removeSubstringMatches","arr","otherEntry","otherIndex","facetToRecord","facet","records","traverseAndAddToFragments","facetChild","recordToObject","record","root","fragment","pathParts","currentRoot","currentPath","part","nextPath","objectToFacet","childObject","transformed","subChildObject","filterRecordByParentPaths","record1","record2","paths1","paths2","parentPaths","path","mergeFacetRoots","incomingRoot","currentArray","incomingArray","currentRootFacetChild","incomingRootFacetChild","currentRecord","incomingRecord","filteredCurrentRecord","mergedRecord","mergedObject","mergedFacetChild","searchcraftFacetListModuleCss","SearchcraftFacetListStyle0","SearchcraftFacetList","label","char","facetChildAncestor","facetPrime","timeTaken","incomingFacetRoot","updatedPaths","testPath","acc","str","paths","pathsWithParentPathsRemoved","firstFacet","isChildSelected","_event","grandchild","SearchcraftFacetList$1","searchcraftSliderModuleCss","SearchcraftSliderStyle0","SearchcraftSlider","inputElement","rangeMin","rangeMax","startPercent","endPercent","startLabel","endLabel","searchcraftToggleButtonModuleCss","SearchcraftToggleButtonStyle0","SearchcraftToggleButton","searchcraftFilterPanelModuleCss","SearchcraftFilterPanelStyle0","SearchcraftFilterPanel$1","min","max","start","end","isActive","filterItem","item","granularityValue","defineCustomElement$4","SearchcraftFilterPanel","searchcraftInputLabelModuleCss","SearchcraftInputLabelStyle0","SearchcraftInputLabel","version","description","author","license","main","types","collection","unpkg","repository","files","scripts","dependencies","devDependencies","packageJson","searchcraftInputFormModuleCss","SearchcraftInputFormStyle0","SearchcraftInput","input","validatedCustomStyles","isShowingClearButton","inputGridClassNames","inputGridStyles","SearchcraftInputForm","SearchcraftInputLabel$1","searchcraftPopoverButtonModuleCss","SearchcraftPopoverButtonStyle0","SearchcraftPopoverButton$1","SearchcraftPopoverButton","searchcraftPopoverListItemModuleCss","SearchcraftPopoverListItemStyle0","SearchcraftPopoverListItem","searchcraftPopoverListViewModuleCss","SearchcraftPopoverListViewStyle0","SearchcraftPopoverListView","href","imageAlt","searchcraftPopoverFormModuleCss","SearchcraftPopoverFormStyle0","SearchcraftPopoverForm$1","computedStyle","hostElementInput","direction","listItems","currentIndex","isListViewVisible","popoverFormClassNames","defineCustomElement$7","defineCustomElement$6","defineCustomElement$5","SearchcraftPopoverForm","searchcraftResultsInfoModuleCss","SearchcraftResultsInfoStyle0","SearchcraftResultsInfo$1","formattedResults","SearchcraftResultsInfo","SearchcraftSlider$1","SearchcraftToggleButton$1","createComponent","SearchcraftBaseSearchResultElement","defineSearchcraftBaseSearchResult","SearchcraftBaseSearchResultsElement","defineSearchcraftBaseSearchResults","SearchcraftButtonElement","defineSearchcraftButton","SearchcraftErrorMessageElement","defineSearchcraftErrorMessage","SearchcraftFacetListElement","defineSearchcraftFacetList","SearchcraftFilterPanelElement","defineSearchcraftFilterPanel","SearchcraftInputFormElement","defineSearchcraftInputForm","SearchcraftInputLabelElement","defineSearchcraftInputLabel","SearchcraftPopoverButtonElement","defineSearchcraftPopoverButton","SearchcraftPopoverFormElement","defineSearchcraftPopoverForm","SearchcraftResultsInfoElement","defineSearchcraftResultsInfo","SearchcraftSliderElement","defineSearchcraftSlider","SearchcraftToggleButtonElement","defineSearchcraftToggleButton","jsx"],"mappings":";;AAAA,MAAMA,KAAY,8BACZC;AAAA;AAAA,EAAyC,EAAE,aAAa,IAAM,oBAAoB,IAAO,cAAc,IAAM,YAAY,IAAO,cAAc,IAAM,cAAc,IAAO,YAAY,IAAM,cAAc,IAAO,cAAc,IAAO,cAAc,IAAO,iBAAiB,IAAO,aAAa,IAAO,eAAe,IAAO,eAAe,IAAO,mBAAmB,IAAM,kBAAkB,IA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