@searchcraft/vue-sdk 0.9.4 → 0.9.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -1,24 +1,24 @@
1
- (function(L,G){typeof exports=="object"&&typeof module<"u"?G(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],G):(L=typeof globalThis<"u"?globalThis:L||self,G(L.SearchcraftVueSdk={},L.Vue))})(this,function(L,G){"use strict";var Uc=Object.defineProperty;var zc=(L,G,Ne)=>G in L?Uc(L,G,{enumerable:!0,configurable:!0,writable:!0,value:Ne}):L[G]=Ne;var h=(L,G,Ne)=>zc(L,typeof G!="symbol"?G+"":G,Ne);var Ya;var Ne=Object.defineProperty,_s=(e,t,r)=>t in e?Ne(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,F=(e,t,r)=>_s(e,typeof t!="symbol"?t+"":t,r);function be(e,t,r,a){return new(r||(r=Promise))(function(n,o){function s(l){try{u(a.next(l))}catch(i){o(i)}}function c(l){try{u(a.throw(l))}catch(i){o(i)}}function u(l){var i;l.done?n(l.value):(i=l.value,i instanceof r?i:new r(function(p){p(i)})).then(s,c)}u((a=a.apply(e,[])).next())})}function ve(e,t){var r,a,n,o,s={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(u){return function(l){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(s=0)),s;)try{if(r=1,a&&(n=2&i[0]?a.return:i[0]?a.throw||((n=a.return)&&n.call(a),0):a.next)&&!(n=n.call(a,i[1])).done)return n;switch(a=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,a=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(n=s.trys,!((n=n.length>0&&n[n.length-1])||i[0]!==6&&i[0]!==2)){s=0;continue}if(i[0]===3&&(!n||i[1]>n[0]&&i[1]<n[3])){s.label=i[1];break}if(i[0]===6&&s.label<n[1]){s.label=n[1],n=i;break}if(n&&s.label<n[2]){s.label=n[2],s.ops.push(i);break}n[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(p){i=[6,p],a=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([u,l])}}}var ye={exclude:[]},Ir={},As={timeout:"true"},fe=function(e,t){typeof window<"u"&&(Ir[e]=t)},Is=function(){return Object.fromEntries(Object.entries(Ir).filter(function(e){var t,r=e[0];return!(!((t=ye==null?void 0:ye.exclude)===null||t===void 0)&&t.includes(r))}).map(function(e){return[e[0],(0,e[1])()]}))};function dt(e){return e^=e>>>16,e=Math.imul(e,2246822507),e^=e>>>13,e=Math.imul(e,3266489909),(e^=e>>>16)>>>0}var q=new Uint32Array([597399067,2869860233,951274213,2716044179]);function le(e,t){return e<<t|e>>>32-t}function Ut(e,t){var r;if(t===void 0&&(t=0),t=t?0|t:0,typeof e=="string"&&(r=e,e=new TextEncoder().encode(r).buffer),!(e instanceof ArrayBuffer))throw new TypeError("Expected key to be ArrayBuffer or string");var a=new Uint32Array([t,t,t,t]);(function(o,s){for(var c=o.byteLength/16|0,u=new Uint32Array(o,0,4*c),l=0;l<c;l++){var i=u.subarray(4*l,4*(l+1));i[0]=Math.imul(i[0],q[0]),i[0]=le(i[0],15),i[0]=Math.imul(i[0],q[1]),s[0]=s[0]^i[0],s[0]=le(s[0],19),s[0]=s[0]+s[1],s[0]=Math.imul(s[0],5)+1444728091,i[1]=Math.imul(i[1],q[1]),i[1]=le(i[1],16),i[1]=Math.imul(i[1],q[2]),s[1]=s[1]^i[1],s[1]=le(s[1],17),s[1]=s[1]+s[2],s[1]=Math.imul(s[1],5)+197830471,i[2]=Math.imul(i[2],q[2]),i[2]=le(i[2],17),i[2]=Math.imul(i[2],q[3]),s[2]=s[2]^i[2],s[2]=le(s[2],15),s[2]=s[2]+s[3],s[2]=Math.imul(s[2],5)+2530024501,i[3]=Math.imul(i[3],q[3]),i[3]=le(i[3],18),i[3]=Math.imul(i[3],q[0]),s[3]=s[3]^i[3],s[3]=le(s[3],13),s[3]=s[3]+s[0],s[3]=Math.imul(s[3],5)+850148119}})(e,a),function(o,s){var c=o.byteLength/16|0,u=o.byteLength%16,l=new Uint32Array(4),i=new Uint8Array(o,16*c,u);switch(u){case 15:l[3]=l[3]^i[14]<<16;case 14:l[3]=l[3]^i[13]<<8;case 13:l[3]=l[3]^i[12]<<0,l[3]=Math.imul(l[3],q[3]),l[3]=le(l[3],18),l[3]=Math.imul(l[3],q[0]),s[3]=s[3]^l[3];case 12:l[2]=l[2]^i[11]<<24;case 11:l[2]=l[2]^i[10]<<16;case 10:l[2]=l[2]^i[9]<<8;case 9:l[2]=l[2]^i[8]<<0,l[2]=Math.imul(l[2],q[2]),l[2]=le(l[2],17),l[2]=Math.imul(l[2],q[3]),s[2]=s[2]^l[2];case 8:l[1]=l[1]^i[7]<<24;case 7:l[1]=l[1]^i[6]<<16;case 6:l[1]=l[1]^i[5]<<8;case 5:l[1]=l[1]^i[4]<<0,l[1]=Math.imul(l[1],q[1]),l[1]=le(l[1],16),l[1]=Math.imul(l[1],q[2]),s[1]=s[1]^l[1];case 4:l[0]=l[0]^i[3]<<24;case 3:l[0]=l[0]^i[2]<<16;case 2:l[0]=l[0]^i[1]<<8;case 1:l[0]=l[0]^i[0]<<0,l[0]=Math.imul(l[0],q[0]),l[0]=le(l[0],15),l[0]=Math.imul(l[0],q[1]),s[0]=s[0]^l[0]}}(e,a),function(o,s){s[0]=s[0]^o.byteLength,s[1]=s[1]^o.byteLength,s[2]=s[2]^o.byteLength,s[3]=s[3]^o.byteLength,s[0]=s[0]+s[1]|0,s[0]=s[0]+s[2]|0,s[0]=s[0]+s[3]|0,s[1]=s[1]+s[0]|0,s[2]=s[2]+s[0]|0,s[3]=s[3]+s[0]|0,s[0]=dt(s[0]),s[1]=dt(s[1]),s[2]=dt(s[2]),s[3]=dt(s[3]),s[0]=s[0]+s[1]|0,s[0]=s[0]+s[2]|0,s[0]=s[0]+s[3]|0,s[1]=s[1]+s[0]|0,s[2]=s[2]+s[0]|0,s[3]=s[3]+s[0]|0}(e,a);var n=new Uint8Array(a.buffer);return Array.from(n).map(function(o){return o.toString(16).padStart(2,"0")}).join("")}function Ms(e,t){return new Promise(function(r){setTimeout(function(){return r(t)},e)})}function Ls(e,t,r){return Promise.all(e.map(function(a){return Promise.race([a,Ms(t,r)])}))}function Os(){return be(this,void 0,void 0,function(){var e,t,r,a,n;return ve(this,function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),e=Is(),t=Object.keys(e),[4,Ls(Object.values(e),(ye==null?void 0:ye.timeout)||1e3,As)];case 1:return r=o.sent(),a=r.filter(function(s){return s!==void 0}),n={},a.forEach(function(s,c){n[t[c]]=s}),[2,Mr(n,ye.exclude||[])];case 2:throw o.sent();case 3:return[2]}})})}function Mr(e,t){var r={},a=function(o){if(e.hasOwnProperty(o)){var s=e[o];if(typeof s!="object"||Array.isArray(s))t.includes(o)||(r[o]=s);else{var c=Mr(s,t.map(function(u){return u.startsWith(o+".")?u.slice(o.length+1):u}));Object.keys(c).length>0&&(r[o]=c)}}};for(var n in e)a(n);return r}function Fs(e){return be(this,void 0,void 0,function(){var t,r;return ve(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,Os()];case 1:return t=a.sent(),r=Ut(JSON.stringify(t)),[2,r.toString()];case 2:throw a.sent();case 3:return[2]}})})}function Ds(e){for(var t=0,r=0;r<e.length;++r)t+=Math.abs(e[r]);return t}function Lr(e,t,r){for(var a=[],n=0;n<e[0].data.length;n++){for(var o=[],s=0;s<e.length;s++)o.push(e[s].data[n]);a.push(Ns(o))}var c=new Uint8ClampedArray(a);return new ImageData(c,t,r)}function Ns(e){if(e.length===0)return 0;for(var t={},r=0,a=e;r<a.length;r++)t[o=a[r]]=(t[o]||0)+1;var n=e[0];for(var o in t)t[o]>t[n]&&(n=parseInt(o,10));return n}function Qe(){if(typeof navigator>"u")return{name:"unknown",version:"unknown"};for(var e=navigator.userAgent,t={Edg:"Edge",OPR:"Opera"},r=0,a=[/(?<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<a.length;r++){var n=a[r],o=e.match(n);if(o&&o.groups)return{name:t[o.groups.name]||o.groups.name,version:o.groups.version}}return{name:"unknown",version:"unknown"}}fe("audio",function(){return be(this,void 0,void 0,function(){return ve(this,function(e){return[2,new Promise(function(t,r){try{var a=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,5e3,44100),n=a.createBufferSource(),o=a.createOscillator();o.frequency.value=1e3;var s,c=a.createDynamicsCompressor();c.threshold.value=-50,c.knee.value=40,c.ratio.value=12,c.attack.value=0,c.release.value=.2,o.connect(c),c.connect(a.destination),o.start(),a.oncomplete=function(u){s=u.renderedBuffer.getChannelData(0),t({sampleHash:Ds(s),oscillator:o.type,maxChannels:a.destination.maxChannelCount,channelCountMode:n.channelCountMode})},a.startRendering()}catch(u){console.error("Error creating audio fingerprint:",u),r(u)}})]})})});var Us=Qe().name!=="SamsungBrowser"?1:3,Or=280,Fr=20;Qe().name!="Firefox"&&fe("canvas",function(){return document.createElement("canvas").getContext("2d"),new Promise(function(e){var t=Array.from({length:Us},function(){return function(){var r=document.createElement("canvas"),a=r.getContext("2d");if(!a)return new ImageData(1,1);r.width=Or,r.height=Fr;var n=a.createLinearGradient(0,0,r.width,r.height);n.addColorStop(0,"red"),n.addColorStop(.16666666666666666,"orange"),n.addColorStop(.3333333333333333,"yellow"),n.addColorStop(.5,"green"),n.addColorStop(.6666666666666666,"blue"),n.addColorStop(.8333333333333334,"indigo"),n.addColorStop(1,"violet"),a.fillStyle=n,a.fillRect(0,0,r.width,r.height);var o="Random Text WMwmil10Oo";a.font="23.123px Arial",a.fillStyle="black",a.fillText(o,-5,15),a.fillStyle="rgba(0, 0, 255, 0.5)",a.fillText(o,-3.3,17.7),a.beginPath(),a.moveTo(0,0),a.lineTo(2*r.width/7,r.height),a.strokeStyle="white",a.lineWidth=2,a.stroke();var s=a.getImageData(0,0,r.width,r.height);return s}()});e({commonImageDataHash:Ut(Lr(t,Or,Fr).data.toString()).toString()})})});var zt,zs=["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"],Hs=["monospace","sans-serif","serif"];function Dr(e,t){if(!e)throw new Error("Canvas context not supported");return e.font,e.font="72px ".concat(t),e.measureText("WwMmLli0Oo").width}function Bs(){var e,t=document.createElement("canvas"),r=(e=t.getContext("webgl"))!==null&&e!==void 0?e:t.getContext("experimental-webgl");if(r&&"getParameter"in r)try{var a=(r.getParameter(r.VENDOR)||"").toString(),n=(r.getParameter(r.RENDERER)||"").toString(),o={vendor:a,renderer:n,version:(r.getParameter(r.VERSION)||"").toString(),shadingLanguageVersion:(r.getParameter(r.SHADING_LANGUAGE_VERSION)||"").toString()};if(!n.length||!a.length){var s=r.getExtension("WEBGL_debug_renderer_info");if(s){var c=(r.getParameter(s.UNMASKED_VENDOR_WEBGL)||"").toString(),u=(r.getParameter(s.UNMASKED_RENDERER_WEBGL)||"").toString();c&&(o.vendorUnmasked=c),u&&(o.rendererUnmasked=u)}}return o}catch{}return"undefined"}function js(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}function Gs(e,t){var r={};return t.forEach(function(a){var n=function(o){if(o.length===0)return null;var s={};o.forEach(function(l){var i=String(l);s[i]=(s[i]||0)+1});var c=o[0],u=1;return Object.keys(s).forEach(function(l){s[l]>u&&(c=l,u=s[l])}),c}(e.map(function(o){return a in o?o[a]:void 0}).filter(function(o){return o!==void 0}));n&&(r[a]=n)}),r}function Ws(){var e=[],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"]};return Object.keys(t).forEach(function(r){t[r].forEach(function(a){matchMedia("(".concat(r,": ").concat(a,")")).matches&&e.push("".concat(r,": ").concat(a))})}),e}function Vs(){if(window.location.protocol==="https:"&&typeof window.ApplePaySession=="function")try{for(var e=window.ApplePaySession.supportsVersion,t=15;t>0;t--)if(e(t))return t}catch{return 0}return 0}Qe().name!="Firefox"&&fe("fonts",function(){var e=this;return new Promise(function(t,r){try{(function(a){var n;be(this,void 0,void 0,function(){var o,s,c;return ve(this,function(u){switch(u.label){case 0:return document.body?[3,2]:[4,(l=50,new Promise(function(p){return setTimeout(p,l,i)}))];case 1:return u.sent(),[3,0];case 2:if((o=document.createElement("iframe")).setAttribute("frameBorder","0"),(s=o.style).setProperty("position","fixed"),s.setProperty("display","block","important"),s.setProperty("visibility","visible"),s.setProperty("border","0"),s.setProperty("opacity","0"),o.src="about:blank",document.body.appendChild(o),!(c=o.contentDocument||((n=o.contentWindow)===null||n===void 0?void 0:n.document)))throw new Error("Iframe document is not accessible");return a({iframe:c}),setTimeout(function(){document.body.removeChild(o)},0),[2]}var l,i})})})(function(a){var n=a.iframe;return be(e,void 0,void 0,function(){var o,s,c,u;return ve(this,function(l){return o=n.createElement("canvas"),s=o.getContext("2d"),c=Hs.map(function(i){return Dr(s,i)}),u={},zs.forEach(function(i){var p=Dr(s,i);c.includes(p)||(u[i]=p)}),t(u),[2]})})})}catch{r({error:"unsupported"})}})}),fe("hardware",function(){return new Promise(function(e,t){var r=navigator.deviceMemory!==void 0?navigator.deviceMemory:0,a=window.performance&&window.performance.memory?window.performance.memory:0;e({videocard:Bs(),architecture:js(),deviceMemory:r.toString()||"undefined",jsHeapSizeLimit:a.jsHeapSizeLimit||0})})}),fe("locales",function(){return new Promise(function(e){e({languages:navigator.language,timezone:Intl.DateTimeFormat().resolvedOptions().timeZone})})}),fe("permissions",function(){return be(this,void 0,void 0,function(){var e;return ve(this,function(t){return zt=(ye==null?void 0:ye.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"],e=Array.from({length:(ye==null?void 0:ye.retries)||3},function(){return function(){return be(this,void 0,void 0,function(){var r,a,n,o,s;return ve(this,function(c){switch(c.label){case 0:r={},a=0,n=zt,c.label=1;case 1:if(!(a<n.length))return[3,6];o=n[a],c.label=2;case 2:return c.trys.push([2,4,,5]),[4,navigator.permissions.query({name:o})];case 3:return s=c.sent(),r[o]=s.state.toString(),[3,5];case 4:return c.sent(),[3,5];case 5:return a++,[3,1];case 6:return[2,r]}})})}()}),[2,Promise.all(e).then(function(r){return Gs(r,zt)})]})})}),fe("plugins",function(){var e=[];if(navigator.plugins)for(var t=0;t<navigator.plugins.length;t++){var r=navigator.plugins[t];e.push([r.name,r.filename,r.description].join("|"))}return new Promise(function(a){a({plugins:e})})}),fe("screen",function(){return new Promise(function(e){e({is_touchscreen:navigator.maxTouchPoints>0,maxTouchPoints:navigator.maxTouchPoints,colorDepth:screen.colorDepth,mediaMatches:Ws()})})}),fe("system",function(){return new Promise(function(e){var t=Qe();e({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:Vs()})})});var J,qs=Qe().name!=="SamsungBrowser"?1:3,w=null;fe("webgl",function(){return be(this,void 0,void 0,function(){var e;return ve(this,function(t){typeof document<"u"&&((J=document.createElement("canvas")).width=200,J.height=100,w=J.getContext("webgl"));try{if(!w)throw new Error("WebGL not supported");return e=Array.from({length:qs},function(){return function(){try{if(!w)throw new Error("WebGL not supported");var r=`
1
+ (function(O,W){typeof exports=="object"&&typeof module<"u"?W(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],W):(O=typeof globalThis<"u"?globalThis:O||self,W(O.SearchcraftVueSdk={},O.Vue))})(this,function(O,W){"use strict";var Hc=Object.defineProperty;var Bc=(O,W,Ne)=>W in O?Hc(O,W,{enumerable:!0,configurable:!0,writable:!0,value:Ne}):O[W]=Ne;var h=(O,W,Ne)=>Bc(O,typeof W!="symbol"?W+"":W,Ne);var Ys;var Ne=Object.defineProperty,_a=(e,t,r)=>t in e?Ne(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,F=(e,t,r)=>_a(e,typeof t!="symbol"?t+"":t,r);function ve(e,t,r,s){return new(r||(r=Promise))(function(n,o){function a(l){try{u(s.next(l))}catch(i){o(i)}}function c(l){try{u(s.throw(l))}catch(i){o(i)}}function u(l){var i;l.done?n(l.value):(i=l.value,i instanceof r?i:new r(function(p){p(i)})).then(a,c)}u((s=s.apply(e,[])).next())})}function be(e,t){var r,s,n,o,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(u){return function(l){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(a=0)),a;)try{if(r=1,s&&(n=2&i[0]?s.return:i[0]?s.throw||((n=s.return)&&n.call(s),0):s.next)&&!(n=n.call(s,i[1])).done)return n;switch(s=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,s=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(n=a.trys,!((n=n.length>0&&n[n.length-1])||i[0]!==6&&i[0]!==2)){a=0;continue}if(i[0]===3&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(i[0]===6&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(p){i=[6,p],s=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([u,l])}}}var ye={exclude:[]},Ir={},Aa={timeout:"true"},fe=function(e,t){typeof window<"u"&&(Ir[e]=t)},Ia=function(){return Object.fromEntries(Object.entries(Ir).filter(function(e){var t,r=e[0];return!(!((t=ye==null?void 0:ye.exclude)===null||t===void 0)&&t.includes(r))}).map(function(e){return[e[0],(0,e[1])()]}))};function ft(e){return e^=e>>>16,e=Math.imul(e,2246822507),e^=e>>>13,e=Math.imul(e,3266489909),(e^=e>>>16)>>>0}var Y=new Uint32Array([597399067,2869860233,951274213,2716044179]);function ue(e,t){return e<<t|e>>>32-t}function Ut(e,t){var r;if(t===void 0&&(t=0),t=t?0|t:0,typeof e=="string"&&(r=e,e=new TextEncoder().encode(r).buffer),!(e instanceof ArrayBuffer))throw new TypeError("Expected key to be ArrayBuffer or string");var s=new Uint32Array([t,t,t,t]);(function(o,a){for(var c=o.byteLength/16|0,u=new Uint32Array(o,0,4*c),l=0;l<c;l++){var i=u.subarray(4*l,4*(l+1));i[0]=Math.imul(i[0],Y[0]),i[0]=ue(i[0],15),i[0]=Math.imul(i[0],Y[1]),a[0]=a[0]^i[0],a[0]=ue(a[0],19),a[0]=a[0]+a[1],a[0]=Math.imul(a[0],5)+1444728091,i[1]=Math.imul(i[1],Y[1]),i[1]=ue(i[1],16),i[1]=Math.imul(i[1],Y[2]),a[1]=a[1]^i[1],a[1]=ue(a[1],17),a[1]=a[1]+a[2],a[1]=Math.imul(a[1],5)+197830471,i[2]=Math.imul(i[2],Y[2]),i[2]=ue(i[2],17),i[2]=Math.imul(i[2],Y[3]),a[2]=a[2]^i[2],a[2]=ue(a[2],15),a[2]=a[2]+a[3],a[2]=Math.imul(a[2],5)+2530024501,i[3]=Math.imul(i[3],Y[3]),i[3]=ue(i[3],18),i[3]=Math.imul(i[3],Y[0]),a[3]=a[3]^i[3],a[3]=ue(a[3],13),a[3]=a[3]+a[0],a[3]=Math.imul(a[3],5)+850148119}})(e,s),function(o,a){var c=o.byteLength/16|0,u=o.byteLength%16,l=new Uint32Array(4),i=new Uint8Array(o,16*c,u);switch(u){case 15:l[3]=l[3]^i[14]<<16;case 14:l[3]=l[3]^i[13]<<8;case 13:l[3]=l[3]^i[12]<<0,l[3]=Math.imul(l[3],Y[3]),l[3]=ue(l[3],18),l[3]=Math.imul(l[3],Y[0]),a[3]=a[3]^l[3];case 12:l[2]=l[2]^i[11]<<24;case 11:l[2]=l[2]^i[10]<<16;case 10:l[2]=l[2]^i[9]<<8;case 9:l[2]=l[2]^i[8]<<0,l[2]=Math.imul(l[2],Y[2]),l[2]=ue(l[2],17),l[2]=Math.imul(l[2],Y[3]),a[2]=a[2]^l[2];case 8:l[1]=l[1]^i[7]<<24;case 7:l[1]=l[1]^i[6]<<16;case 6:l[1]=l[1]^i[5]<<8;case 5:l[1]=l[1]^i[4]<<0,l[1]=Math.imul(l[1],Y[1]),l[1]=ue(l[1],16),l[1]=Math.imul(l[1],Y[2]),a[1]=a[1]^l[1];case 4:l[0]=l[0]^i[3]<<24;case 3:l[0]=l[0]^i[2]<<16;case 2:l[0]=l[0]^i[1]<<8;case 1:l[0]=l[0]^i[0]<<0,l[0]=Math.imul(l[0],Y[0]),l[0]=ue(l[0],15),l[0]=Math.imul(l[0],Y[1]),a[0]=a[0]^l[0]}}(e,s),function(o,a){a[0]=a[0]^o.byteLength,a[1]=a[1]^o.byteLength,a[2]=a[2]^o.byteLength,a[3]=a[3]^o.byteLength,a[0]=a[0]+a[1]|0,a[0]=a[0]+a[2]|0,a[0]=a[0]+a[3]|0,a[1]=a[1]+a[0]|0,a[2]=a[2]+a[0]|0,a[3]=a[3]+a[0]|0,a[0]=ft(a[0]),a[1]=ft(a[1]),a[2]=ft(a[2]),a[3]=ft(a[3]),a[0]=a[0]+a[1]|0,a[0]=a[0]+a[2]|0,a[0]=a[0]+a[3]|0,a[1]=a[1]+a[0]|0,a[2]=a[2]+a[0]|0,a[3]=a[3]+a[0]|0}(e,s);var n=new Uint8Array(s.buffer);return Array.from(n).map(function(o){return o.toString(16).padStart(2,"0")}).join("")}function Ma(e,t){return new Promise(function(r){setTimeout(function(){return r(t)},e)})}function La(e,t,r){return Promise.all(e.map(function(s){return Promise.race([s,Ma(t,r)])}))}function Oa(){return ve(this,void 0,void 0,function(){var e,t,r,s,n;return be(this,function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),e=Ia(),t=Object.keys(e),[4,La(Object.values(e),(ye==null?void 0:ye.timeout)||1e3,Aa)];case 1:return r=o.sent(),s=r.filter(function(a){return a!==void 0}),n={},s.forEach(function(a,c){n[t[c]]=a}),[2,Mr(n,ye.exclude||[])];case 2:throw o.sent();case 3:return[2]}})})}function Mr(e,t){var r={},s=function(o){if(e.hasOwnProperty(o)){var a=e[o];if(typeof a!="object"||Array.isArray(a))t.includes(o)||(r[o]=a);else{var c=Mr(a,t.map(function(u){return u.startsWith(o+".")?u.slice(o.length+1):u}));Object.keys(c).length>0&&(r[o]=c)}}};for(var n in e)s(n);return r}function Fa(e){return ve(this,void 0,void 0,function(){var t,r;return be(this,function(s){switch(s.label){case 0:return s.trys.push([0,2,,3]),[4,Oa()];case 1:return t=s.sent(),r=Ut(JSON.stringify(t)),[2,r.toString()];case 2:throw s.sent();case 3:return[2]}})})}function Da(e){for(var t=0,r=0;r<e.length;++r)t+=Math.abs(e[r]);return t}function Lr(e,t,r){for(var s=[],n=0;n<e[0].data.length;n++){for(var o=[],a=0;a<e.length;a++)o.push(e[a].data[n]);s.push(Na(o))}var c=new Uint8ClampedArray(s);return new ImageData(c,t,r)}function Na(e){if(e.length===0)return 0;for(var t={},r=0,s=e;r<s.length;r++)t[o=s[r]]=(t[o]||0)+1;var n=e[0];for(var o in t)t[o]>t[n]&&(n=parseInt(o,10));return n}function Xe(){if(typeof navigator>"u")return{name:"unknown",version:"unknown"};for(var e=navigator.userAgent,t={Edg:"Edge",OPR:"Opera"},r=0,s=[/(?<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<s.length;r++){var n=s[r],o=e.match(n);if(o&&o.groups)return{name:t[o.groups.name]||o.groups.name,version:o.groups.version}}return{name:"unknown",version:"unknown"}}fe("audio",function(){return ve(this,void 0,void 0,function(){return be(this,function(e){return[2,new Promise(function(t,r){try{var s=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,5e3,44100),n=s.createBufferSource(),o=s.createOscillator();o.frequency.value=1e3;var a,c=s.createDynamicsCompressor();c.threshold.value=-50,c.knee.value=40,c.ratio.value=12,c.attack.value=0,c.release.value=.2,o.connect(c),c.connect(s.destination),o.start(),s.oncomplete=function(u){a=u.renderedBuffer.getChannelData(0),t({sampleHash:Da(a),oscillator:o.type,maxChannels:s.destination.maxChannelCount,channelCountMode:n.channelCountMode})},s.startRendering()}catch(u){console.error("Error creating audio fingerprint:",u),r(u)}})]})})});var Ua=Xe().name!=="SamsungBrowser"?1:3,Or=280,Fr=20;Xe().name!="Firefox"&&fe("canvas",function(){return document.createElement("canvas").getContext("2d"),new Promise(function(e){var t=Array.from({length:Ua},function(){return function(){var r=document.createElement("canvas"),s=r.getContext("2d");if(!s)return new ImageData(1,1);r.width=Or,r.height=Fr;var n=s.createLinearGradient(0,0,r.width,r.height);n.addColorStop(0,"red"),n.addColorStop(.16666666666666666,"orange"),n.addColorStop(.3333333333333333,"yellow"),n.addColorStop(.5,"green"),n.addColorStop(.6666666666666666,"blue"),n.addColorStop(.8333333333333334,"indigo"),n.addColorStop(1,"violet"),s.fillStyle=n,s.fillRect(0,0,r.width,r.height);var o="Random Text WMwmil10Oo";s.font="23.123px Arial",s.fillStyle="black",s.fillText(o,-5,15),s.fillStyle="rgba(0, 0, 255, 0.5)",s.fillText(o,-3.3,17.7),s.beginPath(),s.moveTo(0,0),s.lineTo(2*r.width/7,r.height),s.strokeStyle="white",s.lineWidth=2,s.stroke();var a=s.getImageData(0,0,r.width,r.height);return a}()});e({commonImageDataHash:Ut(Lr(t,Or,Fr).data.toString()).toString()})})});var zt,za=["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"],Ha=["monospace","sans-serif","serif"];function Dr(e,t){if(!e)throw new Error("Canvas context not supported");return e.font,e.font="72px ".concat(t),e.measureText("WwMmLli0Oo").width}function Ba(){var e,t=document.createElement("canvas"),r=(e=t.getContext("webgl"))!==null&&e!==void 0?e:t.getContext("experimental-webgl");if(r&&"getParameter"in r)try{var s=(r.getParameter(r.VENDOR)||"").toString(),n=(r.getParameter(r.RENDERER)||"").toString(),o={vendor:s,renderer:n,version:(r.getParameter(r.VERSION)||"").toString(),shadingLanguageVersion:(r.getParameter(r.SHADING_LANGUAGE_VERSION)||"").toString()};if(!n.length||!s.length){var a=r.getExtension("WEBGL_debug_renderer_info");if(a){var c=(r.getParameter(a.UNMASKED_VENDOR_WEBGL)||"").toString(),u=(r.getParameter(a.UNMASKED_RENDERER_WEBGL)||"").toString();c&&(o.vendorUnmasked=c),u&&(o.rendererUnmasked=u)}}return o}catch{}return"undefined"}function ja(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}function Va(e,t){var r={};return t.forEach(function(s){var n=function(o){if(o.length===0)return null;var a={};o.forEach(function(l){var i=String(l);a[i]=(a[i]||0)+1});var c=o[0],u=1;return Object.keys(a).forEach(function(l){a[l]>u&&(c=l,u=a[l])}),c}(e.map(function(o){return s in o?o[s]:void 0}).filter(function(o){return o!==void 0}));n&&(r[s]=n)}),r}function Wa(){var e=[],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"]};return Object.keys(t).forEach(function(r){t[r].forEach(function(s){matchMedia("(".concat(r,": ").concat(s,")")).matches&&e.push("".concat(r,": ").concat(s))})}),e}function Ga(){if(window.location.protocol==="https:"&&typeof window.ApplePaySession=="function")try{for(var e=window.ApplePaySession.supportsVersion,t=15;t>0;t--)if(e(t))return t}catch{return 0}return 0}Xe().name!="Firefox"&&fe("fonts",function(){var e=this;return new Promise(function(t,r){try{(function(s){var n;ve(this,void 0,void 0,function(){var o,a,c;return be(this,function(u){switch(u.label){case 0:return document.body?[3,2]:[4,(l=50,new Promise(function(p){return setTimeout(p,l,i)}))];case 1:return u.sent(),[3,0];case 2:if((o=document.createElement("iframe")).setAttribute("frameBorder","0"),(a=o.style).setProperty("position","fixed"),a.setProperty("display","block","important"),a.setProperty("visibility","visible"),a.setProperty("border","0"),a.setProperty("opacity","0"),o.src="about:blank",document.body.appendChild(o),!(c=o.contentDocument||((n=o.contentWindow)===null||n===void 0?void 0:n.document)))throw new Error("Iframe document is not accessible");return s({iframe:c}),setTimeout(function(){document.body.removeChild(o)},0),[2]}var l,i})})})(function(s){var n=s.iframe;return ve(e,void 0,void 0,function(){var o,a,c,u;return be(this,function(l){return o=n.createElement("canvas"),a=o.getContext("2d"),c=Ha.map(function(i){return Dr(a,i)}),u={},za.forEach(function(i){var p=Dr(a,i);c.includes(p)||(u[i]=p)}),t(u),[2]})})})}catch{r({error:"unsupported"})}})}),fe("hardware",function(){return new Promise(function(e,t){var r=navigator.deviceMemory!==void 0?navigator.deviceMemory:0,s=window.performance&&window.performance.memory?window.performance.memory:0;e({videocard:Ba(),architecture:ja(),deviceMemory:r.toString()||"undefined",jsHeapSizeLimit:s.jsHeapSizeLimit||0})})}),fe("locales",function(){return new Promise(function(e){e({languages:navigator.language,timezone:Intl.DateTimeFormat().resolvedOptions().timeZone})})}),fe("permissions",function(){return ve(this,void 0,void 0,function(){var e;return be(this,function(t){return zt=(ye==null?void 0:ye.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"],e=Array.from({length:(ye==null?void 0:ye.retries)||3},function(){return function(){return ve(this,void 0,void 0,function(){var r,s,n,o,a;return be(this,function(c){switch(c.label){case 0:r={},s=0,n=zt,c.label=1;case 1:if(!(s<n.length))return[3,6];o=n[s],c.label=2;case 2:return c.trys.push([2,4,,5]),[4,navigator.permissions.query({name:o})];case 3:return a=c.sent(),r[o]=a.state.toString(),[3,5];case 4:return c.sent(),[3,5];case 5:return s++,[3,1];case 6:return[2,r]}})})}()}),[2,Promise.all(e).then(function(r){return Va(r,zt)})]})})}),fe("plugins",function(){var e=[];if(navigator.plugins)for(var t=0;t<navigator.plugins.length;t++){var r=navigator.plugins[t];e.push([r.name,r.filename,r.description].join("|"))}return new Promise(function(s){s({plugins:e})})}),fe("screen",function(){return new Promise(function(e){e({is_touchscreen:navigator.maxTouchPoints>0,maxTouchPoints:navigator.maxTouchPoints,colorDepth:screen.colorDepth,mediaMatches:Wa()})})}),fe("system",function(){return new Promise(function(e){var t=Xe();e({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:Ga()})})});var Z,qa=Xe().name!=="SamsungBrowser"?1:3,R=null;fe("webgl",function(){return ve(this,void 0,void 0,function(){var e;return be(this,function(t){typeof document<"u"&&((Z=document.createElement("canvas")).width=200,Z.height=100,R=Z.getContext("webgl"));try{if(!R)throw new Error("WebGL not supported");return e=Array.from({length:qa},function(){return function(){try{if(!R)throw new Error("WebGL not supported");var r=`
2
2
  attribute vec2 position;
3
3
  void main() {
4
4
  gl_Position = vec4(position, 0.0, 1.0);
5
5
  }
6
- `,a=`
6
+ `,s=`
7
7
  precision mediump float;
8
8
  void main() {
9
9
  gl_FragColor = vec4(0.812, 0.195, 0.553, 0.921); // Set line color
10
10
  }
11
- `,n=w.createShader(w.VERTEX_SHADER),o=w.createShader(w.FRAGMENT_SHADER);if(!n||!o)throw new Error("Failed to create shaders");if(w.shaderSource(n,r),w.shaderSource(o,a),w.compileShader(n),!w.getShaderParameter(n,w.COMPILE_STATUS))throw new Error("Vertex shader compilation failed: "+w.getShaderInfoLog(n));if(w.compileShader(o),!w.getShaderParameter(o,w.COMPILE_STATUS))throw new Error("Fragment shader compilation failed: "+w.getShaderInfoLog(o));var s=w.createProgram();if(!s)throw new Error("Failed to create shader program");if(w.attachShader(s,n),w.attachShader(s,o),w.linkProgram(s),!w.getProgramParameter(s,w.LINK_STATUS))throw new Error("Shader program linking failed: "+w.getProgramInfoLog(s));w.useProgram(s);for(var c=137,u=new Float32Array(4*c),l=2*Math.PI/c,i=0;i<c;i++){var p=i*l;u[4*i]=0,u[4*i+1]=0,u[4*i+2]=Math.cos(p)*(J.width/2),u[4*i+3]=Math.sin(p)*(J.height/2)}var g=w.createBuffer();w.bindBuffer(w.ARRAY_BUFFER,g),w.bufferData(w.ARRAY_BUFFER,u,w.STATIC_DRAW);var S=w.getAttribLocation(s,"position");w.enableVertexAttribArray(S),w.vertexAttribPointer(S,2,w.FLOAT,!1,0,0),w.viewport(0,0,J.width,J.height),w.clearColor(0,0,0,1),w.clear(w.COLOR_BUFFER_BIT),w.drawArrays(w.LINES,0,2*c);var P=new Uint8ClampedArray(J.width*J.height*4);return w.readPixels(0,0,J.width,J.height,w.RGBA,w.UNSIGNED_BYTE,P),new ImageData(P,J.width,J.height)}catch{return new ImageData(1,1)}finally{w&&(w.bindBuffer(w.ARRAY_BUFFER,null),w.useProgram(null),w.viewport(0,0,w.drawingBufferWidth,w.drawingBufferHeight),w.clearColor(0,0,0,0))}}()}),[2,{commonImageHash:Ut(Lr(e,J.width,J.height).data.toString()).toString()}]}catch{return[2,{webgl:"unsupported"}]}return[2]})})});var $e=function(e,t,r,a){for(var n=(r-t)/a,o=0,s=0;s<a;s++)o+=e(t+(s+.5)*n);return o*n};fe("math",function(){return be(void 0,void 0,void 0,function(){return ve(this,function(e){return[2,{acos:Math.acos(.5),asin:$e(Math.asin,-1,1,97),atan:$e(Math.atan,-1,1,97),cos:$e(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:$e(Math.sin,-Math.PI,Math.PI,97),sinh:$e(Math.sinh,-9/7,7/9,97),sqrt:Math.sqrt(2),tan:$e(Math.tan,0,2*Math.PI,97),tanh:$e(Math.tanh,-9/7,7/9,97)}]})})});const Ys="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";let pt=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+=Ys[r[e]&63];return t};class Ht{constructor(t){F(this,"config"),this.config=t}async getAdsForSearchParams(t){return[]}}class Ks extends Ht{async getAdsForSearchParams(t){if(!this.config.admSub)return console.error("No admSub specified in config."),[];const r=`https://demofeed.is.ampfeed.com/is?${new URLSearchParams({partner:"demofeed",sub1:this.config.admSub,qt:t.searchTerm,v:"2.0",rfr:"searchcraft.io","results-ta":`${this.config.admTextAdQuantity||0}`,"results-pa":`${this.config.admProductAdQuantity||0}`}).toString()}`,a=await(await fetch(r,{method:"GET"})).json(),n=a.product_ads.map(s=>({id:pt(),adSource:"adMarketplace",admAdType:"adm-product-ad",admAd:s})),o=a.text_ads.map(s=>({id:pt(),adSource:"adMarketplace",admAdType:"adm-text-ad",admAd:s}));return n.concat(o)}}class Xs extends Ht{async getAdsForSearchParams(t){return[]}}class Qs extends Ht{async getAdsForSearchParams(t){return[]}}const Js=500;class Zs{constructor(t,r,a){F(this,"measureRequestTimeout"),F(this,"measureRequestsBatched",[]),F(this,"config"),F(this,"sdkInfo"),F(this,"userId"),F(this,"sessionId"),F(this,"sendMeasureEvent",(n,o={},s={})=>{const c={event_name:n,properties:{searchcraft_index_names:this.config.index,session_id:this.sessionId,...o},user:{...this.measureRequestUser,...s}};this.measureRequestsBatched.push(c),clearTimeout(this.measureRequestTimeout),this.measureRequestTimeout=setTimeout(async()=>{const u=JSON.stringify({items:this.measureRequestsBatched}),l=`${this.baseMeasureUrl}/batch`;try{const i=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json",Authorization:this.config.readKey,"X-Sc-User-Id":this.userId},body:u,keepalive:!0});if(!i.ok)throw new Error(`Failed to send request: ${i.status} ${i.statusText}`);this.measureRequestsBatched=[];return}catch(i){throw console.error("Error sending MeasureRequest:",i),i}},Js)}),this.config=t,this.sdkInfo=r,this.userId=a,this.sessionId=pt(),this.sendMeasureEvent("sdk_initialized")}get baseMeasureUrl(){return`${this.config.endpointURL}/measure`}get measureRequestUser(){return{user_id:this.userId,locale:navigator.language||"en-US",os:navigator.userAgent.includes("Windows")?"Windows":navigator.userAgent.includes("Mac")?"Mac":navigator.userAgent.includes("Linux")?"Linux":"Unknown",platform:navigator.platform||"Unknown",sdk_name:this.sdkInfo.sdkName,sdk_version:this.sdkInfo.sdkVersion,user_agent:navigator.userAgent||"Unknown"}}}function en(e){const t=[];let r="should";return e.facetPathsForIndexFields&&Object.keys(e.facetPathsForIndexFields).forEach(a=>{var n;const o=(n=e.facetPathsForIndexFields)==null?void 0:n[a];o&&(r="must",t.push({occur:r,exact:{ctx:o.value}}))}),e.rangeValueForIndexFields&&Object.keys(e.rangeValueForIndexFields).forEach(a=>{var n;const o=(n=e.rangeValueForIndexFields)==null?void 0:n[a];o&&(r="must",t.push({occur:r,exact:{ctx:o.value}}))}),e.sort==="desc"?e.order_by="date_published":e.order_by="",t.push({occur:r,[e.mode]:{ctx:e.searchTerm}}),t}const tn=e=>e.endsWith("/")?e.slice(0,-1):e,rn=e=>{let t="";if(t=e.trim(),t=t.replace(/[‘’“”]/g,r=>({"‘":"'","’":"'","“":'"',"”":'"'})[r]||r),(t.match(/"/g)||[]).length%2!==0)throw new Error("The search term contains an uneven number of quote characters.");return t};class an{constructor(t,r,a){F(this,"config"),F(this,"userId"),F(this,"parent"),F(this,"getSearchResponse",async n=>{var o,s;const c=rn(n.searchTerm);(o=this.parent.measureClient)==null||o.sendMeasureEvent("search_requested",{search_term:c}),this.parent.emitEvent("query_submitted",{name:"query_submitted",data:{searchTerm:c}});try{const u={query:en(n),offset:n.offset||0,limit:n.limit||this.config.searchResultsPerPage||20};n.order_by&&(u.order_by=n.order_by,u.sort=n.sort==="desc"||n.sort==="asc"?n.sort:"asc");const l={method:"POST",headers:{Authorization:this.config.readKey,"Content-Type":"application/json","X-Sc-User-Id":this.userId},body:JSON.stringify(u)},i=await fetch(this.baseSearchUrl,l);if(!i.ok)throw new Error(`Error: ${i.statusText} (Status: ${i.status})`);const p=await i.json();return(s=this.parent.measureClient)==null||s.sendMeasureEvent("search_response_received",{search_term:c,number_of_documents:p.data.count}),p}catch(u){throw console.error("Error parsing response:",u),u}}),this.parent=t,this.config=r,this.userId=a}get baseSearchUrl(){return`${this.config.endpointURL}/index/${this.config.index.join(",")}/search`}}class sn{constructor(t,r){if(F(this,"config"),F(this,"measureClient"),F(this,"searchClient"),F(this,"adClient"),F(this,"userId"),F(this,"requestTimeout"),F(this,"subscriptionEvents",{}),F(this,"getItems",(a,n,o)=>{const s=async()=>{(async()=>{var c,u;const l=await((c=this==null?void 0:this.searchClient)==null?void 0:c.getSearchResponse(a));if(!l)throw new Error("Search client was not initialized.");const i=(u=l.data.hits||[])==null?void 0:u.map(p=>p.doc).filter(p=>!!p).map(p=>({type:"SearchDocument",id:pt(),document:p}));i.length===0&&this.emitEvent("no_results_returned",{name:"no_results_returned"}),n(l,i)})(),(async()=>{if(this.adClient){const c=await this.adClient.getAdsForSearchParams(a);o(c)}})()};clearTimeout(this.requestTimeout),this.config.searchDebounceDelay?this.requestTimeout=setTimeout(s,this.config.searchDebounceDelay):s()}),!t.endpointURL||!t.index||!t.readKey)throw new Error("Endpoint URL, Index value(s), and Read Key must be provided");this.config={...t,endpointURL:tn(t.endpointURL)},this.userId="",this.initClients(this.config,r),this.initInputForms(),this.startObservingMutations()}initInputForms(){const t=document.querySelectorAll("searchcraft-input-form");setTimeout(()=>{t.forEach(r=>{r.core=this})},40)}startObservingMutations(){new MutationObserver((t,r)=>{let a=!1;for(const n of t)n.type==="childList"&&n.addedNodes.forEach(o=>{o.nodeType===1&&o.className.toLowerCase()==="searchcraft-input-form"&&(a=!0)});a&&this.initInputForms()}).observe(document.body,{childList:!0,subtree:!0})}initClients(t,r){setTimeout(async()=>{let a=this.config.userId;switch(a||(a=await Fs()),this.measureClient=new Zs(t,r,a),this.searchClient=new an(this,t,a),t.adSource){case"adMarketplace":this.adClient=new Ks(t);break;case"Nativo":this.adClient=new Qs(t);break;case"Custom":this.adClient=new Xs(t);break}},300)}emitEvent(t,r){var a;(a=this.subscriptionEvents[t])==null||a.forEach(n=>{n(r)})}subscribe(t,r){return this.subscriptionEvents[t]||(this.subscriptionEvents[t]=[]),this.subscriptionEvents[t].push(r),()=>{this.subscriptionEvents[t]=this.subscriptionEvents[t].filter(a=>a!==r)}}}const nn="searchcraft-javascript-sdk",Ue={allRenderFn:!0,appendChildSlotFix:!1,asyncLoading:!0,asyncQueue:!1,attachStyles:!0,cloneNodeFix:!1,cmpDidLoad:!0,cmpDidRender:!1,cmpDidUnload:!1,cmpDidUpdate:!1,cmpShouldUpdate:!1,cmpWillLoad:!1,cmpWillRender:!1,cmpWillUpdate:!1,connectedCallback:!0,constructableCSS:!0,cssAnnotations:!0,devTools:!1,disconnectedCallback:!0,element:!1,event:!0,experimentalScopedSlotChanges:!1,experimentalSlotFixes:!1,formAssociated:!1,hasRenderFn:!0,hostListener:!1,hostListenerTarget:!1,hostListenerTargetBody:!1,hostListenerTargetDocument:!1,hostListenerTargetParent:!1,hostListenerTargetWindow:!1,hotModuleReplacement:!1,hydrateClientSide:!1,hydrateServerSide:!1,hydratedAttribute:!1,hydratedClass:!0,hydratedSelectorName:"hydrated",invisiblePrehydration:!0,isDebug:!1,isDev:!1,isTesting:!1,lazyLoad:!1,lifecycle:!0,lifecycleDOMEvents:!1,member:!0,method:!1,mode:!1,modernPropertyDecls:!0,observeAttribute:!0,profile:!1,prop:!0,propBoolean:!0,propMutable:!1,propNumber:!0,propString:!0,reflect:!1,scoped:!1,scopedSlotTextContentFix:!1,scriptDataOpts:!1,shadowDelegatesFocus:!1,shadowDom:!1,slot:!0,slotChildNodesFix:!1,slotRelocation:!0,state:!0,style:!1,svg:!0,taskQueue:!0,updatable:!0,vdomAttribute:!0,vdomClass:!0,vdomFunctional:!0,vdomKey:!0,vdomListener:!0,vdomPropOrAttr:!0,vdomRef:!1,vdomRender:!0,vdomStyle:!0,vdomText:!0,vdomXlink:!1,watchCallback:!0};var on=Object.defineProperty,cn=(e,t)=>{for(var r in t)on(e,r,{get:t[r],enumerable:!0})},ln="http://www.w3.org/2000/svg",un="http://www.w3.org/1999/xhtml",hn=(e,t)=>{var r;const a=t.$cmpMeta$;Object.entries((r=a.$members$)!=null?r:{}).map(([o,[s]])=>{if(s&31||s&32){const c=e[o],u=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),o);Object.defineProperty(e,o,{get(){return u.get.call(this)},set(l){u.set.call(this,l)},configurable:!0,enumerable:!0}),e[o]=t.$instanceValues$.has(o)?t.$instanceValues$.get(o):c}})},Bt=new WeakMap,fn=e=>Bt.delete(e),Te=e=>Bt.get(e),dn=(e,t)=>{const r={$flags$:0,$hostElement$:e,$cmpMeta$:t,$instanceValues$:new Map};r.$onReadyPromise$=new Promise(n=>r.$onReadyResolve$=n),e["s-p"]=[],e["s-rc"]=[];const a=Bt.set(e,r);return hn(e,r),a},Nr=(e,t)=>t in e,mt=(e,t)=>(0,console.error)(e,t),gt=typeof window<"u"?window:{},ze=gt.document||{head:{}},D=gt.HTMLElement||class{},se={$flags$:0,$resourcesUrl$:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,r,a)=>e.addEventListener(t,r,a),rel:(e,t,r,a)=>e.removeEventListener(t,r,a),ce:(e,t)=>new CustomEvent(e,t)},pn=Ue.shadowDom,mn=e=>Promise.resolve(e),jt=!1,Ur=[],zr=[],gn=(e,t)=>r=>{e.push(r),jt||(jt=!0,se.$flags$&4?Wt(Gt):se.raf(Gt))},Hr=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(r){mt(r)}e.length=0},Gt=()=>{Hr(Ur),Hr(zr),(jt=Ur.length>0)&&se.raf(Gt)},Wt=e=>mn().then(e),bn=gn(zr),Vt=e=>(e=typeof e,e==="object"||e==="function"),vn={};cn(vn,{err:()=>Br,map:()=>yn,ok:()=>qt,unwrap:()=>Sn,unwrapErr:()=>wn});var qt=e=>({isOk:!0,isErr:!1,value:e}),Br=e=>({isOk:!1,isErr:!0,value:e});function yn(e,t){if(e.isOk){const r=t(e.value);return r instanceof Promise?r.then(a=>qt(a)):qt(r)}if(e.isErr){const r=e.value;return Br(r)}throw"should never get here"}var Sn=e=>{if(e.isOk)return e.value;throw e.value},wn=e=>{if(e.isErr)return e.value;throw e.value},jr=e=>{const t=e.__childNodes||e.childNodes;e.tagName&&e.tagName.includes("-")&&e["s-cr"]&&e.tagName!=="SLOT-FB"&&Gr(t,e.tagName).forEach(r=>{var a;r.nodeType===1&&r.tagName==="SLOT-FB"&&((a=Rn(r,r["s-sn"],!1))!=null&&a.length?r.hidden=!0:r.hidden=!1)});for(const r of t)r.nodeType===1&&(r.__childNodes||r.childNodes).length&&jr(r)};function Gr(e,t,r){let a=0,n=[],o;for(;a<e.length;a++)o=e[a],o["s-sr"]&&o["s-hn"]===t&&r===void 0&&n.push(o),n=[...n,...Gr(o.childNodes,t,r)];return n}var Rn=(e,t,r=!0)=>{const a=[];for((r&&e["s-sr"]||!e["s-sr"])&&a.push(e);(e=e.nextSibling)&&e["s-sn"]===t;)a.push(e);return a},Wr=(e,t)=>e.nodeType===1?e.getAttribute("slot")===null&&t===""||e.getAttribute("slot")===t:e["s-sn"]===t?!0:t==="",Je=(e,t="")=>()=>{},d=(e,t,...r)=>{let a=null,n=null,o=null,s=!1,c=!1;const u=[],l=p=>{for(let g=0;g<p.length;g++)a=p[g],Array.isArray(a)?l(a):a!=null&&typeof a!="boolean"&&((s=typeof e!="function"&&!Vt(a))&&(a=String(a)),s&&c?u[u.length-1].$text$+=a:u.push(s?bt(null,a):a),c=s)};if(l(r),t){t.key&&(n=t.key),t.name&&(o=t.name);{const p=t.className||t.class;p&&(t.class=typeof p!="object"?p:Object.keys(p).filter(g=>p[g]).join(" "))}}if(typeof e=="function")return e(t===null?{}:t,u,kn);const i=bt(e,null);return i.$attrs$=t,u.length>0&&(i.$children$=u),i.$key$=n,i.$name$=o,i},bt=(e,t)=>{const r={$flags$:0,$tag$:e,$text$:t,$elm$:null,$children$:null};return r.$attrs$=null,r.$key$=null,r.$name$=null,r},En={},Pn=e=>e&&e.$tag$===En,kn={forEach:(e,t)=>e.map(Vr).forEach(t),map:(e,t)=>e.map(Vr).map(t).map(Tn)},Vr=e=>({vattrs:e.$attrs$,vchildren:e.$children$,vkey:e.$key$,vname:e.$name$,vtag:e.$tag$,vtext:e.$text$}),Tn=e=>{if(typeof e.vtag=="function"){const r={...e.vattrs};return e.vkey&&(r.key=e.vkey),e.vname&&(r.name=e.vname),d(e.vtag,r,...e.vchildren||[])}const t=bt(e.vtag,e.vtext);return t.$attrs$=e.vattrs,t.$children$=e.vchildren,t.$key$=e.vkey,t.$name$=e.vname,t},qr=(e,t)=>e!=null&&!Vt(e)?t&4?e==="false"?!1:e===""||!!e:t&2?parseFloat(e):t&1?String(e):e:e,Cn=e=>e,Ce=(e,t,r)=>{const a=Cn(e);return{emit:n=>Yr(a,t,{bubbles:!0,composed:!0,cancelable:!0,detail:n})}},Yr=(e,t,r)=>{const a=se.ce(t,r);return e.dispatchEvent(a),a},vt=new WeakMap,Kr=(e,t,r,a,n,o)=>{if(r!==a){let s=Nr(e,t),c=t.toLowerCase();if(t==="class"){const u=e.classList,l=Xr(r);let i=Xr(a);e["s-si"]?(i.push(e["s-si"]),l.forEach(p=>{p.startsWith(e["s-si"])&&i.push(p)}),i=[...new Set(i)],u.add(...i),delete e["s-si"]):(u.remove(...l.filter(p=>p&&!i.includes(p))),u.add(...i.filter(p=>p&&!l.includes(p))))}else if(t==="style"){for(const u in r)(!a||a[u]==null)&&(u.includes("-")?e.style.removeProperty(u):e.style[u]="");for(const u in a)(!r||a[u]!==r[u])&&(u.includes("-")?e.style.setProperty(u,a[u]):e.style[u]=a[u])}else if(t!=="key")if(!e.__lookupSetter__(t)&&t[0]==="o"&&t[1]==="n"){if(t[2]==="-"?t=t.slice(3):Nr(gt,c)?t=c.slice(2):t=c[2]+t.slice(3),r||a){const u=t.endsWith(Qr);t=t.replace($n,""),r&&se.rel(e,t,r,u),a&&se.ael(e,t,a,u)}}else{const u=Vt(a);if((s||u&&a!==null)&&!n)try{if(e.tagName.includes("-"))e[t]!==a&&(e[t]=a);else{const l=a??"";t==="list"?s=!1:(r==null||e[t]!=l)&&(typeof e.__lookupSetter__(t)=="function"?e[t]=l:e.setAttribute(t,l))}}catch{}a==null||a===!1?(a!==!1||e.getAttribute(t)==="")&&e.removeAttribute(t):(!s||o&4||n)&&!u&&(a=a===!0?"":a,e.setAttribute(t,a))}}},xn=/\s/,Xr=e=>(typeof e=="object"&&"baseVal"in e&&(e=e.baseVal),e?e.split(xn):[]),Qr="Capture",$n=new RegExp(Qr+"$"),Jr=(e,t,r)=>{const a=t.$elm$.nodeType===11&&t.$elm$.host?t.$elm$.host:t.$elm$,n=e&&e.$attrs$||{},o=t.$attrs$||{};for(const s of Zr(Object.keys(n)))s in o||Kr(a,s,n[s],void 0,r,t.$flags$);for(const s of Zr(Object.keys(o)))Kr(a,s,n[s],o[s],r,t.$flags$)};function Zr(e){return e.includes("ref")?[...e.filter(t=>t!=="ref"),"ref"]:e}var Yt,Kt,yt=!1,St=!1,Xt=!1,ie=!1,wt=(e,t,r)=>{var a;const n=t.$children$[r];let o=0,s,c,u;if(yt||(Xt=!0,n.$tag$==="slot"&&(n.$flags$|=n.$children$?2:1)),n.$text$!==null)s=n.$elm$=ze.createTextNode(n.$text$);else if(n.$flags$&1)s=n.$elm$=ze.createTextNode("");else{if(ie||(ie=n.$tag$==="svg"),s=n.$elm$=ze.createElementNS(ie?ln:un,!yt&&Ue.slotRelocation&&n.$flags$&2?"slot-fb":n.$tag$),ie&&n.$tag$==="foreignObject"&&(ie=!1),Jr(null,n,ie),n.$children$)for(o=0;o<n.$children$.length;++o)c=wt(e,n,o),c&&s.appendChild(c);n.$tag$==="svg"?ie=!1:s.tagName==="foreignObject"&&(ie=!0)}return s["s-hn"]=Kt,n.$flags$&3&&(s["s-sr"]=!0,s["s-cr"]=Yt,s["s-sn"]=n.$name$||"",s["s-rf"]=(a=n.$attrs$)==null?void 0:a.ref,u=e&&e.$children$&&e.$children$[r],u&&u.$tag$===n.$tag$&&e.$elm$&&Ze(e.$elm$,!1)),s},Ze=(e,t)=>{se.$flags$|=1;const r=Array.from(e.__childNodes||e.childNodes);e["s-sr"]&&Ue.experimentalSlotFixes;for(let a=r.length-1;a>=0;a--){const n=r[a];n["s-hn"]!==Kt&&n["s-ol"]&&(xe(et(n).parentNode,n,et(n)),n["s-ol"].remove(),n["s-ol"]=void 0,n["s-sh"]=void 0,Xt=!0),t&&Ze(n,t)}se.$flags$&=-2},ea=(e,t,r,a,n,o)=>{let s=e["s-cr"]&&e["s-cr"].parentNode||e,c;for(;n<=o;++n)a[n]&&(c=wt(null,r,n),c&&(a[n].$elm$=c,xe(s,c,et(t))))},ta=(e,t,r)=>{for(let a=t;a<=r;++a){const n=e[a];if(n){const o=n.$elm$;o&&(St=!0,o["s-ol"]?o["s-ol"].remove():Ze(o,!0),o.remove())}}},_n=(e,t,r,a,n=!1)=>{let o=0,s=0,c=0,u=0,l=t.length-1,i=t[0],p=t[l],g=a.length-1,S=a[0],P=a[g],U,pe;for(;o<=l&&s<=g;)if(i==null)i=t[++o];else if(p==null)p=t[--l];else if(S==null)S=a[++s];else if(P==null)P=a[--g];else if(Rt(i,S,n))He(i,S,n),i=t[++o],S=a[++s];else if(Rt(p,P,n))He(p,P,n),p=t[--l],P=a[--g];else if(Rt(i,P,n))(i.$tag$==="slot"||P.$tag$==="slot")&&Ze(i.$elm$.parentNode,!1),He(i,P,n),xe(e,i.$elm$,p.$elm$.nextSibling),i=t[++o],P=a[--g];else if(Rt(p,S,n))(i.$tag$==="slot"||P.$tag$==="slot")&&Ze(p.$elm$.parentNode,!1),He(p,S,n),xe(e,p.$elm$,i.$elm$),p=t[--l],S=a[++s];else{for(c=-1,u=o;u<=l;++u)if(t[u]&&t[u].$key$!==null&&t[u].$key$===S.$key$){c=u;break}c>=0?(pe=t[c],pe.$tag$!==S.$tag$?U=wt(t&&t[s],r,c):(He(pe,S,n),t[c]=void 0,U=pe.$elm$),S=a[++s]):(U=wt(t&&t[s],r,s),S=a[++s]),U&&xe(et(i.$elm$).parentNode,U,et(i.$elm$))}o>l?ea(e,a[g+1]==null?null:a[g+1].$elm$,r,a,s,g):s>g&&ta(t,o,l)},Rt=(e,t,r=!1)=>e.$tag$===t.$tag$?e.$tag$==="slot"?e.$name$===t.$name$:r?(r&&!e.$key$&&t.$key$&&(e.$key$=t.$key$),!0):e.$key$===t.$key$:!1,et=e=>e&&e["s-ol"]||e,He=(e,t,r=!1)=>{const a=t.$elm$=e.$elm$,n=e.$children$,o=t.$children$,s=t.$tag$,c=t.$text$;let u;c===null?(ie=s==="svg"?!0:s==="foreignObject"?!1:ie,s==="slot"&&!yt||Jr(e,t,ie),n!==null&&o!==null?_n(a,n,t,o,r):o!==null?(e.$text$!==null&&(a.textContent=""),ea(a,null,t,o,0,o.length-1)):!r&&Ue.updatable&&n!==null&&ta(n,0,n.length-1),ie&&s==="svg"&&(ie=!1)):(u=a["s-cr"])?u.parentNode.textContent=c:e.$text$!==c&&(a.data=c)},Se=[],ra=e=>{let t,r,a;const n=e.__childNodes||e.childNodes;for(const o of n){if(o["s-sr"]&&(t=o["s-cr"])&&t.parentNode){r=t.parentNode.__childNodes||t.parentNode.childNodes;const s=o["s-sn"];for(a=r.length-1;a>=0;a--)if(t=r[a],!t["s-cn"]&&!t["s-nr"]&&t["s-hn"]!==o["s-hn"])if(Wr(t,s)){let c=Se.find(u=>u.$nodeToRelocate$===t);St=!0,t["s-sn"]=t["s-sn"]||s,c?(c.$nodeToRelocate$["s-sh"]=o["s-hn"],c.$slotRefNode$=o):(t["s-sh"]=o["s-hn"],Se.push({$slotRefNode$:o,$nodeToRelocate$:t})),t["s-sr"]&&Se.map(u=>{Wr(u.$nodeToRelocate$,t["s-sn"])&&(c=Se.find(l=>l.$nodeToRelocate$===t),c&&!u.$slotRefNode$&&(u.$slotRefNode$=c.$slotRefNode$))})}else Se.some(c=>c.$nodeToRelocate$===t)||Se.push({$nodeToRelocate$:t})}o.nodeType===1&&ra(o)}},xe=(e,t,r)=>e==null?void 0:e.insertBefore(t,r),An=(e,t,r=!1)=>{var a,n,o,s;const c=e.$hostElement$,u=e.$vnode$||bt(null,null),l=Pn(t)?t:d(null,null,t);if(Kt=c.tagName,r&&l.$attrs$)for(const i of Object.keys(l.$attrs$))c.hasAttribute(i)&&!["key","ref","style","class"].includes(i)&&(l.$attrs$[i]=c[i]);l.$tag$=null,l.$flags$|=4,e.$vnode$=l,l.$elm$=u.$elm$=c,yt=pn,Yt=c["s-cr"],St=!1,He(u,l,r);{if(se.$flags$|=1,Xt){ra(l.$elm$);for(const i of Se){const p=i.$nodeToRelocate$;if(!p["s-ol"]){const g=ze.createTextNode("");g["s-nr"]=p,xe(p.parentNode,p["s-ol"]=g,p)}}for(const i of Se){const p=i.$nodeToRelocate$,g=i.$slotRefNode$;if(g){const S=g.parentNode;let P=g.nextSibling;{let K=(a=p["s-ol"])==null?void 0:a.previousSibling;for(;K;){let $=(n=K["s-nr"])!=null?n:null;if($&&$["s-sn"]===p["s-sn"]&&S===($.__parentNode||$.parentNode)){for($=$.nextSibling;$===p||$!=null&&$["s-sr"];)$=$==null?void 0:$.nextSibling;if(!$||!$["s-nr"]){P=$;break}}K=K.previousSibling}}const U=p.__parentNode||p.parentNode,pe=p.__nextSibling||p.nextSibling;(!P&&S!==U||pe!==P)&&p!==P&&(!p["s-hn"]&&p["s-ol"]&&(p["s-hn"]=p["s-ol"].parentNode.nodeName),xe(S,p,P),p.nodeType===1&&p.tagName!=="SLOT-FB"&&(p.hidden=(o=p["s-ih"])!=null?o:!1)),p&&typeof g["s-rf"]=="function"&&g["s-rf"](p)}else p.nodeType===1&&(r&&(p["s-ih"]=(s=p.hidden)!=null?s:!1),p.hidden=!0)}}St&&jr(l.$elm$),se.$flags$&=-2,Se.length=0}Yt=void 0},aa=(e,t)=>{if(t&&!e.$onRenderResolve$&&t["s-p"]){const r=t["s-p"].push(new Promise(a=>e.$onRenderResolve$=()=>{t["s-p"].splice(r-1,1),a()}))}},Qt=(e,t)=>{if(e.$flags$|=16,e.$flags$&4){e.$flags$|=512;return}return aa(e,e.$ancestorComponent$),bn(()=>In(e,t))},In=(e,t)=>{const r=e.$hostElement$,a=Je("scheduleUpdate",e.$cmpMeta$.$tagName$),n=r;if(!n)throw new Error(`Can't render component <${r.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`);let o;return a(),Mn(o,()=>On(e,n,t))},Mn=(e,t)=>Ln(e)?e.then(t).catch(r=>{console.error(r),t()}):t(),Ln=e=>e instanceof Promise||e&&e.then&&typeof e.then=="function",On=async(e,t,r)=>{var a;const n=e.$hostElement$,o=Je("update",e.$cmpMeta$.$tagName$),s=n["s-rc"],c=Je("render",e.$cmpMeta$.$tagName$);Fn(e,t,n,r),s&&(s.map(u=>u()),n["s-rc"]=void 0),c(),o();{const u=(a=n["s-p"])!=null?a:[],l=()=>Dn(e);u.length===0?l():(Promise.all(u).then(l),e.$flags$|=4,u.length=0)}},Fn=(e,t,r,a)=>{try{t=t.render(),e.$flags$&=-17,e.$flags$|=2,An(e,t,a)}catch(n){mt(n,e.$hostElement$)}return null},Dn=e=>{const t=e.$cmpMeta$.$tagName$,r=e.$hostElement$,a=Je("postUpdate",t),n=r,o=e.$ancestorComponent$;e.$flags$&64?a():(e.$flags$|=64,sa(r),Un(n,"componentDidLoad",void 0,r),a(),e.$onReadyResolve$(r),o||Nn()),e.$onRenderResolve$&&(e.$onRenderResolve$(),e.$onRenderResolve$=void 0),e.$flags$&512&&Wt(()=>Qt(e,!1)),e.$flags$&=-517},Nn=e=>{sa(ze.documentElement),Wt(()=>Yr(gt,"appload",{detail:{namespace:nn}}))},Un=(e,t,r,a)=>{if(e&&e[t])try{return e[t](r)}catch(n){mt(n,a)}},sa=e=>{var t;return e.classList.add((t=Ue.hydratedSelectorName)!=null?t:"hydrated")},zn=(e,t)=>Te(e).$instanceValues$.get(t),na=(e,t,r,a)=>{const n=Te(e),o=e,s=n.$instanceValues$.get(t),c=n.$flags$,u=o;r=qr(r,a.$members$[t][0]);const l=Number.isNaN(s)&&Number.isNaN(r);if(r!==s&&!l){n.$instanceValues$.set(t,r);{if(a.$watchers$&&c&128){const p=a.$watchers$[t];p&&p.map(g=>{try{u[g](r,s,t)}catch(S){mt(S,o)}})}(c&18)===2&&Qt(n,!1)}}},Hn=(e,t,r)=>{var a,n;const o=e.prototype;if(t.$members$||t.$watchers$||e.watchers){e.watchers&&!t.$watchers$&&(t.$watchers$=e.watchers);const s=Object.entries((a=t.$members$)!=null?a:{});s.map(([c,[u]])=>{if(u&31||u&32){const{get:l,set:i}=Object.getOwnPropertyDescriptor(o,c)||{};l&&(t.$members$[c][0]|=2048),i&&(t.$members$[c][0]|=4096),Object.defineProperty(o,c,{get(){return l?l.apply(this):zn(this,c)},configurable:!0,enumerable:!0}),Object.defineProperty(o,c,{set(p){const g=Te(this);if(i){const S=u&32?this[c]:g.$hostElement$[c];typeof S>"u"&&g.$instanceValues$.get(c)?p=g.$instanceValues$.get(c):!g.$instanceValues$.get(c)&&S&&g.$instanceValues$.set(c,S),i.apply(this,[qr(p,u)]),p=u&32?this[c]:g.$hostElement$[c],na(this,c,p,t);return}{na(this,c,p,t);return}}})}});{const c=new Map;o.attributeChangedCallback=function(u,l,i){se.jmp(()=>{var p;const g=c.get(u);if(!(this.hasOwnProperty(g)&&Ue.lazyLoad)){if(o.hasOwnProperty(g)&&typeof this[g]=="number"&&this[g]==i)return;if(g==null){const P=Te(this),U=P==null?void 0:P.$flags$;if(U&&!(U&8)&&U&128&&i!==l){const K=this,$=(p=t.$watchers$)==null?void 0:p[u];$==null||$.forEach(Re=>{K[Re]!=null&&K[Re].call(K,i,l,u)})}return}}const S=Object.getOwnPropertyDescriptor(o,g);i=i===null&&typeof this[g]=="boolean"?!1:i,i!==this[g]&&(!S.get||S.set)&&(this[g]=i)})},e.observedAttributes=Array.from(new Set([...Object.keys((n=t.$watchers$)!=null?n:{}),...s.filter(([u,l])=>l[0]&15).map(([u,l])=>{const i=l[1]||u;return c.set(i,u),i})]))}}return e},Bn=async(e,t,r,a)=>{if(!(t.$flags$&32)){t.$flags$|=32;{const s=e.localName;customElements.whenDefined(s).then(()=>t.$flags$|=128)}}const n=t.$ancestorComponent$,o=()=>Qt(t,!0);n&&n["s-rc"]?n["s-rc"].push(o):o()},jn=(e,t)=>{},Gn=e=>{if(!(se.$flags$&1)){const t=Te(e),r=t.$cmpMeta$,a=Je("connectedCallback",r.$tagName$);if(t.$flags$&1)t!=null&&t.$lazyInstance$||t!=null&&t.$onReadyPromise$&&t.$onReadyPromise$.then(()=>jn());else{t.$flags$|=1,r.$flags$&12&&Wn(e);{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){aa(t,t.$ancestorComponent$=n);break}}r.$members$&&Object.entries(r.$members$).map(([n,[o]])=>{if(o&31&&e.hasOwnProperty(n)){const s=e[n];delete e[n],e[n]=s}}),Bn(e,t)}a()}},Wn=e=>{const t=e["s-cr"]=ze.createComment("");t["s-cn"]=!0,xe(e,t,e.firstChild)},Vn=async e=>{se.$flags$&1||Te(e),vt.has(e)&&vt.delete(e),e.shadowRoot&&vt.has(e.shadowRoot)&&vt.delete(e.shadowRoot)},N=(e,t)=>{const r={$flags$:t[0],$tagName$:t[1]};r.$members$=t[2],r.$watchers$=e.$watchers$;const a=e.prototype.connectedCallback,n=e.prototype.disconnectedCallback;return Object.assign(e.prototype,{__hasHostListenerAttached:!1,__registerHost(){dn(this,r)},connectedCallback(){this.__hasHostListenerAttached||(Te(this),this.__hasHostListenerAttached=!0),Gn(this),a&&a.call(this)},disconnectedCallback(){Vn(this),n&&n.call(this),se.raf(()=>{var o;const s=Te(this);((o=s==null?void 0:s.$vnode$)==null?void 0:o.$elm$)instanceof Node&&!s.$vnode$.$elm$.isConnected&&delete s.$vnode$,this instanceof Node&&!this.isConnected&&fn(this)})},__attachShadow(){this.shadowRoot=this}}),e.is=r.$tagName$,Hn(e,r)},Jt=(e,t)=>t,qn=Object.defineProperty,Yn=(e,t,r)=>t in e?qn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,oa=(e,t,r)=>Yn(e,typeof t!="symbol"?t+"":t,r),_e=(e=>(e[e.DEBUG=0]="DEBUG",e[e.INFO=1]="INFO",e[e.WARN=2]="WARN",e[e.ERROR=3]="ERROR",e))(_e||{});class Kn{constructor(t){oa(this,"logLevel"),oa(this,"logFormatter"),this.logLevel=t.logLevel||1,this.logFormatter=t.logFormatter||this.defaultFormatter}defaultFormatter(t,r){return`[${_e[t]}] ${new Date().toISOString()}: ${r}`}debug(t){this.logLevel<=0&&console.log(this.logFormatter(0,t))}info(t){this.logLevel<=1&&console.info(this.logFormatter(1,t))}warn(t){this.logLevel<=2&&console.warn(this.logFormatter(2,t))}error(t){this.logLevel<=3&&console.error(this.logFormatter(3,t))}log(t,r){switch(t){case 0:this.debug(r);break;case 1:this.info(r);break;case 2:this.warn(r);break;case 3:this.error(r);break}}}function Ae(e,t,r,a){return new(r||(r=Promise))(function(n,o){function s(l){try{u(a.next(l))}catch(i){o(i)}}function c(l){try{u(a.throw(l))}catch(i){o(i)}}function u(l){var i;l.done?n(l.value):(i=l.value,i instanceof r?i:new r(function(p){p(i)})).then(s,c)}u((a=a.apply(e,[])).next())})}function Ie(e,t){var r,a,n,o,s={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(u){return function(l){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(s=0)),s;)try{if(r=1,a&&(n=2&i[0]?a.return:i[0]?a.throw||((n=a.return)&&n.call(a),0):a.next)&&!(n=n.call(a,i[1])).done)return n;switch(a=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,a=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(n=s.trys,!((n=n.length>0&&n[n.length-1])||i[0]!==6&&i[0]!==2)){s=0;continue}if(i[0]===3&&(!n||i[1]>n[0]&&i[1]<n[3])){s.label=i[1];break}if(i[0]===6&&s.label<n[1]){s.label=n[1],n=i;break}if(n&&s.label<n[2]){s.label=n[2],s.ops.push(i);break}n[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(p){i=[6,p],a=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([u,l])}}}var Et={exclude:[]},Xn={},de=function(e,t){typeof window<"u"&&(Xn[e]=t)};function Pt(e){return e^=e>>>16,e=Math.imul(e,2246822507),e^=e>>>13,e=Math.imul(e,3266489909),(e^=e>>>16)>>>0}var Y=new Uint32Array([597399067,2869860233,951274213,2716044179]);function ue(e,t){return e<<t|e>>>32-t}function ia(e,t){var r;if(t===void 0&&(t=0),t=t?0|t:0,typeof e=="string"&&(r=e,e=new TextEncoder().encode(r).buffer),!(e instanceof ArrayBuffer))throw new TypeError("Expected key to be ArrayBuffer or string");var a=new Uint32Array([t,t,t,t]);(function(o,s){for(var c=o.byteLength/16|0,u=new Uint32Array(o,0,4*c),l=0;l<c;l++){var i=u.subarray(4*l,4*(l+1));i[0]=Math.imul(i[0],Y[0]),i[0]=ue(i[0],15),i[0]=Math.imul(i[0],Y[1]),s[0]=s[0]^i[0],s[0]=ue(s[0],19),s[0]=s[0]+s[1],s[0]=Math.imul(s[0],5)+1444728091,i[1]=Math.imul(i[1],Y[1]),i[1]=ue(i[1],16),i[1]=Math.imul(i[1],Y[2]),s[1]=s[1]^i[1],s[1]=ue(s[1],17),s[1]=s[1]+s[2],s[1]=Math.imul(s[1],5)+197830471,i[2]=Math.imul(i[2],Y[2]),i[2]=ue(i[2],17),i[2]=Math.imul(i[2],Y[3]),s[2]=s[2]^i[2],s[2]=ue(s[2],15),s[2]=s[2]+s[3],s[2]=Math.imul(s[2],5)+2530024501,i[3]=Math.imul(i[3],Y[3]),i[3]=ue(i[3],18),i[3]=Math.imul(i[3],Y[0]),s[3]=s[3]^i[3],s[3]=ue(s[3],13),s[3]=s[3]+s[0],s[3]=Math.imul(s[3],5)+850148119}})(e,a),function(o,s){var c=o.byteLength/16|0,u=o.byteLength%16,l=new Uint32Array(4),i=new Uint8Array(o,16*c,u);switch(u){case 15:l[3]=l[3]^i[14]<<16;case 14:l[3]=l[3]^i[13]<<8;case 13:l[3]=l[3]^i[12]<<0,l[3]=Math.imul(l[3],Y[3]),l[3]=ue(l[3],18),l[3]=Math.imul(l[3],Y[0]),s[3]=s[3]^l[3];case 12:l[2]=l[2]^i[11]<<24;case 11:l[2]=l[2]^i[10]<<16;case 10:l[2]=l[2]^i[9]<<8;case 9:l[2]=l[2]^i[8]<<0,l[2]=Math.imul(l[2],Y[2]),l[2]=ue(l[2],17),l[2]=Math.imul(l[2],Y[3]),s[2]=s[2]^l[2];case 8:l[1]=l[1]^i[7]<<24;case 7:l[1]=l[1]^i[6]<<16;case 6:l[1]=l[1]^i[5]<<8;case 5:l[1]=l[1]^i[4]<<0,l[1]=Math.imul(l[1],Y[1]),l[1]=ue(l[1],16),l[1]=Math.imul(l[1],Y[2]),s[1]=s[1]^l[1];case 4:l[0]=l[0]^i[3]<<24;case 3:l[0]=l[0]^i[2]<<16;case 2:l[0]=l[0]^i[1]<<8;case 1:l[0]=l[0]^i[0]<<0,l[0]=Math.imul(l[0],Y[0]),l[0]=ue(l[0],15),l[0]=Math.imul(l[0],Y[1]),s[0]=s[0]^l[0]}}(e,a),function(o,s){s[0]=s[0]^o.byteLength,s[1]=s[1]^o.byteLength,s[2]=s[2]^o.byteLength,s[3]=s[3]^o.byteLength,s[0]=s[0]+s[1]|0,s[0]=s[0]+s[2]|0,s[0]=s[0]+s[3]|0,s[1]=s[1]+s[0]|0,s[2]=s[2]+s[0]|0,s[3]=s[3]+s[0]|0,s[0]=Pt(s[0]),s[1]=Pt(s[1]),s[2]=Pt(s[2]),s[3]=Pt(s[3]),s[0]=s[0]+s[1]|0,s[0]=s[0]+s[2]|0,s[0]=s[0]+s[3]|0,s[1]=s[1]+s[0]|0,s[2]=s[2]+s[0]|0,s[3]=s[3]+s[0]|0}(e,a);var n=new Uint8Array(a.buffer);return Array.from(n).map(function(o){return o.toString(16).padStart(2,"0")}).join("")}function Qn(e){for(var t=0,r=0;r<e.length;++r)t+=Math.abs(e[r]);return t}function ca(e,t,r){for(var a=[],n=0;n<e[0].data.length;n++){for(var o=[],s=0;s<e.length;s++)o.push(e[s].data[n]);a.push(Jn(o))}var c=new Uint8ClampedArray(a);return new ImageData(c,t,r)}function Jn(e){if(e.length===0)return 0;for(var t={},r=0,a=e;r<a.length;r++)t[o=a[r]]=(t[o]||0)+1;var n=e[0];for(var o in t)t[o]>t[n]&&(n=parseInt(o,10));return n}function tt(){if(typeof navigator>"u")return{name:"unknown",version:"unknown"};for(var e=navigator.userAgent,t={Edg:"Edge",OPR:"Opera"},r=0,a=[/(?<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<a.length;r++){var n=a[r],o=e.match(n);if(o&&o.groups)return{name:t[o.groups.name]||o.groups.name,version:o.groups.version}}return{name:"unknown",version:"unknown"}}de("audio",function(){return Ae(this,void 0,void 0,function(){return Ie(this,function(e){return[2,new Promise(function(t,r){try{var a=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,5e3,44100),n=a.createBufferSource(),o=a.createOscillator();o.frequency.value=1e3;var s,c=a.createDynamicsCompressor();c.threshold.value=-50,c.knee.value=40,c.ratio.value=12,c.attack.value=0,c.release.value=.2,o.connect(c),c.connect(a.destination),o.start(),a.oncomplete=function(u){s=u.renderedBuffer.getChannelData(0),t({sampleHash:Qn(s),oscillator:o.type,maxChannels:a.destination.maxChannelCount,channelCountMode:n.channelCountMode})},a.startRendering()}catch(u){console.error("Error creating audio fingerprint:",u),r(u)}})]})})});var Zn=tt().name!=="SamsungBrowser"?1:3,la=280,ua=20;tt().name!="Firefox"&&de("canvas",function(){return document.createElement("canvas").getContext("2d"),new Promise(function(e){var t=Array.from({length:Zn},function(){return function(){var r=document.createElement("canvas"),a=r.getContext("2d");if(!a)return new ImageData(1,1);r.width=la,r.height=ua;var n=a.createLinearGradient(0,0,r.width,r.height);n.addColorStop(0,"red"),n.addColorStop(.16666666666666666,"orange"),n.addColorStop(.3333333333333333,"yellow"),n.addColorStop(.5,"green"),n.addColorStop(.6666666666666666,"blue"),n.addColorStop(.8333333333333334,"indigo"),n.addColorStop(1,"violet"),a.fillStyle=n,a.fillRect(0,0,r.width,r.height);var o="Random Text WMwmil10Oo";a.font="23.123px Arial",a.fillStyle="black",a.fillText(o,-5,15),a.fillStyle="rgba(0, 0, 255, 0.5)",a.fillText(o,-3.3,17.7),a.beginPath(),a.moveTo(0,0),a.lineTo(2*r.width/7,r.height),a.strokeStyle="white",a.lineWidth=2,a.stroke();var s=a.getImageData(0,0,r.width,r.height);return s}()});e({commonImageDataHash:ia(ca(t,la,ua).data.toString()).toString()})})});var Zt,eo=["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"],to=["monospace","sans-serif","serif"];function ha(e,t){if(!e)throw new Error("Canvas context not supported");return e.font="72px ".concat(t),e.measureText("WwMmLli0Oo").width}function ro(){var e,t=document.createElement("canvas"),r=(e=t.getContext("webgl"))!==null&&e!==void 0?e:t.getContext("experimental-webgl");if(r&&"getParameter"in r)try{var a=(r.getParameter(r.VENDOR)||"").toString(),n=(r.getParameter(r.RENDERER)||"").toString(),o={vendor:a,renderer:n,version:(r.getParameter(r.VERSION)||"").toString(),shadingLanguageVersion:(r.getParameter(r.SHADING_LANGUAGE_VERSION)||"").toString()};if(!n.length||!a.length){var s=r.getExtension("WEBGL_debug_renderer_info");if(s){var c=(r.getParameter(s.UNMASKED_VENDOR_WEBGL)||"").toString(),u=(r.getParameter(s.UNMASKED_RENDERER_WEBGL)||"").toString();c&&(o.vendorUnmasked=c),u&&(o.rendererUnmasked=u)}}return o}catch{}return"undefined"}function ao(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}function so(e,t){var r={};return t.forEach(function(a){var n=function(o){if(o.length===0)return null;var s={};o.forEach(function(l){var i=String(l);s[i]=(s[i]||0)+1});var c=o[0],u=1;return Object.keys(s).forEach(function(l){s[l]>u&&(c=l,u=s[l])}),c}(e.map(function(o){return a in o?o[a]:void 0}).filter(function(o){return o!==void 0}));n&&(r[a]=n)}),r}function no(){var e=[],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"]};return Object.keys(t).forEach(function(r){t[r].forEach(function(a){matchMedia("(".concat(r,": ").concat(a,")")).matches&&e.push("".concat(r,": ").concat(a))})}),e}function oo(){if(window.location.protocol==="https:"&&typeof window.ApplePaySession=="function")try{for(var e=window.ApplePaySession.supportsVersion,t=15;t>0;t--)if(e(t))return t}catch{return 0}return 0}tt().name!="Firefox"&&de("fonts",function(){var e=this;return new Promise(function(t,r){try{(function(a){var n;Ae(this,void 0,void 0,function(){var o,s,c;return Ie(this,function(u){switch(u.label){case 0:return document.body?[3,2]:[4,(l=50,new Promise(function(p){return setTimeout(p,l,i)}))];case 1:return u.sent(),[3,0];case 2:if((o=document.createElement("iframe")).setAttribute("frameBorder","0"),(s=o.style).setProperty("position","fixed"),s.setProperty("display","block","important"),s.setProperty("visibility","visible"),s.setProperty("border","0"),s.setProperty("opacity","0"),o.src="about:blank",document.body.appendChild(o),!(c=o.contentDocument||((n=o.contentWindow)===null||n===void 0?void 0:n.document)))throw new Error("Iframe document is not accessible");return a({iframe:c}),setTimeout(function(){document.body.removeChild(o)},0),[2]}var l,i})})})(function(a){var n=a.iframe;return Ae(e,void 0,void 0,function(){var o,s,c,u;return Ie(this,function(l){return o=n.createElement("canvas"),s=o.getContext("2d"),c=to.map(function(i){return ha(s,i)}),u={},eo.forEach(function(i){var p=ha(s,i);c.includes(p)||(u[i]=p)}),t(u),[2]})})})}catch{r({error:"unsupported"})}})}),de("hardware",function(){return new Promise(function(e,t){var r=navigator.deviceMemory!==void 0?navigator.deviceMemory:0,a=window.performance&&window.performance.memory?window.performance.memory:0;e({videocard:ro(),architecture:ao(),deviceMemory:r.toString()||"undefined",jsHeapSizeLimit:a.jsHeapSizeLimit||0})})}),de("locales",function(){return new Promise(function(e){e({languages:navigator.language,timezone:Intl.DateTimeFormat().resolvedOptions().timeZone})})}),de("permissions",function(){return Ae(this,void 0,void 0,function(){var e;return Ie(this,function(t){return Zt=(Et==null?void 0:Et.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"],e=Array.from({length:(Et==null?void 0:Et.retries)||3},function(){return function(){return Ae(this,void 0,void 0,function(){var r,a,n,o,s;return Ie(this,function(c){switch(c.label){case 0:r={},a=0,n=Zt,c.label=1;case 1:if(!(a<n.length))return[3,6];o=n[a],c.label=2;case 2:return c.trys.push([2,4,,5]),[4,navigator.permissions.query({name:o})];case 3:return s=c.sent(),r[o]=s.state.toString(),[3,5];case 4:return c.sent(),[3,5];case 5:return a++,[3,1];case 6:return[2,r]}})})}()}),[2,Promise.all(e).then(function(r){return so(r,Zt)})]})})}),de("plugins",function(){var e=[];if(navigator.plugins)for(var t=0;t<navigator.plugins.length;t++){var r=navigator.plugins[t];e.push([r.name,r.filename,r.description].join("|"))}return new Promise(function(a){a({plugins:e})})}),de("screen",function(){return new Promise(function(e){e({is_touchscreen:navigator.maxTouchPoints>0,maxTouchPoints:navigator.maxTouchPoints,colorDepth:screen.colorDepth,mediaMatches:no()})})}),de("system",function(){return new Promise(function(e){var t=tt();e({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:oo()})})});var Z,io=tt().name!=="SamsungBrowser"?1:3,R=null;de("webgl",function(){return Ae(this,void 0,void 0,function(){var e;return Ie(this,function(t){typeof document<"u"&&((Z=document.createElement("canvas")).width=200,Z.height=100,R=Z.getContext("webgl"));try{if(!R)throw new Error("WebGL not supported");return e=Array.from({length:io},function(){return function(){try{if(!R)throw new Error("WebGL not supported");var r=`
11
+ `,n=R.createShader(R.VERTEX_SHADER),o=R.createShader(R.FRAGMENT_SHADER);if(!n||!o)throw new Error("Failed to create shaders");if(R.shaderSource(n,r),R.shaderSource(o,s),R.compileShader(n),!R.getShaderParameter(n,R.COMPILE_STATUS))throw new Error("Vertex shader compilation failed: "+R.getShaderInfoLog(n));if(R.compileShader(o),!R.getShaderParameter(o,R.COMPILE_STATUS))throw new Error("Fragment shader compilation failed: "+R.getShaderInfoLog(o));var a=R.createProgram();if(!a)throw new Error("Failed to create shader program");if(R.attachShader(a,n),R.attachShader(a,o),R.linkProgram(a),!R.getProgramParameter(a,R.LINK_STATUS))throw new Error("Shader program linking failed: "+R.getProgramInfoLog(a));R.useProgram(a);for(var c=137,u=new Float32Array(4*c),l=2*Math.PI/c,i=0;i<c;i++){var p=i*l;u[4*i]=0,u[4*i+1]=0,u[4*i+2]=Math.cos(p)*(Z.width/2),u[4*i+3]=Math.sin(p)*(Z.height/2)}var m=R.createBuffer();R.bindBuffer(R.ARRAY_BUFFER,m),R.bufferData(R.ARRAY_BUFFER,u,R.STATIC_DRAW);var b=R.getAttribLocation(a,"position");R.enableVertexAttribArray(b),R.vertexAttribPointer(b,2,R.FLOAT,!1,0,0),R.viewport(0,0,Z.width,Z.height),R.clearColor(0,0,0,1),R.clear(R.COLOR_BUFFER_BIT),R.drawArrays(R.LINES,0,2*c);var v=new Uint8ClampedArray(Z.width*Z.height*4);return R.readPixels(0,0,Z.width,Z.height,R.RGBA,R.UNSIGNED_BYTE,v),new ImageData(v,Z.width,Z.height)}catch{return new ImageData(1,1)}finally{R&&(R.bindBuffer(R.ARRAY_BUFFER,null),R.useProgram(null),R.viewport(0,0,R.drawingBufferWidth,R.drawingBufferHeight),R.clearColor(0,0,0,0))}}()}),[2,{commonImageHash:Ut(Lr(e,Z.width,Z.height).data.toString()).toString()}]}catch{return[2,{webgl:"unsupported"}]}return[2]})})});var $e=function(e,t,r,s){for(var n=(r-t)/s,o=0,a=0;a<s;a++)o+=e(t+(a+.5)*n);return o*n};fe("math",function(){return ve(void 0,void 0,void 0,function(){return be(this,function(e){return[2,{acos:Math.acos(.5),asin:$e(Math.asin,-1,1,97),atan:$e(Math.atan,-1,1,97),cos:$e(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:$e(Math.sin,-Math.PI,Math.PI,97),sinh:$e(Math.sinh,-9/7,7/9,97),sqrt:Math.sqrt(2),tan:$e(Math.tan,0,2*Math.PI,97),tanh:$e(Math.tanh,-9/7,7/9,97)}]})})});const Ya="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";let pt=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+=Ya[r[e]&63];return t};class Ht{constructor(t){F(this,"config"),this.config=t}async getAdsForSearchParams(t){return[]}async onQuerySubmitted(t){}async onQueryFetched(t,r){}async onInputCleared(){}async onAdContainerRendered(t){}async onAdContainerViewed(t){}}class Qa extends Ht{async getAdsForSearchParams(t){if(!this.config.admSub)return console.error("No admSub specified in config."),[];const r=`https://demofeed.is.ampfeed.com/is?${new URLSearchParams({partner:"demofeed",sub1:this.config.admSub,qt:t.searchTerm,v:"2.0",rfr:"searchcraft.io","results-ta":`${this.config.admTextAdQuantity||0}`,"results-pa":`${this.config.admProductAdQuantity||0}`}).toString()}`,s=await(await fetch(r,{method:"GET"})).json(),n=s.product_ads.map(a=>({id:pt(),adSource:"adMarketplace",admAdType:"adm-product-ad",admAd:a})),o=s.text_ads.map(a=>({id:pt(),adSource:"adMarketplace",admAdType:"adm-text-ad",admAd:a}));return n.concat(o)}async onAdContainerViewed(t){var r;const s=t.adClientResponseItem;(r=s.admAd)!=null&&r.impression_url&&fetch(s.admAd.impression_url)}}class Ka extends Ht{async getAdsForSearchParams(t){return[]}}const Xa=200,Ja=100;class Za extends Ht{constructor(t){super(t),F(this,"adCallTimeout"),this.addScriptTagToDocument()}async onQuerySubmitted(t){this.addScriptTagToDocument()}async onQueryFetched(t,r){var s;if((((s=r.data.hits)==null?void 0:s.length)||0)===0){this.removeScriptTagFromDocument();return}this.performAdCall(Xa)}async onAdContainerViewed(t){this.performAdCall(Ja)}async onInputCleared(){this.removeScriptTagFromDocument()}performAdCall(t){this.adCallTimeout&&clearTimeout(this.adCallTimeout),this.adCallTimeout=setTimeout(()=>{this.addScriptTagToDocument();try{PostRelease==null||PostRelease.Start({ptd:[this.config.nativoPlacementId]})}catch(r){console.error(r)}},t)}async getAdsForSearchParams(t){return[]}addScriptTagToDocument(){if(!document.head.querySelector("#nativo-tag")){const t=document.createElement("script");t.type="text/javascript",t.src="https://s.ntv.io/serve/load.js",t.id="nativo-tag",t.setAttribute("data-ntv-set-no-auto-start","true"),document.head.appendChild(t)}}removeScriptTagFromDocument(){const t=document.head.querySelector("#nativo-tag");t&&document.head.removeChild(t)}}const en=500;class tn{constructor(t,r,s){F(this,"measureRequestTimeout"),F(this,"measureRequestsBatched",[]),F(this,"config"),F(this,"sdkInfo"),F(this,"userId"),F(this,"sessionId"),F(this,"sendMeasureEvent",(n,o={},a={})=>{const c={event_name:n,properties:{searchcraft_index_names:this.config.index,session_id:this.sessionId,...o},user:{...this.measureRequestUser,...a}};this.measureRequestsBatched.push(c),clearTimeout(this.measureRequestTimeout),this.measureRequestTimeout=setTimeout(async()=>{const u=JSON.stringify({items:this.measureRequestsBatched}),l=`${this.baseMeasureUrl}/batch`;try{const i=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json",Authorization:this.config.readKey,"X-Sc-User-Id":this.userId},body:u,keepalive:!0});if(!i.ok)throw new Error(`Failed to send request: ${i.status} ${i.statusText}`);this.measureRequestsBatched=[];return}catch(i){throw console.error("Error sending MeasureRequest:",i),i}},en)}),this.config=t,this.sdkInfo=r,this.userId=s,this.sessionId=pt(),this.sendMeasureEvent("sdk_initialized")}get baseMeasureUrl(){return`${this.config.endpointURL}/measure`}get measureRequestUser(){return{user_id:this.userId,locale:navigator.language||"en-US",os:navigator.userAgent.includes("Windows")?"Windows":navigator.userAgent.includes("Mac")?"Mac":navigator.userAgent.includes("Linux")?"Linux":"Unknown",platform:navigator.platform||"Unknown",sdk_name:this.sdkInfo.sdkName,sdk_version:this.sdkInfo.sdkVersion,user_agent:navigator.userAgent||"Unknown"}}}function rn(e){const t=[];let r="should";return e.facetPathsForIndexFields&&Object.keys(e.facetPathsForIndexFields).forEach(s=>{var n;const o=(n=e.facetPathsForIndexFields)==null?void 0:n[s];o&&(r="must",t.push({occur:r,exact:{ctx:o.value}}))}),e.rangeValueForIndexFields&&Object.keys(e.rangeValueForIndexFields).forEach(s=>{var n;const o=(n=e.rangeValueForIndexFields)==null?void 0:n[s];o&&(r="must",t.push({occur:r,exact:{ctx:o.value}}))}),e.sort==="desc"?e.order_by="date_published":e.order_by="",t.push({occur:r,[e.mode]:{ctx:e.searchTerm}}),t}const sn=e=>e.endsWith("/")?e.slice(0,-1):e,an=e=>{let t="";if(t=e.trim(),t=t.replace(/[‘’“”]/g,r=>({"‘":"'","’":"'","“":'"',"”":'"'})[r]||r),(t.match(/"/g)||[]).length%2!==0)throw new Error("The search term contains an uneven number of quote characters.");return t};class nn{constructor(t,r,s){F(this,"config"),F(this,"userId"),F(this,"parent"),F(this,"getSearchResponse",async n=>{var o,a,c,u,l;const i=an(n.searchTerm);(o=this.parent.measureClient)==null||o.sendMeasureEvent("search_requested",{search_term:i}),this.parent.emitEvent("query_submitted",{name:"query_submitted",data:{searchTerm:i}}),(a=this.parent.adClient)==null||a.onQuerySubmitted(n);try{const p={query:rn(n),offset:n.offset||0,limit:n.limit||this.config.searchResultsPerPage||20};n.order_by&&(p.order_by=n.order_by,p.sort=n.sort==="desc"||n.sort==="asc"?n.sort:"asc");const m={method:"POST",headers:{Authorization:this.config.readKey,"Content-Type":"application/json","X-Sc-User-Id":this.userId},body:JSON.stringify(p)},b=await fetch(this.baseSearchUrl,m);if(!b.ok)throw new Error(`Error: ${b.statusText} (Status: ${b.status})`);const v=await b.json();return(c=this.parent.measureClient)==null||c.sendMeasureEvent("search_response_received",{search_term:i,number_of_documents:v.data.count}),this.parent.emitEvent("query_fetched",{name:"query_fetched",data:{searchTerm:i}}),(((u=v.data.hits)==null?void 0:u.length)||0)===0&&this.parent.emitEvent("no_results_returned",{name:"no_results_returned"}),(l=this.parent.adClient)==null||l.onQueryFetched(n,v),v}catch(p){throw console.error("Error parsing response:",p),p}}),this.parent=t,this.config=r,this.userId=s}get baseSearchUrl(){return`${this.config.endpointURL}/index/${this.config.index.join(",")}/search`}}class on{constructor(t,r){if(F(this,"config"),F(this,"measureClient"),F(this,"searchClient"),F(this,"adClient"),F(this,"userId"),F(this,"requestTimeout"),F(this,"subscriptionEvents",{}),F(this,"getItems",(s,n,o)=>{const a=async()=>{(async()=>{var c,u;const l=await((c=this==null?void 0:this.searchClient)==null?void 0:c.getSearchResponse(s));if(!l)throw new Error("Search client was not initialized.");const i=(u=l.data.hits||[])==null?void 0:u.map(p=>p.doc).filter(p=>!!p).map(p=>({type:"SearchDocument",id:pt(),document:p}));n(l,i)})(),(async()=>{if(this.adClient){const c=await this.adClient.getAdsForSearchParams(s);o(c)}})()};clearTimeout(this.requestTimeout),this.config.searchDebounceDelay?this.requestTimeout=setTimeout(a,this.config.searchDebounceDelay):a()}),!t.endpointURL||!t.index||!t.readKey)throw new Error("Endpoint URL, Index value(s), and Read Key must be provided");this.config={...t,endpointURL:sn(t.endpointURL)},this.userId="",this.initClients(this.config,r),this.initInputForms(),this.startObservingMutations()}initInputForms(){const t=document.querySelectorAll("searchcraft-input-form");setTimeout(()=>{t.forEach(r=>{r.core=this})},40)}startObservingMutations(){new MutationObserver((t,r)=>{let s=!1;for(const n of t)n.type==="childList"&&n.addedNodes.forEach(o=>{o.nodeType===1&&o.className.toLowerCase()==="searchcraft-input-form"&&(s=!0)});s&&this.initInputForms()}).observe(document.body,{childList:!0,subtree:!0})}initClients(t,r){setTimeout(async()=>{let s=this.config.userId;switch(s||(s=await Fa()),this.measureClient=new tn(t,r,s),this.searchClient=new nn(this,t,s),t.adSource){case"adMarketplace":this.adClient=new Qa(t);break;case"Nativo":this.adClient=new Za(t);break;case"Custom":this.adClient=new Ka(t);break}},300)}emitEvent(t,r){var s;(s=this.subscriptionEvents[t])==null||s.forEach(n=>{n(r)})}subscribe(t,r){return this.subscriptionEvents[t]||(this.subscriptionEvents[t]=[]),this.subscriptionEvents[t].push(r),()=>{this.subscriptionEvents[t]=this.subscriptionEvents[t].filter(s=>s!==r)}}handleAdContainerRendered(t){var r;(r=this.adClient)==null||r.onAdContainerRendered(t),this.emitEvent("ad_container_rendered",{name:"ad_container_rendered",data:{adContainerId:t.adContainerId,adSource:t.adSource,searchTerm:t.searchTerm}})}handleAdContainerViewed(t){var r;(r=this.adClient)==null||r.onAdContainerViewed(t),this.emitEvent("ad_container_viewed",{name:"ad_container_viewed",data:{adContainerId:t.adContainerId,adSource:t.adSource,searchTerm:t.searchTerm}})}handleInputCleared(){var t;this.emitEvent("input_cleared",{name:"input_cleared"}),(t=this.adClient)==null||t.onInputCleared()}}const cn="searchcraft-javascript-sdk",Ue={allRenderFn:!0,appendChildSlotFix:!1,asyncLoading:!0,asyncQueue:!1,attachStyles:!0,cloneNodeFix:!1,cmpDidLoad:!0,cmpDidRender:!1,cmpDidUnload:!1,cmpDidUpdate:!1,cmpShouldUpdate:!1,cmpWillLoad:!1,cmpWillRender:!1,cmpWillUpdate:!1,connectedCallback:!0,constructableCSS:!0,cssAnnotations:!0,devTools:!1,disconnectedCallback:!0,element:!1,event:!0,experimentalScopedSlotChanges:!1,experimentalSlotFixes:!1,formAssociated:!1,hasRenderFn:!0,hostListener:!1,hostListenerTarget:!1,hostListenerTargetBody:!1,hostListenerTargetDocument:!1,hostListenerTargetParent:!1,hostListenerTargetWindow:!1,hotModuleReplacement:!1,hydrateClientSide:!1,hydrateServerSide:!1,hydratedAttribute:!1,hydratedClass:!0,hydratedSelectorName:"hydrated",invisiblePrehydration:!0,isDebug:!1,isDev:!1,isTesting:!1,lazyLoad:!1,lifecycle:!0,lifecycleDOMEvents:!1,member:!0,method:!1,mode:!1,modernPropertyDecls:!0,observeAttribute:!0,profile:!1,prop:!0,propBoolean:!0,propMutable:!1,propNumber:!0,propString:!0,reflect:!1,scoped:!1,scopedSlotTextContentFix:!1,scriptDataOpts:!1,shadowDelegatesFocus:!1,shadowDom:!1,slot:!0,slotChildNodesFix:!1,slotRelocation:!0,state:!0,style:!1,svg:!0,taskQueue:!0,updatable:!0,vdomAttribute:!0,vdomClass:!0,vdomFunctional:!0,vdomKey:!0,vdomListener:!0,vdomPropOrAttr:!0,vdomRef:!1,vdomRender:!0,vdomStyle:!0,vdomText:!0,vdomXlink:!1,watchCallback:!0};var ln=Object.defineProperty,un=(e,t)=>{for(var r in t)ln(e,r,{get:t[r],enumerable:!0})},hn="http://www.w3.org/2000/svg",dn="http://www.w3.org/1999/xhtml",fn=(e,t)=>{var r;const s=t.$cmpMeta$;Object.entries((r=s.$members$)!=null?r:{}).map(([o,[a]])=>{if(a&31||a&32){const c=e[o],u=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),o);Object.defineProperty(e,o,{get(){return u.get.call(this)},set(l){u.set.call(this,l)},configurable:!0,enumerable:!0}),e[o]=t.$instanceValues$.has(o)?t.$instanceValues$.get(o):c}})},Bt=new WeakMap,pn=e=>Bt.delete(e),ke=e=>Bt.get(e),mn=(e,t)=>{const r={$flags$:0,$hostElement$:e,$cmpMeta$:t,$instanceValues$:new Map};r.$onReadyPromise$=new Promise(n=>r.$onReadyResolve$=n),e["s-p"]=[],e["s-rc"]=[];const s=Bt.set(e,r);return fn(e,r),s},Nr=(e,t)=>t in e,mt=(e,t)=>(0,console.error)(e,t),gt=typeof window<"u"?window:{},ze=gt.document||{head:{}},N=gt.HTMLElement||class{},ne={$flags$:0,$resourcesUrl$:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,r,s)=>e.addEventListener(t,r,s),rel:(e,t,r,s)=>e.removeEventListener(t,r,s),ce:(e,t)=>new CustomEvent(e,t)},gn=Ue.shadowDom,vn=e=>Promise.resolve(e),jt=!1,Ur=[],zr=[],bn=(e,t)=>r=>{e.push(r),jt||(jt=!0,ne.$flags$&4?Wt(Vt):ne.raf(Vt))},Hr=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(r){mt(r)}e.length=0},Vt=()=>{Hr(Ur),Hr(zr),(jt=Ur.length>0)&&ne.raf(Vt)},Wt=e=>vn().then(e),yn=bn(zr),Gt=e=>(e=typeof e,e==="object"||e==="function"),Sn={};un(Sn,{err:()=>Br,map:()=>wn,ok:()=>qt,unwrap:()=>Rn,unwrapErr:()=>En});var qt=e=>({isOk:!0,isErr:!1,value:e}),Br=e=>({isOk:!1,isErr:!0,value:e});function wn(e,t){if(e.isOk){const r=t(e.value);return r instanceof Promise?r.then(s=>qt(s)):qt(r)}if(e.isErr){const r=e.value;return Br(r)}throw"should never get here"}var Rn=e=>{if(e.isOk)return e.value;throw e.value},En=e=>{if(e.isErr)return e.value;throw e.value},jr=e=>{const t=e.__childNodes||e.childNodes;e.tagName&&e.tagName.includes("-")&&e["s-cr"]&&e.tagName!=="SLOT-FB"&&Vr(t,e.tagName).forEach(r=>{var s;r.nodeType===1&&r.tagName==="SLOT-FB"&&((s=Pn(r,r["s-sn"],!1))!=null&&s.length?r.hidden=!0:r.hidden=!1)});for(const r of t)r.nodeType===1&&(r.__childNodes||r.childNodes).length&&jr(r)};function Vr(e,t,r){let s=0,n=[],o;for(;s<e.length;s++)o=e[s],o["s-sr"]&&o["s-hn"]===t&&r===void 0&&n.push(o),n=[...n,...Vr(o.childNodes,t,r)];return n}var Pn=(e,t,r=!0)=>{const s=[];for((r&&e["s-sr"]||!e["s-sr"])&&s.push(e);(e=e.nextSibling)&&e["s-sn"]===t;)s.push(e);return s},Wr=(e,t)=>e.nodeType===1?e.getAttribute("slot")===null&&t===""||e.getAttribute("slot")===t:e["s-sn"]===t?!0:t==="",Je=(e,t="")=>()=>{},f=(e,t,...r)=>{let s=null,n=null,o=null,a=!1,c=!1;const u=[],l=p=>{for(let m=0;m<p.length;m++)s=p[m],Array.isArray(s)?l(s):s!=null&&typeof s!="boolean"&&((a=typeof e!="function"&&!Gt(s))&&(s=String(s)),a&&c?u[u.length-1].$text$+=s:u.push(a?vt(null,s):s),c=a)};if(l(r),t){t.key&&(n=t.key),t.name&&(o=t.name);{const p=t.className||t.class;p&&(t.class=typeof p!="object"?p:Object.keys(p).filter(m=>p[m]).join(" "))}}if(typeof e=="function")return e(t===null?{}:t,u,Tn);const i=vt(e,null);return i.$attrs$=t,u.length>0&&(i.$children$=u),i.$key$=n,i.$name$=o,i},vt=(e,t)=>{const r={$flags$:0,$tag$:e,$text$:t,$elm$:null,$children$:null};return r.$attrs$=null,r.$key$=null,r.$name$=null,r},Cn={},kn=e=>e&&e.$tag$===Cn,Tn={forEach:(e,t)=>e.map(Gr).forEach(t),map:(e,t)=>e.map(Gr).map(t).map(xn)},Gr=e=>({vattrs:e.$attrs$,vchildren:e.$children$,vkey:e.$key$,vname:e.$name$,vtag:e.$tag$,vtext:e.$text$}),xn=e=>{if(typeof e.vtag=="function"){const r={...e.vattrs};return e.vkey&&(r.key=e.vkey),e.vname&&(r.name=e.vname),f(e.vtag,r,...e.vchildren||[])}const t=vt(e.vtag,e.vtext);return t.$attrs$=e.vattrs,t.$children$=e.vchildren,t.$key$=e.vkey,t.$name$=e.vname,t},qr=(e,t)=>e!=null&&!Gt(e)?t&4?e==="false"?!1:e===""||!!e:t&2?parseFloat(e):t&1?String(e):e:e,$n=e=>e,Te=(e,t,r)=>{const s=$n(e);return{emit:n=>Yr(s,t,{bubbles:!0,composed:!0,cancelable:!0,detail:n})}},Yr=(e,t,r)=>{const s=ne.ce(t,r);return e.dispatchEvent(s),s},bt=new WeakMap,Qr=(e,t,r,s,n,o)=>{if(r!==s){let a=Nr(e,t),c=t.toLowerCase();if(t==="class"){const u=e.classList,l=Kr(r);let i=Kr(s);e["s-si"]?(i.push(e["s-si"]),l.forEach(p=>{p.startsWith(e["s-si"])&&i.push(p)}),i=[...new Set(i)],u.add(...i),delete e["s-si"]):(u.remove(...l.filter(p=>p&&!i.includes(p))),u.add(...i.filter(p=>p&&!l.includes(p))))}else if(t==="style"){for(const u in r)(!s||s[u]==null)&&(u.includes("-")?e.style.removeProperty(u):e.style[u]="");for(const u in s)(!r||s[u]!==r[u])&&(u.includes("-")?e.style.setProperty(u,s[u]):e.style[u]=s[u])}else if(t!=="key")if(!e.__lookupSetter__(t)&&t[0]==="o"&&t[1]==="n"){if(t[2]==="-"?t=t.slice(3):Nr(gt,c)?t=c.slice(2):t=c[2]+t.slice(3),r||s){const u=t.endsWith(Xr);t=t.replace(An,""),r&&ne.rel(e,t,r,u),s&&ne.ael(e,t,s,u)}}else{const u=Gt(s);if((a||u&&s!==null)&&!n)try{if(e.tagName.includes("-"))e[t]!==s&&(e[t]=s);else{const l=s??"";t==="list"?a=!1:(r==null||e[t]!=l)&&(typeof e.__lookupSetter__(t)=="function"?e[t]=l:e.setAttribute(t,l))}}catch{}s==null||s===!1?(s!==!1||e.getAttribute(t)==="")&&e.removeAttribute(t):(!a||o&4||n)&&!u&&(s=s===!0?"":s,e.setAttribute(t,s))}}},_n=/\s/,Kr=e=>(typeof e=="object"&&"baseVal"in e&&(e=e.baseVal),e?e.split(_n):[]),Xr="Capture",An=new RegExp(Xr+"$"),Jr=(e,t,r)=>{const s=t.$elm$.nodeType===11&&t.$elm$.host?t.$elm$.host:t.$elm$,n=e&&e.$attrs$||{},o=t.$attrs$||{};for(const a of Zr(Object.keys(n)))a in o||Qr(s,a,n[a],void 0,r,t.$flags$);for(const a of Zr(Object.keys(o)))Qr(s,a,n[a],o[a],r,t.$flags$)};function Zr(e){return e.includes("ref")?[...e.filter(t=>t!=="ref"),"ref"]:e}var Yt,Qt,yt=!1,St=!1,Kt=!1,ce=!1,wt=(e,t,r)=>{var s;const n=t.$children$[r];let o=0,a,c,u;if(yt||(Kt=!0,n.$tag$==="slot"&&(n.$flags$|=n.$children$?2:1)),n.$text$!==null)a=n.$elm$=ze.createTextNode(n.$text$);else if(n.$flags$&1)a=n.$elm$=ze.createTextNode("");else{if(ce||(ce=n.$tag$==="svg"),a=n.$elm$=ze.createElementNS(ce?hn:dn,!yt&&Ue.slotRelocation&&n.$flags$&2?"slot-fb":n.$tag$),ce&&n.$tag$==="foreignObject"&&(ce=!1),Jr(null,n,ce),n.$children$)for(o=0;o<n.$children$.length;++o)c=wt(e,n,o),c&&a.appendChild(c);n.$tag$==="svg"?ce=!1:a.tagName==="foreignObject"&&(ce=!0)}return a["s-hn"]=Qt,n.$flags$&3&&(a["s-sr"]=!0,a["s-cr"]=Yt,a["s-sn"]=n.$name$||"",a["s-rf"]=(s=n.$attrs$)==null?void 0:s.ref,u=e&&e.$children$&&e.$children$[r],u&&u.$tag$===n.$tag$&&e.$elm$&&Ze(e.$elm$,!1)),a},Ze=(e,t)=>{ne.$flags$|=1;const r=Array.from(e.__childNodes||e.childNodes);e["s-sr"]&&Ue.experimentalSlotFixes;for(let s=r.length-1;s>=0;s--){const n=r[s];n["s-hn"]!==Qt&&n["s-ol"]&&(xe(et(n).parentNode,n,et(n)),n["s-ol"].remove(),n["s-ol"]=void 0,n["s-sh"]=void 0,Kt=!0),t&&Ze(n,t)}ne.$flags$&=-2},es=(e,t,r,s,n,o)=>{let a=e["s-cr"]&&e["s-cr"].parentNode||e,c;for(;n<=o;++n)s[n]&&(c=wt(null,r,n),c&&(s[n].$elm$=c,xe(a,c,et(t))))},ts=(e,t,r)=>{for(let s=t;s<=r;++s){const n=e[s];if(n){const o=n.$elm$;o&&(St=!0,o["s-ol"]?o["s-ol"].remove():Ze(o,!0),o.remove())}}},In=(e,t,r,s,n=!1)=>{let o=0,a=0,c=0,u=0,l=t.length-1,i=t[0],p=t[l],m=s.length-1,b=s[0],v=s[m],$,z;for(;o<=l&&a<=m;)if(i==null)i=t[++o];else if(p==null)p=t[--l];else if(b==null)b=s[++a];else if(v==null)v=s[--m];else if(Rt(i,b,n))He(i,b,n),i=t[++o],b=s[++a];else if(Rt(p,v,n))He(p,v,n),p=t[--l],v=s[--m];else if(Rt(i,v,n))(i.$tag$==="slot"||v.$tag$==="slot")&&Ze(i.$elm$.parentNode,!1),He(i,v,n),xe(e,i.$elm$,p.$elm$.nextSibling),i=t[++o],v=s[--m];else if(Rt(p,b,n))(i.$tag$==="slot"||v.$tag$==="slot")&&Ze(p.$elm$.parentNode,!1),He(p,b,n),xe(e,p.$elm$,i.$elm$),p=t[--l],b=s[++a];else{for(c=-1,u=o;u<=l;++u)if(t[u]&&t[u].$key$!==null&&t[u].$key$===b.$key$){c=u;break}c>=0?(z=t[c],z.$tag$!==b.$tag$?$=wt(t&&t[a],r,c):(He(z,b,n),t[c]=void 0,$=z.$elm$),b=s[++a]):($=wt(t&&t[a],r,a),b=s[++a]),$&&xe(et(i.$elm$).parentNode,$,et(i.$elm$))}o>l?es(e,s[m+1]==null?null:s[m+1].$elm$,r,s,a,m):a>m&&ts(t,o,l)},Rt=(e,t,r=!1)=>e.$tag$===t.$tag$?e.$tag$==="slot"?e.$name$===t.$name$:r?(r&&!e.$key$&&t.$key$&&(e.$key$=t.$key$),!0):e.$key$===t.$key$:!1,et=e=>e&&e["s-ol"]||e,He=(e,t,r=!1)=>{const s=t.$elm$=e.$elm$,n=e.$children$,o=t.$children$,a=t.$tag$,c=t.$text$;let u;c===null?(ce=a==="svg"?!0:a==="foreignObject"?!1:ce,a==="slot"&&!yt||Jr(e,t,ce),n!==null&&o!==null?In(s,n,t,o,r):o!==null?(e.$text$!==null&&(s.textContent=""),es(s,null,t,o,0,o.length-1)):!r&&Ue.updatable&&n!==null&&ts(n,0,n.length-1),ce&&a==="svg"&&(ce=!1)):(u=s["s-cr"])?u.parentNode.textContent=c:e.$text$!==c&&(s.data=c)},Se=[],rs=e=>{let t,r,s;const n=e.__childNodes||e.childNodes;for(const o of n){if(o["s-sr"]&&(t=o["s-cr"])&&t.parentNode){r=t.parentNode.__childNodes||t.parentNode.childNodes;const a=o["s-sn"];for(s=r.length-1;s>=0;s--)if(t=r[s],!t["s-cn"]&&!t["s-nr"]&&t["s-hn"]!==o["s-hn"])if(Wr(t,a)){let c=Se.find(u=>u.$nodeToRelocate$===t);St=!0,t["s-sn"]=t["s-sn"]||a,c?(c.$nodeToRelocate$["s-sh"]=o["s-hn"],c.$slotRefNode$=o):(t["s-sh"]=o["s-hn"],Se.push({$slotRefNode$:o,$nodeToRelocate$:t})),t["s-sr"]&&Se.map(u=>{Wr(u.$nodeToRelocate$,t["s-sn"])&&(c=Se.find(l=>l.$nodeToRelocate$===t),c&&!u.$slotRefNode$&&(u.$slotRefNode$=c.$slotRefNode$))})}else Se.some(c=>c.$nodeToRelocate$===t)||Se.push({$nodeToRelocate$:t})}o.nodeType===1&&rs(o)}},xe=(e,t,r)=>e==null?void 0:e.insertBefore(t,r),Mn=(e,t,r=!1)=>{var s,n,o,a;const c=e.$hostElement$,u=e.$vnode$||vt(null,null),l=kn(t)?t:f(null,null,t);if(Qt=c.tagName,r&&l.$attrs$)for(const i of Object.keys(l.$attrs$))c.hasAttribute(i)&&!["key","ref","style","class"].includes(i)&&(l.$attrs$[i]=c[i]);l.$tag$=null,l.$flags$|=4,e.$vnode$=l,l.$elm$=u.$elm$=c,yt=gn,Yt=c["s-cr"],St=!1,He(u,l,r);{if(ne.$flags$|=1,Kt){rs(l.$elm$);for(const i of Se){const p=i.$nodeToRelocate$;if(!p["s-ol"]){const m=ze.createTextNode("");m["s-nr"]=p,xe(p.parentNode,p["s-ol"]=m,p)}}for(const i of Se){const p=i.$nodeToRelocate$,m=i.$slotRefNode$;if(m){const b=m.parentNode;let v=m.nextSibling;{let K=(s=p["s-ol"])==null?void 0:s.previousSibling;for(;K;){let _=(n=K["s-nr"])!=null?n:null;if(_&&_["s-sn"]===p["s-sn"]&&b===(_.__parentNode||_.parentNode)){for(_=_.nextSibling;_===p||_!=null&&_["s-sr"];)_=_==null?void 0:_.nextSibling;if(!_||!_["s-nr"]){v=_;break}}K=K.previousSibling}}const $=p.__parentNode||p.parentNode,z=p.__nextSibling||p.nextSibling;(!v&&b!==$||z!==v)&&p!==v&&(!p["s-hn"]&&p["s-ol"]&&(p["s-hn"]=p["s-ol"].parentNode.nodeName),xe(b,p,v),p.nodeType===1&&p.tagName!=="SLOT-FB"&&(p.hidden=(o=p["s-ih"])!=null?o:!1)),p&&typeof m["s-rf"]=="function"&&m["s-rf"](p)}else p.nodeType===1&&(r&&(p["s-ih"]=(a=p.hidden)!=null?a:!1),p.hidden=!0)}}St&&jr(l.$elm$),ne.$flags$&=-2,Se.length=0}Yt=void 0},ss=(e,t)=>{if(t&&!e.$onRenderResolve$&&t["s-p"]){const r=t["s-p"].push(new Promise(s=>e.$onRenderResolve$=()=>{t["s-p"].splice(r-1,1),s()}))}},Xt=(e,t)=>{if(e.$flags$|=16,e.$flags$&4){e.$flags$|=512;return}return ss(e,e.$ancestorComponent$),yn(()=>Ln(e,t))},Ln=(e,t)=>{const r=e.$hostElement$,s=Je("scheduleUpdate",e.$cmpMeta$.$tagName$),n=r;if(!n)throw new Error(`Can't render component <${r.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`);let o;return s(),On(o,()=>Dn(e,n,t))},On=(e,t)=>Fn(e)?e.then(t).catch(r=>{console.error(r),t()}):t(),Fn=e=>e instanceof Promise||e&&e.then&&typeof e.then=="function",Dn=async(e,t,r)=>{var s;const n=e.$hostElement$,o=Je("update",e.$cmpMeta$.$tagName$),a=n["s-rc"],c=Je("render",e.$cmpMeta$.$tagName$);Nn(e,t,n,r),a&&(a.map(u=>u()),n["s-rc"]=void 0),c(),o();{const u=(s=n["s-p"])!=null?s:[],l=()=>Un(e);u.length===0?l():(Promise.all(u).then(l),e.$flags$|=4,u.length=0)}},Nn=(e,t,r,s)=>{try{t=t.render(),e.$flags$&=-17,e.$flags$|=2,Mn(e,t,s)}catch(n){mt(n,e.$hostElement$)}return null},Un=e=>{const t=e.$cmpMeta$.$tagName$,r=e.$hostElement$,s=Je("postUpdate",t),n=r,o=e.$ancestorComponent$;e.$flags$&64?s():(e.$flags$|=64,as(r),Hn(n,"componentDidLoad",void 0,r),s(),e.$onReadyResolve$(r),o||zn()),e.$onRenderResolve$&&(e.$onRenderResolve$(),e.$onRenderResolve$=void 0),e.$flags$&512&&Wt(()=>Xt(e,!1)),e.$flags$&=-517},zn=e=>{as(ze.documentElement),Wt(()=>Yr(gt,"appload",{detail:{namespace:cn}}))},Hn=(e,t,r,s)=>{if(e&&e[t])try{return e[t](r)}catch(n){mt(n,s)}},as=e=>{var t;return e.classList.add((t=Ue.hydratedSelectorName)!=null?t:"hydrated")},Bn=(e,t)=>ke(e).$instanceValues$.get(t),ns=(e,t,r,s)=>{const n=ke(e),o=e,a=n.$instanceValues$.get(t),c=n.$flags$,u=o;r=qr(r,s.$members$[t][0]);const l=Number.isNaN(a)&&Number.isNaN(r);if(r!==a&&!l){n.$instanceValues$.set(t,r);{if(s.$watchers$&&c&128){const p=s.$watchers$[t];p&&p.map(m=>{try{u[m](r,a,t)}catch(b){mt(b,o)}})}(c&18)===2&&Xt(n,!1)}}},jn=(e,t,r)=>{var s,n;const o=e.prototype;if(t.$members$||t.$watchers$||e.watchers){e.watchers&&!t.$watchers$&&(t.$watchers$=e.watchers);const a=Object.entries((s=t.$members$)!=null?s:{});a.map(([c,[u]])=>{if(u&31||u&32){const{get:l,set:i}=Object.getOwnPropertyDescriptor(o,c)||{};l&&(t.$members$[c][0]|=2048),i&&(t.$members$[c][0]|=4096),Object.defineProperty(o,c,{get(){return l?l.apply(this):Bn(this,c)},configurable:!0,enumerable:!0}),Object.defineProperty(o,c,{set(p){const m=ke(this);if(i){const b=u&32?this[c]:m.$hostElement$[c];typeof b>"u"&&m.$instanceValues$.get(c)?p=m.$instanceValues$.get(c):!m.$instanceValues$.get(c)&&b&&m.$instanceValues$.set(c,b),i.apply(this,[qr(p,u)]),p=u&32?this[c]:m.$hostElement$[c],ns(this,c,p,t);return}{ns(this,c,p,t);return}}})}});{const c=new Map;o.attributeChangedCallback=function(u,l,i){ne.jmp(()=>{var p;const m=c.get(u);if(!(this.hasOwnProperty(m)&&Ue.lazyLoad)){if(o.hasOwnProperty(m)&&typeof this[m]=="number"&&this[m]==i)return;if(m==null){const v=ke(this),$=v==null?void 0:v.$flags$;if($&&!($&8)&&$&128&&i!==l){const K=this,_=(p=t.$watchers$)==null?void 0:p[u];_==null||_.forEach(Re=>{K[Re]!=null&&K[Re].call(K,i,l,u)})}return}}const b=Object.getOwnPropertyDescriptor(o,m);i=i===null&&typeof this[m]=="boolean"?!1:i,i!==this[m]&&(!b.get||b.set)&&(this[m]=i)})},e.observedAttributes=Array.from(new Set([...Object.keys((n=t.$watchers$)!=null?n:{}),...a.filter(([u,l])=>l[0]&15).map(([u,l])=>{const i=l[1]||u;return c.set(i,u),i})]))}}return e},Vn=async(e,t,r,s)=>{if(!(t.$flags$&32)){t.$flags$|=32;{const a=e.localName;customElements.whenDefined(a).then(()=>t.$flags$|=128)}}const n=t.$ancestorComponent$,o=()=>Xt(t,!0);n&&n["s-rc"]?n["s-rc"].push(o):o()},Wn=(e,t)=>{},Gn=e=>{if(!(ne.$flags$&1)){const t=ke(e),r=t.$cmpMeta$,s=Je("connectedCallback",r.$tagName$);if(t.$flags$&1)t!=null&&t.$lazyInstance$||t!=null&&t.$onReadyPromise$&&t.$onReadyPromise$.then(()=>Wn());else{t.$flags$|=1,r.$flags$&12&&qn(e);{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){ss(t,t.$ancestorComponent$=n);break}}r.$members$&&Object.entries(r.$members$).map(([n,[o]])=>{if(o&31&&e.hasOwnProperty(n)){const a=e[n];delete e[n],e[n]=a}}),Vn(e,t)}s()}},qn=e=>{const t=e["s-cr"]=ze.createComment("");t["s-cn"]=!0,xe(e,t,e.firstChild)},Yn=async e=>{ne.$flags$&1||ke(e),bt.has(e)&&bt.delete(e),e.shadowRoot&&bt.has(e.shadowRoot)&&bt.delete(e.shadowRoot)},U=(e,t)=>{const r={$flags$:t[0],$tagName$:t[1]};r.$members$=t[2],r.$watchers$=e.$watchers$;const s=e.prototype.connectedCallback,n=e.prototype.disconnectedCallback;return Object.assign(e.prototype,{__hasHostListenerAttached:!1,__registerHost(){mn(this,r)},connectedCallback(){this.__hasHostListenerAttached||(ke(this),this.__hasHostListenerAttached=!0),Gn(this),s&&s.call(this)},disconnectedCallback(){Yn(this),n&&n.call(this),ne.raf(()=>{var o;const a=ke(this);((o=a==null?void 0:a.$vnode$)==null?void 0:o.$elm$)instanceof Node&&!a.$vnode$.$elm$.isConnected&&delete a.$vnode$,this instanceof Node&&!this.isConnected&&pn(this)})},__attachShadow(){this.shadowRoot=this}}),e.is=r.$tagName$,jn(e,r)},Jt=(e,t)=>t,Qn=Object.defineProperty,Kn=(e,t,r)=>t in e?Qn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,os=(e,t,r)=>Kn(e,typeof t!="symbol"?t+"":t,r),_e=(e=>(e[e.DEBUG=0]="DEBUG",e[e.INFO=1]="INFO",e[e.WARN=2]="WARN",e[e.ERROR=3]="ERROR",e))(_e||{});class Xn{constructor(t){os(this,"logLevel"),os(this,"logFormatter"),this.logLevel=t.logLevel||1,this.logFormatter=t.logFormatter||this.defaultFormatter}defaultFormatter(t,r){return`[${_e[t]}] ${new Date().toISOString()}: ${r}`}debug(t){this.logLevel<=0&&console.log(this.logFormatter(0,t))}info(t){this.logLevel<=1&&console.info(this.logFormatter(1,t))}warn(t){this.logLevel<=2&&console.warn(this.logFormatter(2,t))}error(t){this.logLevel<=3&&console.error(this.logFormatter(3,t))}log(t,r){switch(t){case 0:this.debug(r);break;case 1:this.info(r);break;case 2:this.warn(r);break;case 3:this.error(r);break}}}function Ae(e,t,r,s){return new(r||(r=Promise))(function(n,o){function a(l){try{u(s.next(l))}catch(i){o(i)}}function c(l){try{u(s.throw(l))}catch(i){o(i)}}function u(l){var i;l.done?n(l.value):(i=l.value,i instanceof r?i:new r(function(p){p(i)})).then(a,c)}u((s=s.apply(e,[])).next())})}function Ie(e,t){var r,s,n,o,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(u){return function(l){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(a=0)),a;)try{if(r=1,s&&(n=2&i[0]?s.return:i[0]?s.throw||((n=s.return)&&n.call(s),0):s.next)&&!(n=n.call(s,i[1])).done)return n;switch(s=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,s=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(n=a.trys,!((n=n.length>0&&n[n.length-1])||i[0]!==6&&i[0]!==2)){a=0;continue}if(i[0]===3&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(i[0]===6&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(p){i=[6,p],s=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([u,l])}}}var Et={exclude:[]},Jn={},pe=function(e,t){typeof window<"u"&&(Jn[e]=t)};function Pt(e){return e^=e>>>16,e=Math.imul(e,2246822507),e^=e>>>13,e=Math.imul(e,3266489909),(e^=e>>>16)>>>0}var Q=new Uint32Array([597399067,2869860233,951274213,2716044179]);function he(e,t){return e<<t|e>>>32-t}function is(e,t){var r;if(t===void 0&&(t=0),t=t?0|t:0,typeof e=="string"&&(r=e,e=new TextEncoder().encode(r).buffer),!(e instanceof ArrayBuffer))throw new TypeError("Expected key to be ArrayBuffer or string");var s=new Uint32Array([t,t,t,t]);(function(o,a){for(var c=o.byteLength/16|0,u=new Uint32Array(o,0,4*c),l=0;l<c;l++){var i=u.subarray(4*l,4*(l+1));i[0]=Math.imul(i[0],Q[0]),i[0]=he(i[0],15),i[0]=Math.imul(i[0],Q[1]),a[0]=a[0]^i[0],a[0]=he(a[0],19),a[0]=a[0]+a[1],a[0]=Math.imul(a[0],5)+1444728091,i[1]=Math.imul(i[1],Q[1]),i[1]=he(i[1],16),i[1]=Math.imul(i[1],Q[2]),a[1]=a[1]^i[1],a[1]=he(a[1],17),a[1]=a[1]+a[2],a[1]=Math.imul(a[1],5)+197830471,i[2]=Math.imul(i[2],Q[2]),i[2]=he(i[2],17),i[2]=Math.imul(i[2],Q[3]),a[2]=a[2]^i[2],a[2]=he(a[2],15),a[2]=a[2]+a[3],a[2]=Math.imul(a[2],5)+2530024501,i[3]=Math.imul(i[3],Q[3]),i[3]=he(i[3],18),i[3]=Math.imul(i[3],Q[0]),a[3]=a[3]^i[3],a[3]=he(a[3],13),a[3]=a[3]+a[0],a[3]=Math.imul(a[3],5)+850148119}})(e,s),function(o,a){var c=o.byteLength/16|0,u=o.byteLength%16,l=new Uint32Array(4),i=new Uint8Array(o,16*c,u);switch(u){case 15:l[3]=l[3]^i[14]<<16;case 14:l[3]=l[3]^i[13]<<8;case 13:l[3]=l[3]^i[12]<<0,l[3]=Math.imul(l[3],Q[3]),l[3]=he(l[3],18),l[3]=Math.imul(l[3],Q[0]),a[3]=a[3]^l[3];case 12:l[2]=l[2]^i[11]<<24;case 11:l[2]=l[2]^i[10]<<16;case 10:l[2]=l[2]^i[9]<<8;case 9:l[2]=l[2]^i[8]<<0,l[2]=Math.imul(l[2],Q[2]),l[2]=he(l[2],17),l[2]=Math.imul(l[2],Q[3]),a[2]=a[2]^l[2];case 8:l[1]=l[1]^i[7]<<24;case 7:l[1]=l[1]^i[6]<<16;case 6:l[1]=l[1]^i[5]<<8;case 5:l[1]=l[1]^i[4]<<0,l[1]=Math.imul(l[1],Q[1]),l[1]=he(l[1],16),l[1]=Math.imul(l[1],Q[2]),a[1]=a[1]^l[1];case 4:l[0]=l[0]^i[3]<<24;case 3:l[0]=l[0]^i[2]<<16;case 2:l[0]=l[0]^i[1]<<8;case 1:l[0]=l[0]^i[0]<<0,l[0]=Math.imul(l[0],Q[0]),l[0]=he(l[0],15),l[0]=Math.imul(l[0],Q[1]),a[0]=a[0]^l[0]}}(e,s),function(o,a){a[0]=a[0]^o.byteLength,a[1]=a[1]^o.byteLength,a[2]=a[2]^o.byteLength,a[3]=a[3]^o.byteLength,a[0]=a[0]+a[1]|0,a[0]=a[0]+a[2]|0,a[0]=a[0]+a[3]|0,a[1]=a[1]+a[0]|0,a[2]=a[2]+a[0]|0,a[3]=a[3]+a[0]|0,a[0]=Pt(a[0]),a[1]=Pt(a[1]),a[2]=Pt(a[2]),a[3]=Pt(a[3]),a[0]=a[0]+a[1]|0,a[0]=a[0]+a[2]|0,a[0]=a[0]+a[3]|0,a[1]=a[1]+a[0]|0,a[2]=a[2]+a[0]|0,a[3]=a[3]+a[0]|0}(e,s);var n=new Uint8Array(s.buffer);return Array.from(n).map(function(o){return o.toString(16).padStart(2,"0")}).join("")}function Zn(e){for(var t=0,r=0;r<e.length;++r)t+=Math.abs(e[r]);return t}function cs(e,t,r){for(var s=[],n=0;n<e[0].data.length;n++){for(var o=[],a=0;a<e.length;a++)o.push(e[a].data[n]);s.push(eo(o))}var c=new Uint8ClampedArray(s);return new ImageData(c,t,r)}function eo(e){if(e.length===0)return 0;for(var t={},r=0,s=e;r<s.length;r++)t[o=s[r]]=(t[o]||0)+1;var n=e[0];for(var o in t)t[o]>t[n]&&(n=parseInt(o,10));return n}function tt(){if(typeof navigator>"u")return{name:"unknown",version:"unknown"};for(var e=navigator.userAgent,t={Edg:"Edge",OPR:"Opera"},r=0,s=[/(?<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<s.length;r++){var n=s[r],o=e.match(n);if(o&&o.groups)return{name:t[o.groups.name]||o.groups.name,version:o.groups.version}}return{name:"unknown",version:"unknown"}}pe("audio",function(){return Ae(this,void 0,void 0,function(){return Ie(this,function(e){return[2,new Promise(function(t,r){try{var s=new(window.OfflineAudioContext||window.webkitOfflineAudioContext)(1,5e3,44100),n=s.createBufferSource(),o=s.createOscillator();o.frequency.value=1e3;var a,c=s.createDynamicsCompressor();c.threshold.value=-50,c.knee.value=40,c.ratio.value=12,c.attack.value=0,c.release.value=.2,o.connect(c),c.connect(s.destination),o.start(),s.oncomplete=function(u){a=u.renderedBuffer.getChannelData(0),t({sampleHash:Zn(a),oscillator:o.type,maxChannels:s.destination.maxChannelCount,channelCountMode:n.channelCountMode})},s.startRendering()}catch(u){console.error("Error creating audio fingerprint:",u),r(u)}})]})})});var to=tt().name!=="SamsungBrowser"?1:3,ls=280,us=20;tt().name!="Firefox"&&pe("canvas",function(){return document.createElement("canvas").getContext("2d"),new Promise(function(e){var t=Array.from({length:to},function(){return function(){var r=document.createElement("canvas"),s=r.getContext("2d");if(!s)return new ImageData(1,1);r.width=ls,r.height=us;var n=s.createLinearGradient(0,0,r.width,r.height);n.addColorStop(0,"red"),n.addColorStop(.16666666666666666,"orange"),n.addColorStop(.3333333333333333,"yellow"),n.addColorStop(.5,"green"),n.addColorStop(.6666666666666666,"blue"),n.addColorStop(.8333333333333334,"indigo"),n.addColorStop(1,"violet"),s.fillStyle=n,s.fillRect(0,0,r.width,r.height);var o="Random Text WMwmil10Oo";s.font="23.123px Arial",s.fillStyle="black",s.fillText(o,-5,15),s.fillStyle="rgba(0, 0, 255, 0.5)",s.fillText(o,-3.3,17.7),s.beginPath(),s.moveTo(0,0),s.lineTo(2*r.width/7,r.height),s.strokeStyle="white",s.lineWidth=2,s.stroke();var a=s.getImageData(0,0,r.width,r.height);return a}()});e({commonImageDataHash:is(cs(t,ls,us).data.toString()).toString()})})});var Zt,ro=["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"],so=["monospace","sans-serif","serif"];function hs(e,t){if(!e)throw new Error("Canvas context not supported");return e.font="72px ".concat(t),e.measureText("WwMmLli0Oo").width}function ao(){var e,t=document.createElement("canvas"),r=(e=t.getContext("webgl"))!==null&&e!==void 0?e:t.getContext("experimental-webgl");if(r&&"getParameter"in r)try{var s=(r.getParameter(r.VENDOR)||"").toString(),n=(r.getParameter(r.RENDERER)||"").toString(),o={vendor:s,renderer:n,version:(r.getParameter(r.VERSION)||"").toString(),shadingLanguageVersion:(r.getParameter(r.SHADING_LANGUAGE_VERSION)||"").toString()};if(!n.length||!s.length){var a=r.getExtension("WEBGL_debug_renderer_info");if(a){var c=(r.getParameter(a.UNMASKED_VENDOR_WEBGL)||"").toString(),u=(r.getParameter(a.UNMASKED_RENDERER_WEBGL)||"").toString();c&&(o.vendorUnmasked=c),u&&(o.rendererUnmasked=u)}}return o}catch{}return"undefined"}function no(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],t[3]}function oo(e,t){var r={};return t.forEach(function(s){var n=function(o){if(o.length===0)return null;var a={};o.forEach(function(l){var i=String(l);a[i]=(a[i]||0)+1});var c=o[0],u=1;return Object.keys(a).forEach(function(l){a[l]>u&&(c=l,u=a[l])}),c}(e.map(function(o){return s in o?o[s]:void 0}).filter(function(o){return o!==void 0}));n&&(r[s]=n)}),r}function io(){var e=[],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"]};return Object.keys(t).forEach(function(r){t[r].forEach(function(s){matchMedia("(".concat(r,": ").concat(s,")")).matches&&e.push("".concat(r,": ").concat(s))})}),e}function co(){if(window.location.protocol==="https:"&&typeof window.ApplePaySession=="function")try{for(var e=window.ApplePaySession.supportsVersion,t=15;t>0;t--)if(e(t))return t}catch{return 0}return 0}tt().name!="Firefox"&&pe("fonts",function(){var e=this;return new Promise(function(t,r){try{(function(s){var n;Ae(this,void 0,void 0,function(){var o,a,c;return Ie(this,function(u){switch(u.label){case 0:return document.body?[3,2]:[4,(l=50,new Promise(function(p){return setTimeout(p,l,i)}))];case 1:return u.sent(),[3,0];case 2:if((o=document.createElement("iframe")).setAttribute("frameBorder","0"),(a=o.style).setProperty("position","fixed"),a.setProperty("display","block","important"),a.setProperty("visibility","visible"),a.setProperty("border","0"),a.setProperty("opacity","0"),o.src="about:blank",document.body.appendChild(o),!(c=o.contentDocument||((n=o.contentWindow)===null||n===void 0?void 0:n.document)))throw new Error("Iframe document is not accessible");return s({iframe:c}),setTimeout(function(){document.body.removeChild(o)},0),[2]}var l,i})})})(function(s){var n=s.iframe;return Ae(e,void 0,void 0,function(){var o,a,c,u;return Ie(this,function(l){return o=n.createElement("canvas"),a=o.getContext("2d"),c=so.map(function(i){return hs(a,i)}),u={},ro.forEach(function(i){var p=hs(a,i);c.includes(p)||(u[i]=p)}),t(u),[2]})})})}catch{r({error:"unsupported"})}})}),pe("hardware",function(){return new Promise(function(e,t){var r=navigator.deviceMemory!==void 0?navigator.deviceMemory:0,s=window.performance&&window.performance.memory?window.performance.memory:0;e({videocard:ao(),architecture:no(),deviceMemory:r.toString()||"undefined",jsHeapSizeLimit:s.jsHeapSizeLimit||0})})}),pe("locales",function(){return new Promise(function(e){e({languages:navigator.language,timezone:Intl.DateTimeFormat().resolvedOptions().timeZone})})}),pe("permissions",function(){return Ae(this,void 0,void 0,function(){var e;return Ie(this,function(t){return Zt=(Et==null?void 0:Et.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"],e=Array.from({length:(Et==null?void 0:Et.retries)||3},function(){return function(){return Ae(this,void 0,void 0,function(){var r,s,n,o,a;return Ie(this,function(c){switch(c.label){case 0:r={},s=0,n=Zt,c.label=1;case 1:if(!(s<n.length))return[3,6];o=n[s],c.label=2;case 2:return c.trys.push([2,4,,5]),[4,navigator.permissions.query({name:o})];case 3:return a=c.sent(),r[o]=a.state.toString(),[3,5];case 4:return c.sent(),[3,5];case 5:return s++,[3,1];case 6:return[2,r]}})})}()}),[2,Promise.all(e).then(function(r){return oo(r,Zt)})]})})}),pe("plugins",function(){var e=[];if(navigator.plugins)for(var t=0;t<navigator.plugins.length;t++){var r=navigator.plugins[t];e.push([r.name,r.filename,r.description].join("|"))}return new Promise(function(s){s({plugins:e})})}),pe("screen",function(){return new Promise(function(e){e({is_touchscreen:navigator.maxTouchPoints>0,maxTouchPoints:navigator.maxTouchPoints,colorDepth:screen.colorDepth,mediaMatches:io()})})}),pe("system",function(){return new Promise(function(e){var t=tt();e({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:co()})})});var ee,lo=tt().name!=="SamsungBrowser"?1:3,E=null;pe("webgl",function(){return Ae(this,void 0,void 0,function(){var e;return Ie(this,function(t){typeof document<"u"&&((ee=document.createElement("canvas")).width=200,ee.height=100,E=ee.getContext("webgl"));try{if(!E)throw new Error("WebGL not supported");return e=Array.from({length:lo},function(){return function(){try{if(!E)throw new Error("WebGL not supported");var r=`
12
12
  attribute vec2 position;
13
13
  void main() {
14
14
  gl_Position = vec4(position, 0.0, 1.0);
15
15
  }
16
- `,a=`
16
+ `,s=`
17
17
  precision mediump float;
18
18
  void main() {
19
19
  gl_FragColor = vec4(0.812, 0.195, 0.553, 0.921); // Set line color
20
20
  }
21
- `,n=R.createShader(R.VERTEX_SHADER),o=R.createShader(R.FRAGMENT_SHADER);if(!n||!o)throw new Error("Failed to create shaders");if(R.shaderSource(n,r),R.shaderSource(o,a),R.compileShader(n),!R.getShaderParameter(n,R.COMPILE_STATUS))throw new Error("Vertex shader compilation failed: "+R.getShaderInfoLog(n));if(R.compileShader(o),!R.getShaderParameter(o,R.COMPILE_STATUS))throw new Error("Fragment shader compilation failed: "+R.getShaderInfoLog(o));var s=R.createProgram();if(!s)throw new Error("Failed to create shader program");if(R.attachShader(s,n),R.attachShader(s,o),R.linkProgram(s),!R.getProgramParameter(s,R.LINK_STATUS))throw new Error("Shader program linking failed: "+R.getProgramInfoLog(s));R.useProgram(s);for(var c=137,u=new Float32Array(4*c),l=2*Math.PI/c,i=0;i<c;i++){var p=i*l;u[4*i]=0,u[4*i+1]=0,u[4*i+2]=Math.cos(p)*(Z.width/2),u[4*i+3]=Math.sin(p)*(Z.height/2)}var g=R.createBuffer();R.bindBuffer(R.ARRAY_BUFFER,g),R.bufferData(R.ARRAY_BUFFER,u,R.STATIC_DRAW);var S=R.getAttribLocation(s,"position");R.enableVertexAttribArray(S),R.vertexAttribPointer(S,2,R.FLOAT,!1,0,0),R.viewport(0,0,Z.width,Z.height),R.clearColor(0,0,0,1),R.clear(R.COLOR_BUFFER_BIT),R.drawArrays(R.LINES,0,2*c);var P=new Uint8ClampedArray(Z.width*Z.height*4);return R.readPixels(0,0,Z.width,Z.height,R.RGBA,R.UNSIGNED_BYTE,P),new ImageData(P,Z.width,Z.height)}catch{return new ImageData(1,1)}finally{R&&(R.bindBuffer(R.ARRAY_BUFFER,null),R.useProgram(null),R.viewport(0,0,R.drawingBufferWidth,R.drawingBufferHeight),R.clearColor(0,0,0,0))}}()}),[2,{commonImageHash:ia(ca(e,Z.width,Z.height).data.toString()).toString()}]}catch{return[2,{webgl:"unsupported"}]}return[2]})})});var Me=function(e,t,r,a){for(var n=(r-t)/a,o=0,s=0;s<a;s++)o+=e(t+(s+.5)*n);return o*n};de("math",function(){return Ae(void 0,void 0,void 0,function(){return Ie(this,function(e){return[2,{acos:Math.acos(.5),asin:Me(Math.asin,-1,1,97),atan:Me(Math.atan,-1,1,97),cos:Me(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:Me(Math.sin,-Math.PI,Math.PI,97),sinh:Me(Math.sinh,-9/7,7/9,97),sqrt:Math.sqrt(2),tan:Me(Math.tan,0,2*Math.PI,97),tanh:Me(Math.tanh,-9/7,7/9,97)}]})})});var fa={},er={};const da=e=>{let t;const r=new Set,a=(l,i)=>{const p=typeof l=="function"?l(t):l;if(!Object.is(p,t)){const g=t;t=i??(typeof p!="object"||p===null)?p:Object.assign({},t,p),r.forEach(S=>S(t,g))}},n=()=>t,c={setState:a,getState:n,getInitialState:()=>u,subscribe:l=>(r.add(l),()=>r.delete(l))},u=t=e(a,n,c);return c},co=e=>e?da(e):da;er.createStore=co;var tr={},pa={exports:{}},E={};/**
21
+ `,n=E.createShader(E.VERTEX_SHADER),o=E.createShader(E.FRAGMENT_SHADER);if(!n||!o)throw new Error("Failed to create shaders");if(E.shaderSource(n,r),E.shaderSource(o,s),E.compileShader(n),!E.getShaderParameter(n,E.COMPILE_STATUS))throw new Error("Vertex shader compilation failed: "+E.getShaderInfoLog(n));if(E.compileShader(o),!E.getShaderParameter(o,E.COMPILE_STATUS))throw new Error("Fragment shader compilation failed: "+E.getShaderInfoLog(o));var a=E.createProgram();if(!a)throw new Error("Failed to create shader program");if(E.attachShader(a,n),E.attachShader(a,o),E.linkProgram(a),!E.getProgramParameter(a,E.LINK_STATUS))throw new Error("Shader program linking failed: "+E.getProgramInfoLog(a));E.useProgram(a);for(var c=137,u=new Float32Array(4*c),l=2*Math.PI/c,i=0;i<c;i++){var p=i*l;u[4*i]=0,u[4*i+1]=0,u[4*i+2]=Math.cos(p)*(ee.width/2),u[4*i+3]=Math.sin(p)*(ee.height/2)}var m=E.createBuffer();E.bindBuffer(E.ARRAY_BUFFER,m),E.bufferData(E.ARRAY_BUFFER,u,E.STATIC_DRAW);var b=E.getAttribLocation(a,"position");E.enableVertexAttribArray(b),E.vertexAttribPointer(b,2,E.FLOAT,!1,0,0),E.viewport(0,0,ee.width,ee.height),E.clearColor(0,0,0,1),E.clear(E.COLOR_BUFFER_BIT),E.drawArrays(E.LINES,0,2*c);var v=new Uint8ClampedArray(ee.width*ee.height*4);return E.readPixels(0,0,ee.width,ee.height,E.RGBA,E.UNSIGNED_BYTE,v),new ImageData(v,ee.width,ee.height)}catch{return new ImageData(1,1)}finally{E&&(E.bindBuffer(E.ARRAY_BUFFER,null),E.useProgram(null),E.viewport(0,0,E.drawingBufferWidth,E.drawingBufferHeight),E.clearColor(0,0,0,0))}}()}),[2,{commonImageHash:is(cs(e,ee.width,ee.height).data.toString()).toString()}]}catch{return[2,{webgl:"unsupported"}]}return[2]})})});var Me=function(e,t,r,s){for(var n=(r-t)/s,o=0,a=0;a<s;a++)o+=e(t+(a+.5)*n);return o*n};pe("math",function(){return Ae(void 0,void 0,void 0,function(){return Ie(this,function(e){return[2,{acos:Math.acos(.5),asin:Me(Math.asin,-1,1,97),atan:Me(Math.atan,-1,1,97),cos:Me(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:Me(Math.sin,-Math.PI,Math.PI,97),sinh:Me(Math.sinh,-9/7,7/9,97),sqrt:Math.sqrt(2),tan:Me(Math.tan,0,2*Math.PI,97),tanh:Me(Math.tanh,-9/7,7/9,97)}]})})});var ds={},er={};const fs=e=>{let t;const r=new Set,s=(l,i)=>{const p=typeof l=="function"?l(t):l;if(!Object.is(p,t)){const m=t;t=i??(typeof p!="object"||p===null)?p:Object.assign({},t,p),r.forEach(b=>b(t,m))}},n=()=>t,c={setState:s,getState:n,getInitialState:()=>u,subscribe:l=>(r.add(l),()=>r.delete(l))},u=t=e(s,n,c);return c},uo=e=>e?fs(e):fs;er.createStore=uo;var tr={},ps={exports:{}},P={};/**
22
22
  * @license React
23
23
  * react.production.js
24
24
  *
@@ -26,11 +26,11 @@
26
26
  *
27
27
  * This source code is licensed under the MIT license found in the
28
28
  * LICENSE file in the root directory of this source tree.
29
- */var rr=Symbol.for("react.transitional.element"),lo=Symbol.for("react.portal"),uo=Symbol.for("react.fragment"),ho=Symbol.for("react.strict_mode"),fo=Symbol.for("react.profiler"),po=Symbol.for("react.consumer"),mo=Symbol.for("react.context"),go=Symbol.for("react.forward_ref"),bo=Symbol.for("react.suspense"),vo=Symbol.for("react.memo"),ma=Symbol.for("react.lazy"),ga=Symbol.iterator;function yo(e){return e===null||typeof e!="object"?null:(e=ga&&e[ga]||e["@@iterator"],typeof e=="function"?e:null)}var ba={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},va=Object.assign,ya={};function Be(e,t,r){this.props=e,this.context=t,this.refs=ya,this.updater=r||ba}Be.prototype.isReactComponent={},Be.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},Be.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Sa(){}Sa.prototype=Be.prototype;function ar(e,t,r){this.props=e,this.context=t,this.refs=ya,this.updater=r||ba}var sr=ar.prototype=new Sa;sr.constructor=ar,va(sr,Be.prototype),sr.isPureReactComponent=!0;var wa=Array.isArray,I={H:null,A:null,T:null,S:null},Ra=Object.prototype.hasOwnProperty;function nr(e,t,r,a,n,o){return r=o.ref,{$$typeof:rr,type:e,key:t,ref:r!==void 0?r:null,props:o}}function So(e,t){return nr(e.type,t,void 0,void 0,void 0,e.props)}function or(e){return typeof e=="object"&&e!==null&&e.$$typeof===rr}function wo(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var Ea=/\/+/g;function ir(e,t){return typeof e=="object"&&e!==null&&e.key!=null?wo(""+e.key):t.toString(36)}function Pa(){}function Ro(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(Pa,Pa):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function je(e,t,r,a,n){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(o){case"bigint":case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case rr:case lo:s=!0;break;case ma:return s=e._init,je(s(e._payload),t,r,a,n)}}if(s)return n=n(e),s=a===""?"."+ir(e,0):a,wa(n)?(r="",s!=null&&(r=s.replace(Ea,"$&/")+"/"),je(n,t,r,"",function(l){return l})):n!=null&&(or(n)&&(n=So(n,r+(n.key==null||e&&e.key===n.key?"":(""+n.key).replace(Ea,"$&/")+"/")+s)),t.push(n)),1;s=0;var c=a===""?".":a+":";if(wa(e))for(var u=0;u<e.length;u++)a=e[u],o=c+ir(a,u),s+=je(a,t,r,o,n);else if(u=yo(e),typeof u=="function")for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,o=c+ir(a,u++),s+=je(a,t,r,o,n);else if(o==="object"){if(typeof e.then=="function")return je(Ro(e),t,r,a,n);throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return s}function kt(e,t,r){if(e==null)return e;var a=[],n=0;return je(e,a,"","",function(o){return t.call(r,o,n++)}),a}function Eo(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ka=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function Po(){}E.Children={map:kt,forEach:function(e,t,r){kt(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return kt(e,function(){t++}),t},toArray:function(e){return kt(e,function(t){return t})||[]},only:function(e){if(!or(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},E.Component=Be,E.Fragment=uo,E.Profiler=fo,E.PureComponent=ar,E.StrictMode=ho,E.Suspense=bo,E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=I,E.act=function(){throw Error("act(...) is not supported in production builds of React.")},E.cache=function(e){return function(){return e.apply(null,arguments)}},E.cloneElement=function(e,t,r){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var a=va({},e.props),n=e.key,o=void 0;if(t!=null)for(s in t.ref!==void 0&&(o=void 0),t.key!==void 0&&(n=""+t.key),t)!Ra.call(t,s)||s==="key"||s==="__self"||s==="__source"||s==="ref"&&t.ref===void 0||(a[s]=t[s]);var s=arguments.length-2;if(s===1)a.children=r;else if(1<s){for(var c=Array(s),u=0;u<s;u++)c[u]=arguments[u+2];a.children=c}return nr(e.type,n,void 0,void 0,o,a)},E.createContext=function(e){return e={$$typeof:mo,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:po,_context:e},e},E.createElement=function(e,t,r){var a,n={},o=null;if(t!=null)for(a in t.key!==void 0&&(o=""+t.key),t)Ra.call(t,a)&&a!=="key"&&a!=="__self"&&a!=="__source"&&(n[a]=t[a]);var s=arguments.length-2;if(s===1)n.children=r;else if(1<s){for(var c=Array(s),u=0;u<s;u++)c[u]=arguments[u+2];n.children=c}if(e&&e.defaultProps)for(a in s=e.defaultProps,s)n[a]===void 0&&(n[a]=s[a]);return nr(e,o,void 0,void 0,null,n)},E.createRef=function(){return{current:null}},E.forwardRef=function(e){return{$$typeof:go,render:e}},E.isValidElement=or,E.lazy=function(e){return{$$typeof:ma,_payload:{_status:-1,_result:e},_init:Eo}},E.memo=function(e,t){return{$$typeof:vo,type:e,compare:t===void 0?null:t}},E.startTransition=function(e){var t=I.T,r={};I.T=r;try{var a=e(),n=I.S;n!==null&&n(r,a),typeof a=="object"&&a!==null&&typeof a.then=="function"&&a.then(Po,ka)}catch(o){ka(o)}finally{I.T=t}},E.unstable_useCacheRefresh=function(){return I.H.useCacheRefresh()},E.use=function(e){return I.H.use(e)},E.useActionState=function(e,t,r){return I.H.useActionState(e,t,r)},E.useCallback=function(e,t){return I.H.useCallback(e,t)},E.useContext=function(e){return I.H.useContext(e)},E.useDebugValue=function(){},E.useDeferredValue=function(e,t){return I.H.useDeferredValue(e,t)},E.useEffect=function(e,t){return I.H.useEffect(e,t)},E.useId=function(){return I.H.useId()},E.useImperativeHandle=function(e,t,r){return I.H.useImperativeHandle(e,t,r)},E.useInsertionEffect=function(e,t){return I.H.useInsertionEffect(e,t)},E.useLayoutEffect=function(e,t){return I.H.useLayoutEffect(e,t)},E.useMemo=function(e,t){return I.H.useMemo(e,t)},E.useOptimistic=function(e,t){return I.H.useOptimistic(e,t)},E.useReducer=function(e,t,r){return I.H.useReducer(e,t,r)},E.useRef=function(e){return I.H.useRef(e)},E.useState=function(e){return I.H.useState(e)},E.useSyncExternalStore=function(e,t,r){return I.H.useSyncExternalStore(e,t,r)},E.useTransition=function(){return I.H.useTransition()},E.version="19.0.0",pa.exports=E;var Ta=pa.exports,ko=er;const To=e=>e;function Ca(e,t=To){const r=Ta.useSyncExternalStore(e.subscribe,()=>t(e.getState()),()=>t(e.getInitialState()));return Ta.useDebugValue(r),r}const xa=e=>{const t=ko.createStore(e),r=a=>Ca(t,a);return Object.assign(r,t),r},Co=e=>e?xa(e):xa;tr.create=Co,tr.useStore=Ca,function(e){var t=er,r=tr;Object.keys(t).forEach(function(a){a!=="default"&&!Object.prototype.hasOwnProperty.call(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:function(){return t[a]}})}),Object.keys(r).forEach(function(a){a!=="default"&&!Object.prototype.hasOwnProperty.call(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:function(){return r[a]}})})}(fa);const xo={adClientResponseItems:[],core:void 0,logger:void 0,facetPathsForIndexFields:{},isPopoverVisible:!1,isSearchInProgress:!1,searchTerm:"",rangeValueForIndexFields:{},searchMode:"fuzzy",searchClientResponseItems:[],searchResponseTimeTaken:void 0,searchResponseFacetPrime:void 0,searchResultsCount:0,searchResultsPerPage:20,searchResultsPage:1,sortType:"asc"},_=fa.createStore((e,t)=>{const r={addFacetPathsForIndexField:n=>e(o=>({facetPathsForIndexFields:{...o.facetPathsForIndexFields,[n.fieldName]:n}})),addRangeValueForIndexField:n=>e(o=>({rangeValueForIndexFields:{...o.rangeValueForIndexFields,[n.fieldName]:n}})),getSearchcraftInstance:()=>{const{core:n}=t();return n},initialize:(n,o=!1)=>{const s=n,c=o?new Kn({logLevel:_e.DEBUG}):void 0;e({core:s,logger:c,searchResultsPerPage:s.config.searchResultsPerPage||20})},removeFacetPathsForIndexField:n=>e(o=>{const s=o.facetPathsForIndexFields;return delete s[n],{facetPathsForIndexFields:{...s}}}),removeRangeValueForIndexField:n=>e(o=>{const s=o.rangeValueForIndexFields;return delete s[n],{rangeValueForIndexFields:{...s}}}),resetFacetPaths:()=>{e({facetPathsForIndexFields:{}})},search:async()=>{var c,u;const n=t();if((c=n.logger)==null||c.log(_e.INFO,`Starting search with search term: "${n.searchTerm}"`),!n.core)throw new Error("Searchcraft instance is not initialized.");if(!n.searchTerm.trim()){(u=n.logger)==null||u.log(_e.INFO,"No search request was made: search term was empty."),e({searchClientResponseItems:[],searchResultsCount:0,searchResultsPage:1,searchTerm:""});return}e({isSearchInProgress:!0});const o=(l,i)=>{var g,S;const p=l.data.facets;e(P=>({isSearchInProgress:!1,searchClientResponseItems:i,searchResponseTimeTaken:l.data.time_taken||0,searchResultsPage:l.data.count===P.searchResultsCount?P.searchResultsPage:1,searchResultsCount:l.data.count||0})),p&&e({searchResponseFacetPrime:p}),(g=n.logger)==null||g.log(_e.DEBUG,`Search results: ${JSON.stringify(i)}`),(S=n.logger)==null||S.log(_e.DEBUG,`Facets from response: ${JSON.stringify(p)}`)},s=l=>{e({adClientResponseItems:l})};n.core.getItems({searchTerm:n.searchTerm,mode:n.searchMode,sort:n.sortType,facetPathsForIndexFields:n.facetPathsForIndexFields,rangeValueForIndexFields:n.rangeValueForIndexFields,offset:n.searchResultsPerPage?n.searchResultsPerPage*(n.searchResultsPage-1):0,limit:n.searchResultsPerPage},o,s)},setPopoverVisibility:n=>{e({isPopoverVisible:n})},setSearchMode:n=>e({searchMode:n}),setSortType:n=>e({sortType:n}),setSearchTerm:n=>{const{core:o}=t();o&&n.length===0&&o.emitEvent("input_cleared",{name:"input_cleared"}),e({searchTerm:n,facetPathsForIndexFields:{},...n.trim().length===0&&{searchMode:"fuzzy",sortType:"asc"}})},setSearchClientResponseItems:n=>e({searchClientResponseItems:n}),setSearchResultsPage:async n=>{e({searchResultsPage:n}),await r.search()},setSearchResultsPerPage:async n=>{e({searchResultsPerPage:n}),await r.search()}};return{...xo,...r}});var $o=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},$a={exports:{}};/*! @license DOMPurify 3.2.4 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.4/LICENSE */(function(e,t){(function(r,a){e.exports=a()})($o,function(){const{entries:r,setPrototypeOf:a,isFrozen:n,getPrototypeOf:o,getOwnPropertyDescriptor:s}=Object;let{freeze:c,seal:u,create:l}=Object,{apply:i,construct:p}=typeof Reflect<"u"&&Reflect;c||(c=function(v){return v}),u||(u=function(v){return v}),i||(i=function(v,x,C){return v.apply(x,C)}),p||(p=function(v,x){return new v(...x)});const g=ee(Array.prototype.forEach),S=ee(Array.prototype.lastIndexOf),P=ee(Array.prototype.pop),U=ee(Array.prototype.push),pe=ee(Array.prototype.splice),K=ee(String.prototype.toLowerCase),$=ee(String.prototype.toString),Re=ee(String.prototype.match),ce=ee(String.prototype.replace),Le=ee(String.prototype.indexOf),z=ee(String.prototype.trim),ne=ee(Object.prototype.hasOwnProperty),H=ee(RegExp.prototype.test),Oe=tc(TypeError);function ee(T){return function(v){for(var x=arguments.length,C=new Array(x>1?x-1:0),X=1;X<x;X++)C[X-1]=arguments[X];return i(T,v,C)}}function tc(T){return function(){for(var v=arguments.length,x=new Array(v),C=0;C<v;C++)x[C]=arguments[C];return p(T,x)}}function k(T,v){let x=arguments.length>2&&arguments[2]!==void 0?arguments[2]:K;a&&a(T,null);let C=v.length;for(;C--;){let X=v[C];if(typeof X=="string"){const Ee=x(X);Ee!==X&&(n(v)||(v[C]=Ee),X=Ee)}T[X]=!0}return T}function rc(T){for(let v=0;v<T.length;v++)ne(T,v)||(T[v]=null);return T}function Fe(T){const v=l(null);for(const[x,C]of r(T))ne(T,x)&&(Array.isArray(C)?v[x]=rc(C):C&&typeof C=="object"&&C.constructor===Object?v[x]=Fe(C):v[x]=C);return v}function st(T,v){for(;T!==null;){const C=s(T,v);if(C){if(C.get)return ee(C.get);if(typeof C.value=="function")return ee(C.value)}T=o(T)}function x(){return null}return x}const Ka=c(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),fr=c(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),dr=c(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),ac=c(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),pr=c(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),sc=c(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Xa=c(["#text"]),Qa=c(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),mr=c(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Ja=c(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),$t=c(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),nc=u(/\{\{[\w\W]*|[\w\W]*\}\}/gm),oc=u(/<%[\w\W]*|[\w\W]*%>/gm),ic=u(/\$\{[\w\W]*/gm),cc=u(/^data-[\-\w.\u00B7-\uFFFF]+$/),lc=u(/^aria-[\-\w]+$/),Za=u(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),uc=u(/^(?:\w+script|data):/i),hc=u(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),es=u(/^html$/i),fc=u(/^[a-z][.\w]*(-[.\w]+)+$/i);var ts=Object.freeze({__proto__:null,ARIA_ATTR:lc,ATTR_WHITESPACE:hc,CUSTOM_ELEMENT:fc,DATA_ATTR:cc,DOCTYPE_NAME:es,ERB_EXPR:oc,IS_ALLOWED_URI:Za,IS_SCRIPT_OR_DATA:uc,MUSTACHE_EXPR:nc,TMPLIT_EXPR:ic});const nt={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},dc=function(){return typeof window>"u"?null:window},pc=function(v,x){if(typeof v!="object"||typeof v.createPolicy!="function")return null;let C=null;const X="data-tt-policy-suffix";x&&x.hasAttribute(X)&&(C=x.getAttribute(X));const Ee="dompurify"+(C?"#"+C:"");try{return v.createPolicy(Ee,{createHTML(Ge){return Ge},createScriptURL(Ge){return Ge}})}catch{return console.warn("TrustedTypes policy "+Ee+" could not be created."),null}},rs=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function as(){let T=arguments.length>0&&arguments[0]!==void 0?arguments[0]:dc();const v=y=>as(y);if(v.version="3.2.4",v.removed=[],!T||!T.document||T.document.nodeType!==nt.document||!T.Element)return v.isSupported=!1,v;let{document:x}=T;const C=x,X=C.currentScript,{DocumentFragment:Ee,HTMLTemplateElement:Ge,Node:gr,Element:ss,NodeFilter:ot,NamedNodeMap:gc=T.NamedNodeMap||T.MozNamedAttrMap,HTMLFormElement:bc,DOMParser:vc,trustedTypes:_t}=T,it=ss.prototype,yc=st(it,"cloneNode"),Sc=st(it,"remove"),wc=st(it,"nextSibling"),Rc=st(it,"childNodes"),At=st(it,"parentNode");if(typeof Ge=="function"){const y=x.createElement("template");y.content&&y.content.ownerDocument&&(x=y.content.ownerDocument)}let te,ct="";const{implementation:br,createNodeIterator:Ec,createDocumentFragment:Pc,getElementsByTagName:kc}=x,{importNode:Tc}=C;let re=rs();v.isSupported=typeof r=="function"&&typeof At=="function"&&br&&br.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:vr,ERB_EXPR:yr,TMPLIT_EXPR:Sr,DATA_ATTR:Cc,ARIA_ATTR:xc,IS_SCRIPT_OR_DATA:$c,ATTR_WHITESPACE:ns,CUSTOM_ELEMENT:_c}=ts;let{IS_ALLOWED_URI:os}=ts,B=null;const is=k({},[...Ka,...fr,...dr,...pr,...Xa]);let W=null;const cs=k({},[...Qa,...mr,...Ja,...$t]);let O=Object.seal(l(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),lt=null,wr=null,ls=!0,Rr=!0,us=!1,hs=!0,We=!1,Er=!0,De=!1,Pr=!1,kr=!1,Ve=!1,It=!1,Mt=!1,fs=!0,ds=!1;const Ac="user-content-";let Tr=!0,ut=!1,qe={},Ye=null;const ps=k({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ms=null;const gs=k({},["audio","video","img","source","image","track"]);let Cr=null;const bs=k({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Lt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",Pe="http://www.w3.org/1999/xhtml";let Ke=Pe,xr=!1,$r=null;const Ic=k({},[Lt,Ot,Pe],$);let Ft=k({},["mi","mo","mn","ms","mtext"]),Dt=k({},["annotation-xml"]);const Mc=k({},["title","style","font","a","script"]);let ht=null;const Lc=["application/xhtml+xml","text/html"],Oc="text/html";let j=null,Xe=null;const Fc=x.createElement("form"),vs=function(f){return f instanceof RegExp||f instanceof Function},_r=function(){let f=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Xe&&Xe===f)){if((!f||typeof f!="object")&&(f={}),f=Fe(f),ht=Lc.indexOf(f.PARSER_MEDIA_TYPE)===-1?Oc:f.PARSER_MEDIA_TYPE,j=ht==="application/xhtml+xml"?$:K,B=ne(f,"ALLOWED_TAGS")?k({},f.ALLOWED_TAGS,j):is,W=ne(f,"ALLOWED_ATTR")?k({},f.ALLOWED_ATTR,j):cs,$r=ne(f,"ALLOWED_NAMESPACES")?k({},f.ALLOWED_NAMESPACES,$):Ic,Cr=ne(f,"ADD_URI_SAFE_ATTR")?k(Fe(bs),f.ADD_URI_SAFE_ATTR,j):bs,ms=ne(f,"ADD_DATA_URI_TAGS")?k(Fe(gs),f.ADD_DATA_URI_TAGS,j):gs,Ye=ne(f,"FORBID_CONTENTS")?k({},f.FORBID_CONTENTS,j):ps,lt=ne(f,"FORBID_TAGS")?k({},f.FORBID_TAGS,j):{},wr=ne(f,"FORBID_ATTR")?k({},f.FORBID_ATTR,j):{},qe=ne(f,"USE_PROFILES")?f.USE_PROFILES:!1,ls=f.ALLOW_ARIA_ATTR!==!1,Rr=f.ALLOW_DATA_ATTR!==!1,us=f.ALLOW_UNKNOWN_PROTOCOLS||!1,hs=f.ALLOW_SELF_CLOSE_IN_ATTR!==!1,We=f.SAFE_FOR_TEMPLATES||!1,Er=f.SAFE_FOR_XML!==!1,De=f.WHOLE_DOCUMENT||!1,Ve=f.RETURN_DOM||!1,It=f.RETURN_DOM_FRAGMENT||!1,Mt=f.RETURN_TRUSTED_TYPE||!1,kr=f.FORCE_BODY||!1,fs=f.SANITIZE_DOM!==!1,ds=f.SANITIZE_NAMED_PROPS||!1,Tr=f.KEEP_CONTENT!==!1,ut=f.IN_PLACE||!1,os=f.ALLOWED_URI_REGEXP||Za,Ke=f.NAMESPACE||Pe,Ft=f.MATHML_TEXT_INTEGRATION_POINTS||Ft,Dt=f.HTML_INTEGRATION_POINTS||Dt,O=f.CUSTOM_ELEMENT_HANDLING||{},f.CUSTOM_ELEMENT_HANDLING&&vs(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(O.tagNameCheck=f.CUSTOM_ELEMENT_HANDLING.tagNameCheck),f.CUSTOM_ELEMENT_HANDLING&&vs(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(O.attributeNameCheck=f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),f.CUSTOM_ELEMENT_HANDLING&&typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(O.allowCustomizedBuiltInElements=f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),We&&(Rr=!1),It&&(Ve=!0),qe&&(B=k({},Xa),W=[],qe.html===!0&&(k(B,Ka),k(W,Qa)),qe.svg===!0&&(k(B,fr),k(W,mr),k(W,$t)),qe.svgFilters===!0&&(k(B,dr),k(W,mr),k(W,$t)),qe.mathMl===!0&&(k(B,pr),k(W,Ja),k(W,$t))),f.ADD_TAGS&&(B===is&&(B=Fe(B)),k(B,f.ADD_TAGS,j)),f.ADD_ATTR&&(W===cs&&(W=Fe(W)),k(W,f.ADD_ATTR,j)),f.ADD_URI_SAFE_ATTR&&k(Cr,f.ADD_URI_SAFE_ATTR,j),f.FORBID_CONTENTS&&(Ye===ps&&(Ye=Fe(Ye)),k(Ye,f.FORBID_CONTENTS,j)),Tr&&(B["#text"]=!0),De&&k(B,["html","head","body"]),B.table&&(k(B,["tbody"]),delete lt.tbody),f.TRUSTED_TYPES_POLICY){if(typeof f.TRUSTED_TYPES_POLICY.createHTML!="function")throw Oe('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof f.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Oe('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');te=f.TRUSTED_TYPES_POLICY,ct=te.createHTML("")}else te===void 0&&(te=pc(_t,X)),te!==null&&typeof ct=="string"&&(ct=te.createHTML(""));c&&c(f),Xe=f}},ys=k({},[...fr,...dr,...ac]),Ss=k({},[...pr,...sc]),Dc=function(f){let m=At(f);(!m||!m.tagName)&&(m={namespaceURI:Ke,tagName:"template"});const b=K(f.tagName),A=K(m.tagName);return $r[f.namespaceURI]?f.namespaceURI===Ot?m.namespaceURI===Pe?b==="svg":m.namespaceURI===Lt?b==="svg"&&(A==="annotation-xml"||Ft[A]):!!ys[b]:f.namespaceURI===Lt?m.namespaceURI===Pe?b==="math":m.namespaceURI===Ot?b==="math"&&Dt[A]:!!Ss[b]:f.namespaceURI===Pe?m.namespaceURI===Ot&&!Dt[A]||m.namespaceURI===Lt&&!Ft[A]?!1:!Ss[b]&&(Mc[b]||!ys[b]):!!(ht==="application/xhtml+xml"&&$r[f.namespaceURI]):!1},me=function(f){U(v.removed,{element:f});try{At(f).removeChild(f)}catch{Sc(f)}},Nt=function(f,m){try{U(v.removed,{attribute:m.getAttributeNode(f),from:m})}catch{U(v.removed,{attribute:null,from:m})}if(m.removeAttribute(f),f==="is")if(Ve||It)try{me(m)}catch{}else try{m.setAttribute(f,"")}catch{}},ws=function(f){let m=null,b=null;if(kr)f="<remove></remove>"+f;else{const V=Re(f,/^[\r\n\t ]+/);b=V&&V[0]}ht==="application/xhtml+xml"&&Ke===Pe&&(f='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+f+"</body></html>");const A=te?te.createHTML(f):f;if(Ke===Pe)try{m=new vc().parseFromString(A,ht)}catch{}if(!m||!m.documentElement){m=br.createDocument(Ke,"template",null);try{m.documentElement.innerHTML=xr?ct:A}catch{}}const Q=m.body||m.documentElement;return f&&b&&Q.insertBefore(x.createTextNode(b),Q.childNodes[0]||null),Ke===Pe?kc.call(m,De?"html":"body")[0]:De?m.documentElement:Q},Rs=function(f){return Ec.call(f.ownerDocument||f,f,ot.SHOW_ELEMENT|ot.SHOW_COMMENT|ot.SHOW_TEXT|ot.SHOW_PROCESSING_INSTRUCTION|ot.SHOW_CDATA_SECTION,null)},Ar=function(f){return f instanceof bc&&(typeof f.nodeName!="string"||typeof f.textContent!="string"||typeof f.removeChild!="function"||!(f.attributes instanceof gc)||typeof f.removeAttribute!="function"||typeof f.setAttribute!="function"||typeof f.namespaceURI!="string"||typeof f.insertBefore!="function"||typeof f.hasChildNodes!="function")},Es=function(f){return typeof gr=="function"&&f instanceof gr};function ke(y,f,m){g(y,b=>{b.call(v,f,m,Xe)})}const Ps=function(f){let m=null;if(ke(re.beforeSanitizeElements,f,null),Ar(f))return me(f),!0;const b=j(f.nodeName);if(ke(re.uponSanitizeElement,f,{tagName:b,allowedTags:B}),f.hasChildNodes()&&!Es(f.firstElementChild)&&H(/<[/\w]/g,f.innerHTML)&&H(/<[/\w]/g,f.textContent)||f.nodeType===nt.progressingInstruction||Er&&f.nodeType===nt.comment&&H(/<[/\w]/g,f.data))return me(f),!0;if(!B[b]||lt[b]){if(!lt[b]&&Ts(b)&&(O.tagNameCheck instanceof RegExp&&H(O.tagNameCheck,b)||O.tagNameCheck instanceof Function&&O.tagNameCheck(b)))return!1;if(Tr&&!Ye[b]){const A=At(f)||f.parentNode,Q=Rc(f)||f.childNodes;if(Q&&A){const V=Q.length;for(let oe=V-1;oe>=0;--oe){const ge=yc(Q[oe],!0);ge.__removalCount=(f.__removalCount||0)+1,A.insertBefore(ge,wc(f))}}}return me(f),!0}return f instanceof ss&&!Dc(f)||(b==="noscript"||b==="noembed"||b==="noframes")&&H(/<\/no(script|embed|frames)/i,f.innerHTML)?(me(f),!0):(We&&f.nodeType===nt.text&&(m=f.textContent,g([vr,yr,Sr],A=>{m=ce(m,A," ")}),f.textContent!==m&&(U(v.removed,{element:f.cloneNode()}),f.textContent=m)),ke(re.afterSanitizeElements,f,null),!1)},ks=function(f,m,b){if(fs&&(m==="id"||m==="name")&&(b in x||b in Fc))return!1;if(!(Rr&&!wr[m]&&H(Cc,m))){if(!(ls&&H(xc,m))){if(!W[m]||wr[m]){if(!(Ts(f)&&(O.tagNameCheck instanceof RegExp&&H(O.tagNameCheck,f)||O.tagNameCheck instanceof Function&&O.tagNameCheck(f))&&(O.attributeNameCheck instanceof RegExp&&H(O.attributeNameCheck,m)||O.attributeNameCheck instanceof Function&&O.attributeNameCheck(m))||m==="is"&&O.allowCustomizedBuiltInElements&&(O.tagNameCheck instanceof RegExp&&H(O.tagNameCheck,b)||O.tagNameCheck instanceof Function&&O.tagNameCheck(b))))return!1}else if(!Cr[m]){if(!H(os,ce(b,ns,""))){if(!((m==="src"||m==="xlink:href"||m==="href")&&f!=="script"&&Le(b,"data:")===0&&ms[f])){if(!(us&&!H($c,ce(b,ns,"")))){if(b)return!1}}}}}}return!0},Ts=function(f){return f!=="annotation-xml"&&Re(f,_c)},Cs=function(f){ke(re.beforeSanitizeAttributes,f,null);const{attributes:m}=f;if(!m||Ar(f))return;const b={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:W,forceKeepAttr:void 0};let A=m.length;for(;A--;){const Q=m[A],{name:V,namespaceURI:oe,value:ge}=Q,ft=j(V);let ae=V==="value"?ge:z(ge);if(b.attrName=ft,b.attrValue=ae,b.keepAttr=!0,b.forceKeepAttr=void 0,ke(re.uponSanitizeAttribute,f,b),ae=b.attrValue,ds&&(ft==="id"||ft==="name")&&(Nt(V,f),ae=Ac+ae),Er&&H(/((--!?|])>)|<\/(style|title)/i,ae)){Nt(V,f);continue}if(b.forceKeepAttr||(Nt(V,f),!b.keepAttr))continue;if(!hs&&H(/\/>/i,ae)){Nt(V,f);continue}We&&g([vr,yr,Sr],$s=>{ae=ce(ae,$s," ")});const xs=j(f.nodeName);if(ks(xs,ft,ae)){if(te&&typeof _t=="object"&&typeof _t.getAttributeType=="function"&&!oe)switch(_t.getAttributeType(xs,ft)){case"TrustedHTML":{ae=te.createHTML(ae);break}case"TrustedScriptURL":{ae=te.createScriptURL(ae);break}}try{oe?f.setAttributeNS(oe,V,ae):f.setAttribute(V,ae),Ar(f)?me(f):P(v.removed)}catch{}}}ke(re.afterSanitizeAttributes,f,null)},Nc=function y(f){let m=null;const b=Rs(f);for(ke(re.beforeSanitizeShadowDOM,f,null);m=b.nextNode();)ke(re.uponSanitizeShadowNode,m,null),Ps(m),Cs(m),m.content instanceof Ee&&y(m.content);ke(re.afterSanitizeShadowDOM,f,null)};return v.sanitize=function(y){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},m=null,b=null,A=null,Q=null;if(xr=!y,xr&&(y="<!-->"),typeof y!="string"&&!Es(y))if(typeof y.toString=="function"){if(y=y.toString(),typeof y!="string")throw Oe("dirty is not a string, aborting")}else throw Oe("toString is not a function");if(!v.isSupported)return y;if(Pr||_r(f),v.removed=[],typeof y=="string"&&(ut=!1),ut){if(y.nodeName){const ge=j(y.nodeName);if(!B[ge]||lt[ge])throw Oe("root node is forbidden and cannot be sanitized in-place")}}else if(y instanceof gr)m=ws("<!---->"),b=m.ownerDocument.importNode(y,!0),b.nodeType===nt.element&&b.nodeName==="BODY"||b.nodeName==="HTML"?m=b:m.appendChild(b);else{if(!Ve&&!We&&!De&&y.indexOf("<")===-1)return te&&Mt?te.createHTML(y):y;if(m=ws(y),!m)return Ve?null:Mt?ct:""}m&&kr&&me(m.firstChild);const V=Rs(ut?y:m);for(;A=V.nextNode();)Ps(A),Cs(A),A.content instanceof Ee&&Nc(A.content);if(ut)return y;if(Ve){if(It)for(Q=Pc.call(m.ownerDocument);m.firstChild;)Q.appendChild(m.firstChild);else Q=m;return(W.shadowroot||W.shadowrootmode)&&(Q=Tc.call(C,Q,!0)),Q}let oe=De?m.outerHTML:m.innerHTML;return De&&B["!doctype"]&&m.ownerDocument&&m.ownerDocument.doctype&&m.ownerDocument.doctype.name&&H(es,m.ownerDocument.doctype.name)&&(oe="<!DOCTYPE "+m.ownerDocument.doctype.name+`>
30
- `+oe),We&&g([vr,yr,Sr],ge=>{oe=ce(oe,ge," ")}),te&&Mt?te.createHTML(oe):oe},v.setConfig=function(){let y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_r(y),Pr=!0},v.clearConfig=function(){Xe=null,Pr=!1},v.isValidAttribute=function(y,f,m){Xe||_r({});const b=j(y),A=j(f);return ks(b,A,m)},v.addHook=function(y,f){typeof f=="function"&&U(re[y],f)},v.removeHook=function(y,f){if(f!==void 0){const m=S(re[y],f);return m===-1?void 0:pe(re[y],m,1)[0]}return P(re[y])},v.removeHooks=function(y){re[y]=[]},v.removeAllHooks=function(){re=rs()},v}var mc=as();return mc})})($a);const _o=$a.exports,Ao="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";let Io=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+=Ao[r[e]&63];return t};const Mo=N(class extends D{constructor(){super();h(this,"adSource","Custom");h(this,"adClientResponseItem");h(this,"searchTerm");h(this,"unsubscribe",()=>{});h(this,"core");h(this,"adContainerId",Io());this.__registerHost()}connectedCallback(){var a,n,o;const r=_.getState();if(this.core=r.core,this.searchTerm=r.searchTerm,this.unsubscribe=_.subscribe(s=>{this.searchTerm=s.searchTerm}),((a=this.adClientResponseItem)==null?void 0:a.adSource)==="adMarketplace"){const s=this.adClientResponseItem;(n=s.admAd)!=null&&n.impression_url&&fetch(s.admAd.impression_url)}(o=this.core)==null||o.emitEvent("ad_container_rendered",{name:"ad_container_rendered",data:{adContainerId:this.adContainerId,adSource:this.adSource,searchTerm:this.searchTerm}})}disconnectedCallback(){this.unsubscribe()}renderADMAd(){const r=this.adClientResponseItem;if(r.admAd)return d("a",{class:"searchcraft-adm-ad",href:r.admAd.click_url},r.admAd.image_url&&d("div",{class:"searchcraft-adm-ad-image-wrapper"},d("img",{alt:r.admAd.term||"image",src:r.admAd.image_url,class:"searchcraft-adm-ad-image"})),d("div",{class:"searchcraft-adm-ad-info-wrapper"},d("p",{class:"searchcraft-adm-ad-title"},r.admAd.term),r.admAd.price&&d("p",{class:"searchcraft-adm-ad-subtitle"},r.admAd.price)))}renderCustomAd(){var o,s;const r=(s=(o=this.core)==null?void 0:o.config)==null?void 0:s.customAdTemplate,a=`searchcraft-custom-ad-${this.adContainerId}`;let n="<p>Custom Ad Placeholder</p>";return r&&(n=r({searchTerm:this.searchTerm,adContainerId:this.adContainerId})),d("div",{class:"searchcraft-custom-ad",id:a,"data-searchcraft-ad-container-id":this.adContainerId,innerHTML:_o.sanitize(n)})}renderNativoAd(){return d("div",{class:"searchcraft-nativo-ad"})}render(){switch(this.adSource){case"adMarketplace":return this.renderADMAd();case"Custom":return this.renderCustomAd();case"Nativo":return this.renderNativoAd();default:return}}},[0,"searchcraft-ad",{adSource:[1,"ad-source"],adClientResponseItem:[16],searchTerm:[32]}]);function Tt(){if(typeof customElements>"u")return;["searchcraft-ad"].forEach(t=>{switch(t){case"searchcraft-ad":customElements.get(t)||customElements.define(t,Mo);break}})}const Lo=Tt;function he(e,t){if(e&&t)return t.fieldNames.map(r=>{let a=e[r.fieldName];if(a)switch(r.dataType){case"date":{a=Oo(a);break}case"number":{a=Intl.NumberFormat(r.numberFormatLocale,r.numberFormatOptions).format(a*(r.numberScale||1));break}}return a}).filter(r=>!!r).join(t.delimiter||" ")}function _a(e){switch(e){case"hour":return 36e5;case"day":return 864e5;case"month":return 2592e6;case"year":return 31536e6;default:return 36e5}}function cr(e){return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function Oo(e){const t=new Date,r=new Date(e),a=Math.floor((t.getTime()-r.getTime())/1e3),n=Math.floor(a/60),o=Math.floor(n/60),s=Math.floor(o/24),c=Math.floor(s/365);return n<60?`${n}m ago`:o<24?`${o}h ago`:s<365?`${s}d ago`:`${c}y ago`}const Fo=N(class extends D{constructor(){super();h(this,"item");h(this,"searchResultMappings");h(this,"containerTarget","_blank");h(this,"containerRel");h(this,"buttonTarget","_blank");h(this,"buttonRel");h(this,"imagePlacement","right");h(this,"customStyles");h(this,"documentPosition",0);h(this,"titleContent");h(this,"subtitleContent");h(this,"bodyContent");h(this,"footerContent");h(this,"buttonLabel");h(this,"buttonHref");h(this,"containerHref");h(this,"imageSrc");h(this,"imageAlt");h(this,"searchcraftStore",_.getState());h(this,"handleLinkClick",()=>{var a;const r=this.searchcraftStore.getSearchcraftInstance();if(r){const n=this.documentPosition,o=this.searchcraftStore.searchTerm,s=this.searchcraftStore.searchClientResponseItems.length;(a=r.measureClient)==null||a.sendMeasureEvent("document_clicked",{document_position:n,number_of_documents:s,search_term:o})}});h(this,"parseStyles",()=>{if(this.customStyles)try{return JSON.parse(this.customStyles)}catch(r){return console.error("Error parsing custom styles:",r),{}}return{}});this.__registerHost()}connectedCallback(){this.item&&this.mapValuesFromDocument(this.item.document)}mapValuesFromDocument(r){var a,n,o,s,c,u,l;this.titleContent=he(r,(a=this.searchResultMappings)==null?void 0:a.title),this.subtitleContent=he(r,(n=this.searchResultMappings)==null?void 0:n.subtitle),this.bodyContent=he(r,(o=this.searchResultMappings)==null?void 0:o.body),this.containerHref=he(r,(s=this.searchResultMappings)==null?void 0:s.containerHref),this.buttonHref=he(r,(c=this.searchResultMappings)==null?void 0:c.buttonHref),this.imageSrc=he(r,(u=this.searchResultMappings)==null?void 0:u.imageSource),this.footerContent=he(r,(l=this.searchResultMappings)==null?void 0:l.footer)}render(){const r=this.parseStyles(),a=this.imageSrc&&d("img",{alt:this.imageAlt,class:"searchcraft-search-result-image",src:this.imageSrc,style:r.image||{}}),n=d(Jt,null,this.imageSrc&&this.imagePlacement==="left"&&a,d("div",{class:"searchcraft-base-search-result-content-container"},this.titleContent&&d("h2",{class:"searchcraft-base-search-result-title",style:r.title||{}},this.titleContent),this.subtitleContent&&d("h3",{class:"searchcraft-base-search-result-subtitle",style:r.subtitle||{}},this.subtitleContent),this.bodyContent&&d("p",{class:"searchcraft-base-search-result-body-content",style:r.primaryContent||{}},this.bodyContent),this.footerContent&&d("p",{class:"searchcraft-base-search-result-footer-content",style:r.secondaryContent||{}},this.footerContent),this.buttonHref&&!this.containerHref&&this.buttonLabel&&d("a",{class:"searchcraft-search-result-button",href:this.buttonHref,style:r.button||{},target:this.buttonTarget,rel:this.buttonRel},this.buttonLabel)),this.imageSrc&&this.imagePlacement==="right"&&a);return this.containerHref?d("a",{class:"searchcraft-search-result-container",onClick:this.handleLinkClick,href:this.containerHref,rel:this.containerRel,style:r.container||{},tabindex:"0",target:this.containerTarget},n):d("div",{class:"searchcraft-search-result-container",style:r.container||{}},n)}},[0,"searchcraft-base-search-result",{item:[16],searchResultMappings:[16],containerTarget:[1,"container-target"],containerRel:[1,"container-rel"],buttonTarget:[1,"button-target"],buttonRel:[1,"button-rel"],imagePlacement:[1,"image-placement"],customStyles:[1,"custom-styles"],documentPosition:[2,"document-position"],titleContent:[32],subtitleContent:[32],bodyContent:[32],footerContent:[32],buttonLabel:[32],buttonHref:[32],containerHref:[32],imageSrc:[32],imageAlt:[32]}]);function Aa(){if(typeof customElements>"u")return;["searchcraft-base-search-result"].forEach(t=>{switch(t){case"searchcraft-base-search-result":customElements.get(t)||customElements.define(t,Fo);break}})}const Do=Aa;function rt(e){if(typeof e=="string")try{return JSON.parse(e)}catch{return console.error("Invalid customStyles format:",e),{}}return e||{}}function No(e){try{return JSON.stringify(e)}catch(t){return console.error("Error serializing styles:",t),"{}"}}const Uo=N(class extends D{constructor(){super();h(this,"errorMessage");this.__registerHost()}render(){return d("p",{key:"dc97bb66da10a98fca027f928deaaf80d945417b",class:"searchcraft-error-message"},this.errorMessage||"Search term is required.")}},[0,"searchcraft-error-message",{errorMessage:[1,"error-message"]}]);function Ct(){if(typeof customElements>"u")return;["searchcraft-error-message"].forEach(t=>{switch(t){case"searchcraft-error-message":customElements.get(t)||customElements.define(t,Uo);break}})}const zo=N(class extends D{constructor(){super();h(this,"customStylesForResults");h(this,"searchResultMappings");h(this,"resultImagePlacement","right");h(this,"buttonLabel");h(this,"buttonTarget","_blank");h(this,"buttonRel");h(this,"containerTarget","_blank");h(this,"containerRel");h(this,"searchTerm","");h(this,"searchClientResponseItems",[]);h(this,"adClientResponseItems",[]);h(this,"searchResultsPerPage");h(this,"searchResultsPage");h(this,"isSearchInProgress",!1);h(this,"config");h(this,"unsubscribe",()=>{});this.__registerHost()}get serializedStyles(){let r="";return this.customStylesForResults&&(r=typeof this.customStylesForResults=="string"?this.customStylesForResults:No(this.customStylesForResults)),r}componentDidLoad(){var a;this.unsubscribe=_.subscribe(n=>this.handleStateChange(n));const r=_.getState();this.searchClientResponseItems=r.searchClientResponseItems,this.searchTerm=r.searchTerm,this.config=(a=r.core)==null?void 0:a.config}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleStateChange(r){var a;this.searchClientResponseItems=[...r.searchClientResponseItems],this.adClientResponseItems=[...r.adClientResponseItems],this.searchTerm=r.searchTerm,this.searchResultsPage=r.searchResultsPage,this.searchResultsPerPage=r.searchResultsPerPage,this.config=(a=r.core)==null?void 0:a.config,this.isSearchInProgress=r.isSearchInProgress}renderEmptyState(){return d("div",{class:"searchcraft-search-results-empty-state-container"},d("slot",{name:"empty-search"}))}renderNoResultsFoundState(){return d("div",{class:"searchcraft-search-results-container"},d("div",{class:"searchcraft-search-results-error-message-container"},d("searchcraft-error-message",{"error-message":`No search results found for "${this.searchTerm}" query`})))}renderWithADMAds(){var r,a;return d("div",{class:"searchcraft-search-results-container"},(r=this.adClientResponseItems)==null?void 0:r.map(n=>d("searchcraft-ad",{adSource:"adMarketplace",adClientResponseItem:n,key:n.id})),(a=this.searchClientResponseItems)==null?void 0:a.map((n,o)=>d("searchcraft-base-search-result",{key:n.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+o,searchResultMappings:this.searchResultMappings,item:n})))}renderWithCustomAds(){var u,l,i,p;const r=[],a=((u=this.config)==null?void 0:u.customAdInterstitialInterval)||0,n=((l=this.config)==null?void 0:l.customAdInterstitialQuantity)||1,o=((i=this.config)==null?void 0:i.customAdStartQuantity)||0,s=((p=this.config)==null?void 0:p.customAdEndQuantity)||0,c=this.searchClientResponseItems||[];for(let g=0;g<o;g++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g}-ad`}));c.forEach((g,S)=>{if(a&&S%a===0&&S+a<c.length&&S>=a)for(let P=0;P<n;P++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g.id}-ad-${P}`}));r.push(d("searchcraft-base-search-result",{key:g.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+S,searchResultMappings:this.searchResultMappings,item:g}))});for(let g=0;g<s;g++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g}-ad`}));return d("div",{class:"searchcraft-search-results-container"},r)}renderWithNoAds(){var r;return d("div",{class:"searchcraft-search-results-container"},(r=this.searchClientResponseItems)==null?void 0:r.map((a,n)=>d("searchcraft-base-search-result",{key:a.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+n,searchResultMappings:this.searchResultMappings,item:a})))}render(){var r;if(this.searchTerm.trim()==="")return this.renderEmptyState();if(this.searchTerm.length>0&&this.searchClientResponseItems.length===0&&!this.isSearchInProgress)return this.renderNoResultsFoundState();switch(((r=this.config)==null?void 0:r.adSource)||"None"){case"adMarketplace":return this.renderWithADMAds();case"Custom":return this.renderWithCustomAds();default:return this.renderWithNoAds()}}},[4,"searchcraft-base-search-results",{customStylesForResults:[1,"custom-styles-for-results"],searchResultMappings:[16],resultImagePlacement:[1,"result-image-placement"],buttonLabel:[1,"button-label"],buttonTarget:[1,"button-target"],buttonRel:[1,"button-rel"],containerTarget:[1,"container-target"],containerRel:[1,"container-rel"],searchTerm:[32],searchClientResponseItems:[32],adClientResponseItems:[32],searchResultsPerPage:[32],searchResultsPage:[32],isSearchInProgress:[32],config:[32]}]);function Ho(){if(typeof customElements>"u")return;["searchcraft-base-search-results","searchcraft-ad","searchcraft-base-search-result","searchcraft-error-message"].forEach(t=>{switch(t){case"searchcraft-base-search-results":customElements.get(t)||customElements.define(t,zo);break;case"searchcraft-ad":customElements.get(t)||Tt();break;case"searchcraft-base-search-result":customElements.get(t)||Aa();break;case"searchcraft-error-message":customElements.get(t)||Ct();break}})}const Bo=Ho;var Ia={exports:{}};/*!
29
+ */var rr=Symbol.for("react.transitional.element"),ho=Symbol.for("react.portal"),fo=Symbol.for("react.fragment"),po=Symbol.for("react.strict_mode"),mo=Symbol.for("react.profiler"),go=Symbol.for("react.consumer"),vo=Symbol.for("react.context"),bo=Symbol.for("react.forward_ref"),yo=Symbol.for("react.suspense"),So=Symbol.for("react.memo"),ms=Symbol.for("react.lazy"),gs=Symbol.iterator;function wo(e){return e===null||typeof e!="object"?null:(e=gs&&e[gs]||e["@@iterator"],typeof e=="function"?e:null)}var vs={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},bs=Object.assign,ys={};function Be(e,t,r){this.props=e,this.context=t,this.refs=ys,this.updater=r||vs}Be.prototype.isReactComponent={},Be.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},Be.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Ss(){}Ss.prototype=Be.prototype;function sr(e,t,r){this.props=e,this.context=t,this.refs=ys,this.updater=r||vs}var ar=sr.prototype=new Ss;ar.constructor=sr,bs(ar,Be.prototype),ar.isPureReactComponent=!0;var ws=Array.isArray,M={H:null,A:null,T:null,S:null},Rs=Object.prototype.hasOwnProperty;function nr(e,t,r,s,n,o){return r=o.ref,{$$typeof:rr,type:e,key:t,ref:r!==void 0?r:null,props:o}}function Ro(e,t){return nr(e.type,t,void 0,void 0,void 0,e.props)}function or(e){return typeof e=="object"&&e!==null&&e.$$typeof===rr}function Eo(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var Es=/\/+/g;function ir(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Eo(""+e.key):t.toString(36)}function Ps(){}function Po(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(Ps,Ps):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function je(e,t,r,s,n){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var a=!1;if(e===null)a=!0;else switch(o){case"bigint":case"string":case"number":a=!0;break;case"object":switch(e.$$typeof){case rr:case ho:a=!0;break;case ms:return a=e._init,je(a(e._payload),t,r,s,n)}}if(a)return n=n(e),a=s===""?"."+ir(e,0):s,ws(n)?(r="",a!=null&&(r=a.replace(Es,"$&/")+"/"),je(n,t,r,"",function(l){return l})):n!=null&&(or(n)&&(n=Ro(n,r+(n.key==null||e&&e.key===n.key?"":(""+n.key).replace(Es,"$&/")+"/")+a)),t.push(n)),1;a=0;var c=s===""?".":s+":";if(ws(e))for(var u=0;u<e.length;u++)s=e[u],o=c+ir(s,u),a+=je(s,t,r,o,n);else if(u=wo(e),typeof u=="function")for(e=u.call(e),u=0;!(s=e.next()).done;)s=s.value,o=c+ir(s,u++),a+=je(s,t,r,o,n);else if(o==="object"){if(typeof e.then=="function")return je(Po(e),t,r,s,n);throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return a}function Ct(e,t,r){if(e==null)return e;var s=[],n=0;return je(e,s,"","",function(o){return t.call(r,o,n++)}),s}function Co(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Cs=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function ko(){}P.Children={map:Ct,forEach:function(e,t,r){Ct(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return Ct(e,function(){t++}),t},toArray:function(e){return Ct(e,function(t){return t})||[]},only:function(e){if(!or(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},P.Component=Be,P.Fragment=fo,P.Profiler=mo,P.PureComponent=sr,P.StrictMode=po,P.Suspense=yo,P.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=M,P.act=function(){throw Error("act(...) is not supported in production builds of React.")},P.cache=function(e){return function(){return e.apply(null,arguments)}},P.cloneElement=function(e,t,r){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var s=bs({},e.props),n=e.key,o=void 0;if(t!=null)for(a in t.ref!==void 0&&(o=void 0),t.key!==void 0&&(n=""+t.key),t)!Rs.call(t,a)||a==="key"||a==="__self"||a==="__source"||a==="ref"&&t.ref===void 0||(s[a]=t[a]);var a=arguments.length-2;if(a===1)s.children=r;else if(1<a){for(var c=Array(a),u=0;u<a;u++)c[u]=arguments[u+2];s.children=c}return nr(e.type,n,void 0,void 0,o,s)},P.createContext=function(e){return e={$$typeof:vo,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:go,_context:e},e},P.createElement=function(e,t,r){var s,n={},o=null;if(t!=null)for(s in t.key!==void 0&&(o=""+t.key),t)Rs.call(t,s)&&s!=="key"&&s!=="__self"&&s!=="__source"&&(n[s]=t[s]);var a=arguments.length-2;if(a===1)n.children=r;else if(1<a){for(var c=Array(a),u=0;u<a;u++)c[u]=arguments[u+2];n.children=c}if(e&&e.defaultProps)for(s in a=e.defaultProps,a)n[s]===void 0&&(n[s]=a[s]);return nr(e,o,void 0,void 0,null,n)},P.createRef=function(){return{current:null}},P.forwardRef=function(e){return{$$typeof:bo,render:e}},P.isValidElement=or,P.lazy=function(e){return{$$typeof:ms,_payload:{_status:-1,_result:e},_init:Co}},P.memo=function(e,t){return{$$typeof:So,type:e,compare:t===void 0?null:t}},P.startTransition=function(e){var t=M.T,r={};M.T=r;try{var s=e(),n=M.S;n!==null&&n(r,s),typeof s=="object"&&s!==null&&typeof s.then=="function"&&s.then(ko,Cs)}catch(o){Cs(o)}finally{M.T=t}},P.unstable_useCacheRefresh=function(){return M.H.useCacheRefresh()},P.use=function(e){return M.H.use(e)},P.useActionState=function(e,t,r){return M.H.useActionState(e,t,r)},P.useCallback=function(e,t){return M.H.useCallback(e,t)},P.useContext=function(e){return M.H.useContext(e)},P.useDebugValue=function(){},P.useDeferredValue=function(e,t){return M.H.useDeferredValue(e,t)},P.useEffect=function(e,t){return M.H.useEffect(e,t)},P.useId=function(){return M.H.useId()},P.useImperativeHandle=function(e,t,r){return M.H.useImperativeHandle(e,t,r)},P.useInsertionEffect=function(e,t){return M.H.useInsertionEffect(e,t)},P.useLayoutEffect=function(e,t){return M.H.useLayoutEffect(e,t)},P.useMemo=function(e,t){return M.H.useMemo(e,t)},P.useOptimistic=function(e,t){return M.H.useOptimistic(e,t)},P.useReducer=function(e,t,r){return M.H.useReducer(e,t,r)},P.useRef=function(e){return M.H.useRef(e)},P.useState=function(e){return M.H.useState(e)},P.useSyncExternalStore=function(e,t,r){return M.H.useSyncExternalStore(e,t,r)},P.useTransition=function(){return M.H.useTransition()},P.version="19.0.0",ps.exports=P;var ks=ps.exports,To=er;const xo=e=>e;function Ts(e,t=xo){const r=ks.useSyncExternalStore(e.subscribe,()=>t(e.getState()),()=>t(e.getInitialState()));return ks.useDebugValue(r),r}const xs=e=>{const t=To.createStore(e),r=s=>Ts(t,s);return Object.assign(r,t),r},$o=e=>e?xs(e):xs;tr.create=$o,tr.useStore=Ts,function(e){var t=er,r=tr;Object.keys(t).forEach(function(s){s!=="default"&&!Object.prototype.hasOwnProperty.call(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:function(){return t[s]}})}),Object.keys(r).forEach(function(s){s!=="default"&&!Object.prototype.hasOwnProperty.call(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:function(){return r[s]}})})}(ds);const _o={adClientResponseItems:[],core:void 0,logger:void 0,facetPathsForIndexFields:{},isPopoverVisible:!1,isSearchInProgress:!1,searchTerm:"",rangeValueForIndexFields:{},searchMode:"fuzzy",searchClientResponseItems:[],searchResponseTimeTaken:void 0,searchResponseFacetPrime:void 0,searchResultsCount:0,searchResultsPerPage:20,searchResultsPage:1,sortType:"asc"},A=ds.createStore((e,t)=>{const r={addFacetPathsForIndexField:n=>e(o=>({facetPathsForIndexFields:{...o.facetPathsForIndexFields,[n.fieldName]:n}})),addRangeValueForIndexField:n=>e(o=>({rangeValueForIndexFields:{...o.rangeValueForIndexFields,[n.fieldName]:n}})),getSearchcraftInstance:()=>{const{core:n}=t();return n},initialize:(n,o=!1)=>{const a=n,c=o?new Xn({logLevel:_e.DEBUG}):void 0;e({core:a,logger:c,searchResultsPerPage:a.config.searchResultsPerPage||20})},removeFacetPathsForIndexField:n=>e(o=>{const a=o.facetPathsForIndexFields;return delete a[n],{facetPathsForIndexFields:{...a}}}),removeRangeValueForIndexField:n=>e(o=>{const a=o.rangeValueForIndexFields;return delete a[n],{rangeValueForIndexFields:{...a}}}),resetFacetPaths:()=>{e({facetPathsForIndexFields:{}})},search:async()=>{var c,u;const n=t();if((c=n.logger)==null||c.log(_e.INFO,`Starting search with search term: "${n.searchTerm}"`),!n.core)throw new Error("Searchcraft instance is not initialized.");if(!n.searchTerm.trim()){(u=n.logger)==null||u.log(_e.INFO,"No search request was made: search term was empty."),e({searchClientResponseItems:[],searchResultsCount:0,searchResultsPage:1,searchTerm:""});return}e({isSearchInProgress:!0});const o=(l,i)=>{var m,b;const p=l.data.facets;e(v=>({isSearchInProgress:!1,searchClientResponseItems:i,searchResponseTimeTaken:l.data.time_taken||0,searchResultsPage:l.data.count===v.searchResultsCount?v.searchResultsPage:1,searchResultsCount:l.data.count||0})),p&&e({searchResponseFacetPrime:p}),(m=n.logger)==null||m.log(_e.DEBUG,`Search results: ${JSON.stringify(i)}`),(b=n.logger)==null||b.log(_e.DEBUG,`Facets from response: ${JSON.stringify(p)}`)},a=l=>{e({adClientResponseItems:l})};n.core.getItems({searchTerm:n.searchTerm,mode:n.searchMode,sort:n.sortType,facetPathsForIndexFields:n.facetPathsForIndexFields,rangeValueForIndexFields:n.rangeValueForIndexFields,offset:n.searchResultsPerPage?n.searchResultsPerPage*(n.searchResultsPage-1):0,limit:n.searchResultsPerPage},o,a)},setPopoverVisibility:n=>{e({isPopoverVisible:n})},setSearchMode:n=>e({searchMode:n}),setSortType:n=>e({sortType:n}),setSearchTerm:n=>{const{core:o}=t();n.length===0&&(o==null||o.handleInputCleared()),e({searchTerm:n,facetPathsForIndexFields:{},...n.trim().length===0&&{searchMode:"fuzzy",sortType:"asc"}})},setSearchClientResponseItems:n=>e({searchClientResponseItems:n}),setSearchResultsPage:async n=>{e({searchResultsPage:n}),await r.search()},setSearchResultsPerPage:async n=>{e({searchResultsPerPage:n}),await r.search()}};return{..._o,...r}});var Ao=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},$s={exports:{}};/*! @license DOMPurify 3.2.4 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.4/LICENSE */(function(e,t){(function(r,s){e.exports=s()})(Ao,function(){const{entries:r,setPrototypeOf:s,isFrozen:n,getPrototypeOf:o,getOwnPropertyDescriptor:a}=Object;let{freeze:c,seal:u,create:l}=Object,{apply:i,construct:p}=typeof Reflect<"u"&&Reflect;c||(c=function(S){return S}),u||(u=function(S){return S}),i||(i=function(S,x,T){return S.apply(x,T)}),p||(p=function(S,x){return new S(...x)});const m=te(Array.prototype.forEach),b=te(Array.prototype.lastIndexOf),v=te(Array.prototype.pop),$=te(Array.prototype.push),z=te(Array.prototype.splice),K=te(String.prototype.toLowerCase),_=te(String.prototype.toString),Re=te(String.prototype.match),le=te(String.prototype.replace),Le=te(String.prototype.indexOf),H=te(String.prototype.trim),oe=te(Object.prototype.hasOwnProperty),B=te(RegExp.prototype.test),Oe=sc(TypeError);function te(k){return function(S){for(var x=arguments.length,T=new Array(x>1?x-1:0),X=1;X<x;X++)T[X-1]=arguments[X];return i(k,S,T)}}function sc(k){return function(){for(var S=arguments.length,x=new Array(S),T=0;T<S;T++)x[T]=arguments[T];return p(k,x)}}function C(k,S){let x=arguments.length>2&&arguments[2]!==void 0?arguments[2]:K;s&&s(k,null);let T=S.length;for(;T--;){let X=S[T];if(typeof X=="string"){const Ee=x(X);Ee!==X&&(n(S)||(S[T]=Ee),X=Ee)}k[X]=!0}return k}function ac(k){for(let S=0;S<k.length;S++)oe(k,S)||(k[S]=null);return k}function Fe(k){const S=l(null);for(const[x,T]of r(k))oe(k,x)&&(Array.isArray(T)?S[x]=ac(T):T&&typeof T=="object"&&T.constructor===Object?S[x]=Fe(T):S[x]=T);return S}function at(k,S){for(;k!==null;){const T=a(k,S);if(T){if(T.get)return te(T.get);if(typeof T.value=="function")return te(T.value)}k=o(k)}function x(){return null}return x}const Qs=c(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),dr=c(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),fr=c(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),nc=c(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),pr=c(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),oc=c(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Ks=c(["#text"]),Xs=c(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),mr=c(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Js=c(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),$t=c(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ic=u(/\{\{[\w\W]*|[\w\W]*\}\}/gm),cc=u(/<%[\w\W]*|[\w\W]*%>/gm),lc=u(/\$\{[\w\W]*/gm),uc=u(/^data-[\-\w.\u00B7-\uFFFF]+$/),hc=u(/^aria-[\-\w]+$/),Zs=u(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),dc=u(/^(?:\w+script|data):/i),fc=u(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ea=u(/^html$/i),pc=u(/^[a-z][.\w]*(-[.\w]+)+$/i);var ta=Object.freeze({__proto__:null,ARIA_ATTR:hc,ATTR_WHITESPACE:fc,CUSTOM_ELEMENT:pc,DATA_ATTR:uc,DOCTYPE_NAME:ea,ERB_EXPR:cc,IS_ALLOWED_URI:Zs,IS_SCRIPT_OR_DATA:dc,MUSTACHE_EXPR:ic,TMPLIT_EXPR:lc});const nt={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},mc=function(){return typeof window>"u"?null:window},gc=function(S,x){if(typeof S!="object"||typeof S.createPolicy!="function")return null;let T=null;const X="data-tt-policy-suffix";x&&x.hasAttribute(X)&&(T=x.getAttribute(X));const Ee="dompurify"+(T?"#"+T:"");try{return S.createPolicy(Ee,{createHTML(Ve){return Ve},createScriptURL(Ve){return Ve}})}catch{return console.warn("TrustedTypes policy "+Ee+" could not be created."),null}},ra=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function sa(){let k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:mc();const S=w=>sa(w);if(S.version="3.2.4",S.removed=[],!k||!k.document||k.document.nodeType!==nt.document||!k.Element)return S.isSupported=!1,S;let{document:x}=k;const T=x,X=T.currentScript,{DocumentFragment:Ee,HTMLTemplateElement:Ve,Node:gr,Element:aa,NodeFilter:ot,NamedNodeMap:bc=k.NamedNodeMap||k.MozNamedAttrMap,HTMLFormElement:yc,DOMParser:Sc,trustedTypes:_t}=k,it=aa.prototype,wc=at(it,"cloneNode"),Rc=at(it,"remove"),Ec=at(it,"nextSibling"),Pc=at(it,"childNodes"),At=at(it,"parentNode");if(typeof Ve=="function"){const w=x.createElement("template");w.content&&w.content.ownerDocument&&(x=w.content.ownerDocument)}let re,ct="";const{implementation:vr,createNodeIterator:Cc,createDocumentFragment:kc,getElementsByTagName:Tc}=x,{importNode:xc}=T;let se=ra();S.isSupported=typeof r=="function"&&typeof At=="function"&&vr&&vr.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:br,ERB_EXPR:yr,TMPLIT_EXPR:Sr,DATA_ATTR:$c,ARIA_ATTR:_c,IS_SCRIPT_OR_DATA:Ac,ATTR_WHITESPACE:na,CUSTOM_ELEMENT:Ic}=ta;let{IS_ALLOWED_URI:oa}=ta,j=null;const ia=C({},[...Qs,...dr,...fr,...pr,...Ks]);let G=null;const ca=C({},[...Xs,...mr,...Js,...$t]);let D=Object.seal(l(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),lt=null,wr=null,la=!0,Rr=!0,ua=!1,ha=!0,We=!1,Er=!0,De=!1,Pr=!1,Cr=!1,Ge=!1,It=!1,Mt=!1,da=!0,fa=!1;const Mc="user-content-";let kr=!0,ut=!1,qe={},Ye=null;const pa=C({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ma=null;const ga=C({},["audio","video","img","source","image","track"]);let Tr=null;const va=C({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Lt="http://www.w3.org/1998/Math/MathML",Ot="http://www.w3.org/2000/svg",Pe="http://www.w3.org/1999/xhtml";let Qe=Pe,xr=!1,$r=null;const Lc=C({},[Lt,Ot,Pe],_);let Ft=C({},["mi","mo","mn","ms","mtext"]),Dt=C({},["annotation-xml"]);const Oc=C({},["title","style","font","a","script"]);let ht=null;const Fc=["application/xhtml+xml","text/html"],Dc="text/html";let V=null,Ke=null;const Nc=x.createElement("form"),ba=function(d){return d instanceof RegExp||d instanceof Function},_r=function(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Ke&&Ke===d)){if((!d||typeof d!="object")&&(d={}),d=Fe(d),ht=Fc.indexOf(d.PARSER_MEDIA_TYPE)===-1?Dc:d.PARSER_MEDIA_TYPE,V=ht==="application/xhtml+xml"?_:K,j=oe(d,"ALLOWED_TAGS")?C({},d.ALLOWED_TAGS,V):ia,G=oe(d,"ALLOWED_ATTR")?C({},d.ALLOWED_ATTR,V):ca,$r=oe(d,"ALLOWED_NAMESPACES")?C({},d.ALLOWED_NAMESPACES,_):Lc,Tr=oe(d,"ADD_URI_SAFE_ATTR")?C(Fe(va),d.ADD_URI_SAFE_ATTR,V):va,ma=oe(d,"ADD_DATA_URI_TAGS")?C(Fe(ga),d.ADD_DATA_URI_TAGS,V):ga,Ye=oe(d,"FORBID_CONTENTS")?C({},d.FORBID_CONTENTS,V):pa,lt=oe(d,"FORBID_TAGS")?C({},d.FORBID_TAGS,V):{},wr=oe(d,"FORBID_ATTR")?C({},d.FORBID_ATTR,V):{},qe=oe(d,"USE_PROFILES")?d.USE_PROFILES:!1,la=d.ALLOW_ARIA_ATTR!==!1,Rr=d.ALLOW_DATA_ATTR!==!1,ua=d.ALLOW_UNKNOWN_PROTOCOLS||!1,ha=d.ALLOW_SELF_CLOSE_IN_ATTR!==!1,We=d.SAFE_FOR_TEMPLATES||!1,Er=d.SAFE_FOR_XML!==!1,De=d.WHOLE_DOCUMENT||!1,Ge=d.RETURN_DOM||!1,It=d.RETURN_DOM_FRAGMENT||!1,Mt=d.RETURN_TRUSTED_TYPE||!1,Cr=d.FORCE_BODY||!1,da=d.SANITIZE_DOM!==!1,fa=d.SANITIZE_NAMED_PROPS||!1,kr=d.KEEP_CONTENT!==!1,ut=d.IN_PLACE||!1,oa=d.ALLOWED_URI_REGEXP||Zs,Qe=d.NAMESPACE||Pe,Ft=d.MATHML_TEXT_INTEGRATION_POINTS||Ft,Dt=d.HTML_INTEGRATION_POINTS||Dt,D=d.CUSTOM_ELEMENT_HANDLING||{},d.CUSTOM_ELEMENT_HANDLING&&ba(d.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(D.tagNameCheck=d.CUSTOM_ELEMENT_HANDLING.tagNameCheck),d.CUSTOM_ELEMENT_HANDLING&&ba(d.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(D.attributeNameCheck=d.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),d.CUSTOM_ELEMENT_HANDLING&&typeof d.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(D.allowCustomizedBuiltInElements=d.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),We&&(Rr=!1),It&&(Ge=!0),qe&&(j=C({},Ks),G=[],qe.html===!0&&(C(j,Qs),C(G,Xs)),qe.svg===!0&&(C(j,dr),C(G,mr),C(G,$t)),qe.svgFilters===!0&&(C(j,fr),C(G,mr),C(G,$t)),qe.mathMl===!0&&(C(j,pr),C(G,Js),C(G,$t))),d.ADD_TAGS&&(j===ia&&(j=Fe(j)),C(j,d.ADD_TAGS,V)),d.ADD_ATTR&&(G===ca&&(G=Fe(G)),C(G,d.ADD_ATTR,V)),d.ADD_URI_SAFE_ATTR&&C(Tr,d.ADD_URI_SAFE_ATTR,V),d.FORBID_CONTENTS&&(Ye===pa&&(Ye=Fe(Ye)),C(Ye,d.FORBID_CONTENTS,V)),kr&&(j["#text"]=!0),De&&C(j,["html","head","body"]),j.table&&(C(j,["tbody"]),delete lt.tbody),d.TRUSTED_TYPES_POLICY){if(typeof d.TRUSTED_TYPES_POLICY.createHTML!="function")throw Oe('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof d.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Oe('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');re=d.TRUSTED_TYPES_POLICY,ct=re.createHTML("")}else re===void 0&&(re=gc(_t,X)),re!==null&&typeof ct=="string"&&(ct=re.createHTML(""));c&&c(d),Ke=d}},ya=C({},[...dr,...fr,...nc]),Sa=C({},[...pr,...oc]),Uc=function(d){let g=At(d);(!g||!g.tagName)&&(g={namespaceURI:Qe,tagName:"template"});const y=K(d.tagName),I=K(g.tagName);return $r[d.namespaceURI]?d.namespaceURI===Ot?g.namespaceURI===Pe?y==="svg":g.namespaceURI===Lt?y==="svg"&&(I==="annotation-xml"||Ft[I]):!!ya[y]:d.namespaceURI===Lt?g.namespaceURI===Pe?y==="math":g.namespaceURI===Ot?y==="math"&&Dt[I]:!!Sa[y]:d.namespaceURI===Pe?g.namespaceURI===Ot&&!Dt[I]||g.namespaceURI===Lt&&!Ft[I]?!1:!Sa[y]&&(Oc[y]||!ya[y]):!!(ht==="application/xhtml+xml"&&$r[d.namespaceURI]):!1},me=function(d){$(S.removed,{element:d});try{At(d).removeChild(d)}catch{Rc(d)}},Nt=function(d,g){try{$(S.removed,{attribute:g.getAttributeNode(d),from:g})}catch{$(S.removed,{attribute:null,from:g})}if(g.removeAttribute(d),d==="is")if(Ge||It)try{me(g)}catch{}else try{g.setAttribute(d,"")}catch{}},wa=function(d){let g=null,y=null;if(Cr)d="<remove></remove>"+d;else{const q=Re(d,/^[\r\n\t ]+/);y=q&&q[0]}ht==="application/xhtml+xml"&&Qe===Pe&&(d='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+d+"</body></html>");const I=re?re.createHTML(d):d;if(Qe===Pe)try{g=new Sc().parseFromString(I,ht)}catch{}if(!g||!g.documentElement){g=vr.createDocument(Qe,"template",null);try{g.documentElement.innerHTML=xr?ct:I}catch{}}const J=g.body||g.documentElement;return d&&y&&J.insertBefore(x.createTextNode(y),J.childNodes[0]||null),Qe===Pe?Tc.call(g,De?"html":"body")[0]:De?g.documentElement:J},Ra=function(d){return Cc.call(d.ownerDocument||d,d,ot.SHOW_ELEMENT|ot.SHOW_COMMENT|ot.SHOW_TEXT|ot.SHOW_PROCESSING_INSTRUCTION|ot.SHOW_CDATA_SECTION,null)},Ar=function(d){return d instanceof yc&&(typeof d.nodeName!="string"||typeof d.textContent!="string"||typeof d.removeChild!="function"||!(d.attributes instanceof bc)||typeof d.removeAttribute!="function"||typeof d.setAttribute!="function"||typeof d.namespaceURI!="string"||typeof d.insertBefore!="function"||typeof d.hasChildNodes!="function")},Ea=function(d){return typeof gr=="function"&&d instanceof gr};function Ce(w,d,g){m(w,y=>{y.call(S,d,g,Ke)})}const Pa=function(d){let g=null;if(Ce(se.beforeSanitizeElements,d,null),Ar(d))return me(d),!0;const y=V(d.nodeName);if(Ce(se.uponSanitizeElement,d,{tagName:y,allowedTags:j}),d.hasChildNodes()&&!Ea(d.firstElementChild)&&B(/<[/\w]/g,d.innerHTML)&&B(/<[/\w]/g,d.textContent)||d.nodeType===nt.progressingInstruction||Er&&d.nodeType===nt.comment&&B(/<[/\w]/g,d.data))return me(d),!0;if(!j[y]||lt[y]){if(!lt[y]&&ka(y)&&(D.tagNameCheck instanceof RegExp&&B(D.tagNameCheck,y)||D.tagNameCheck instanceof Function&&D.tagNameCheck(y)))return!1;if(kr&&!Ye[y]){const I=At(d)||d.parentNode,J=Pc(d)||d.childNodes;if(J&&I){const q=J.length;for(let ie=q-1;ie>=0;--ie){const ge=wc(J[ie],!0);ge.__removalCount=(d.__removalCount||0)+1,I.insertBefore(ge,Ec(d))}}}return me(d),!0}return d instanceof aa&&!Uc(d)||(y==="noscript"||y==="noembed"||y==="noframes")&&B(/<\/no(script|embed|frames)/i,d.innerHTML)?(me(d),!0):(We&&d.nodeType===nt.text&&(g=d.textContent,m([br,yr,Sr],I=>{g=le(g,I," ")}),d.textContent!==g&&($(S.removed,{element:d.cloneNode()}),d.textContent=g)),Ce(se.afterSanitizeElements,d,null),!1)},Ca=function(d,g,y){if(da&&(g==="id"||g==="name")&&(y in x||y in Nc))return!1;if(!(Rr&&!wr[g]&&B($c,g))){if(!(la&&B(_c,g))){if(!G[g]||wr[g]){if(!(ka(d)&&(D.tagNameCheck instanceof RegExp&&B(D.tagNameCheck,d)||D.tagNameCheck instanceof Function&&D.tagNameCheck(d))&&(D.attributeNameCheck instanceof RegExp&&B(D.attributeNameCheck,g)||D.attributeNameCheck instanceof Function&&D.attributeNameCheck(g))||g==="is"&&D.allowCustomizedBuiltInElements&&(D.tagNameCheck instanceof RegExp&&B(D.tagNameCheck,y)||D.tagNameCheck instanceof Function&&D.tagNameCheck(y))))return!1}else if(!Tr[g]){if(!B(oa,le(y,na,""))){if(!((g==="src"||g==="xlink:href"||g==="href")&&d!=="script"&&Le(y,"data:")===0&&ma[d])){if(!(ua&&!B(Ac,le(y,na,"")))){if(y)return!1}}}}}}return!0},ka=function(d){return d!=="annotation-xml"&&Re(d,Ic)},Ta=function(d){Ce(se.beforeSanitizeAttributes,d,null);const{attributes:g}=d;if(!g||Ar(d))return;const y={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:G,forceKeepAttr:void 0};let I=g.length;for(;I--;){const J=g[I],{name:q,namespaceURI:ie,value:ge}=J,dt=V(q);let ae=q==="value"?ge:H(ge);if(y.attrName=dt,y.attrValue=ae,y.keepAttr=!0,y.forceKeepAttr=void 0,Ce(se.uponSanitizeAttribute,d,y),ae=y.attrValue,fa&&(dt==="id"||dt==="name")&&(Nt(q,d),ae=Mc+ae),Er&&B(/((--!?|])>)|<\/(style|title)/i,ae)){Nt(q,d);continue}if(y.forceKeepAttr||(Nt(q,d),!y.keepAttr))continue;if(!ha&&B(/\/>/i,ae)){Nt(q,d);continue}We&&m([br,yr,Sr],$a=>{ae=le(ae,$a," ")});const xa=V(d.nodeName);if(Ca(xa,dt,ae)){if(re&&typeof _t=="object"&&typeof _t.getAttributeType=="function"&&!ie)switch(_t.getAttributeType(xa,dt)){case"TrustedHTML":{ae=re.createHTML(ae);break}case"TrustedScriptURL":{ae=re.createScriptURL(ae);break}}try{ie?d.setAttributeNS(ie,q,ae):d.setAttribute(q,ae),Ar(d)?me(d):v(S.removed)}catch{}}}Ce(se.afterSanitizeAttributes,d,null)},zc=function w(d){let g=null;const y=Ra(d);for(Ce(se.beforeSanitizeShadowDOM,d,null);g=y.nextNode();)Ce(se.uponSanitizeShadowNode,g,null),Pa(g),Ta(g),g.content instanceof Ee&&w(g.content);Ce(se.afterSanitizeShadowDOM,d,null)};return S.sanitize=function(w){let d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},g=null,y=null,I=null,J=null;if(xr=!w,xr&&(w="<!-->"),typeof w!="string"&&!Ea(w))if(typeof w.toString=="function"){if(w=w.toString(),typeof w!="string")throw Oe("dirty is not a string, aborting")}else throw Oe("toString is not a function");if(!S.isSupported)return w;if(Pr||_r(d),S.removed=[],typeof w=="string"&&(ut=!1),ut){if(w.nodeName){const ge=V(w.nodeName);if(!j[ge]||lt[ge])throw Oe("root node is forbidden and cannot be sanitized in-place")}}else if(w instanceof gr)g=wa("<!---->"),y=g.ownerDocument.importNode(w,!0),y.nodeType===nt.element&&y.nodeName==="BODY"||y.nodeName==="HTML"?g=y:g.appendChild(y);else{if(!Ge&&!We&&!De&&w.indexOf("<")===-1)return re&&Mt?re.createHTML(w):w;if(g=wa(w),!g)return Ge?null:Mt?ct:""}g&&Cr&&me(g.firstChild);const q=Ra(ut?w:g);for(;I=q.nextNode();)Pa(I),Ta(I),I.content instanceof Ee&&zc(I.content);if(ut)return w;if(Ge){if(It)for(J=kc.call(g.ownerDocument);g.firstChild;)J.appendChild(g.firstChild);else J=g;return(G.shadowroot||G.shadowrootmode)&&(J=xc.call(T,J,!0)),J}let ie=De?g.outerHTML:g.innerHTML;return De&&j["!doctype"]&&g.ownerDocument&&g.ownerDocument.doctype&&g.ownerDocument.doctype.name&&B(ea,g.ownerDocument.doctype.name)&&(ie="<!DOCTYPE "+g.ownerDocument.doctype.name+`>
30
+ `+ie),We&&m([br,yr,Sr],ge=>{ie=le(ie,ge," ")}),re&&Mt?re.createHTML(ie):ie},S.setConfig=function(){let w=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_r(w),Pr=!0},S.clearConfig=function(){Ke=null,Pr=!1},S.isValidAttribute=function(w,d,g){Ke||_r({});const y=V(w),I=V(d);return Ca(y,I,g)},S.addHook=function(w,d){typeof d=="function"&&$(se[w],d)},S.removeHook=function(w,d){if(d!==void 0){const g=b(se[w],d);return g===-1?void 0:z(se[w],g,1)[0]}return v(se[w])},S.removeHooks=function(w){se[w]=[]},S.removeAllHooks=function(){se=ra()},S}var vc=sa();return vc})})($s);const Io=$s.exports,Mo="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";let Lo=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+=Mo[r[e]&63];return t};const Oo=U(class extends N{constructor(){super();h(this,"adSource","Custom");h(this,"adClientResponseItem");h(this,"searchTerm");h(this,"isSearchInProgress",!1);h(this,"core");h(this,"adContainerId",Lo());h(this,"intersectionObserver");h(this,"storeUnsubscribe");this.__registerHost()}get hostElement(){return this}connectedCallback(){var s;const r=A.getState();this.core=r.core,this.searchTerm=r.searchTerm,this.isSearchInProgress=r.isSearchInProgress,this.storeUnsubscribe=A.subscribe(n=>{this.searchTerm=n.searchTerm,this.isSearchInProgress=n.isSearchInProgress}),(s=this.core)==null||s.handleAdContainerRendered({adClientResponseItem:this.adClientResponseItem,adContainerId:this.adContainerId,adSource:this.adSource,searchTerm:this.searchTerm})}componentDidLoad(){this.hostElement&&(this.intersectionObserver=new IntersectionObserver(([r])=>{var s;r!=null&&r.isIntersecting&&!this.isSearchInProgress&&((s=this.core)==null||s.handleAdContainerViewed({adClientResponseItem:this.adClientResponseItem,adContainerId:this.adContainerId,adSource:this.adSource,searchTerm:this.searchTerm||""}))},{threshold:0}),this.intersectionObserver.observe(this.hostElement))}disconnectedCallback(){var r,s;console.log("disconnectedCallback()",this.adContainerId),(r=this.storeUnsubscribe)==null||r.call(this),(s=this.intersectionObserver)==null||s.disconnect()}renderADMAd(){const r=this.adClientResponseItem;if(r.admAd)return f("a",{class:"searchcraft-adm-ad",href:r.admAd.click_url},r.admAd.image_url&&f("div",{class:"searchcraft-adm-ad-image-wrapper"},f("img",{alt:r.admAd.term||"image",src:r.admAd.image_url,class:"searchcraft-adm-ad-image"})),f("div",{class:"searchcraft-adm-ad-info-wrapper"},f("p",{class:"searchcraft-adm-ad-title"},r.admAd.term),r.admAd.price&&f("p",{class:"searchcraft-adm-ad-subtitle"},r.admAd.price)))}renderCustomAd(){var o,a;const r=(a=(o=this.core)==null?void 0:o.config)==null?void 0:a.customAdTemplate,s=`searchcraft-custom-ad-${this.adContainerId}`;let n="<p>Custom Ad Placeholder</p>";return r&&(n=r({searchTerm:this.searchTerm||"",adContainerId:this.adContainerId})),f("div",{class:"searchcraft-custom-ad",id:s,"data-searchcraft-ad-container-id":this.adContainerId,innerHTML:Io.sanitize(n)})}renderNativoAd(){var s;const r=((s=this.core)==null?void 0:s.config.nativoAdClassName)||"ntv-item";return f("div",{class:r})}render(){if(!this.isSearchInProgress)switch(this.adSource){case"adMarketplace":return this.renderADMAd();case"Custom":return this.renderCustomAd();case"Nativo":return this.renderNativoAd();default:return}}},[0,"searchcraft-ad",{adSource:[1,"ad-source"],adClientResponseItem:[16],searchTerm:[32],isSearchInProgress:[32]}]);function kt(){if(typeof customElements>"u")return;["searchcraft-ad"].forEach(t=>{switch(t){case"searchcraft-ad":customElements.get(t)||customElements.define(t,Oo);break}})}const Fo=kt;function de(e,t){if(e&&t)return t.fieldNames.map(r=>{let s=e[r.fieldName];if(s)switch(r.dataType){case"date":{s=Do(s);break}case"number":{s=Intl.NumberFormat(r.numberFormatLocale,r.numberFormatOptions).format(s*(r.numberScale||1));break}}return s}).filter(r=>!!r).join(t.delimiter||" ")}function _s(e){switch(e){case"hour":return 36e5;case"day":return 864e5;case"month":return 2592e6;case"year":return 31536e6;default:return 36e5}}function cr(e){return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function Do(e){const t=new Date,r=new Date(e),s=Math.floor((t.getTime()-r.getTime())/1e3),n=Math.floor(s/60),o=Math.floor(n/60),a=Math.floor(o/24),c=Math.floor(a/365);return n<60?`${n}m ago`:o<24?`${o}h ago`:a<365?`${a}d ago`:`${c}y ago`}const No=U(class extends N{constructor(){super();h(this,"item");h(this,"searchResultMappings");h(this,"containerTarget","_blank");h(this,"containerRel");h(this,"buttonTarget","_blank");h(this,"buttonRel");h(this,"imagePlacement","right");h(this,"customStyles");h(this,"documentPosition",0);h(this,"titleContent");h(this,"subtitleContent");h(this,"bodyContent");h(this,"footerContent");h(this,"buttonLabel");h(this,"buttonHref");h(this,"containerHref");h(this,"imageSrc");h(this,"imageAlt");h(this,"searchcraftStore",A.getState());h(this,"handleLinkClick",()=>{var s;const r=this.searchcraftStore.getSearchcraftInstance();if(r){const n=this.documentPosition,o=this.searchcraftStore.searchTerm,a=this.searchcraftStore.searchClientResponseItems.length;(s=r.measureClient)==null||s.sendMeasureEvent("document_clicked",{document_position:n,number_of_documents:a,search_term:o})}});h(this,"parseStyles",()=>{if(this.customStyles)try{return JSON.parse(this.customStyles)}catch(r){return console.error("Error parsing custom styles:",r),{}}return{}});this.__registerHost()}connectedCallback(){this.item&&this.mapValuesFromDocument(this.item.document)}mapValuesFromDocument(r){var s,n,o,a,c,u,l;this.titleContent=de(r,(s=this.searchResultMappings)==null?void 0:s.title),this.subtitleContent=de(r,(n=this.searchResultMappings)==null?void 0:n.subtitle),this.bodyContent=de(r,(o=this.searchResultMappings)==null?void 0:o.body),this.containerHref=de(r,(a=this.searchResultMappings)==null?void 0:a.containerHref),this.buttonHref=de(r,(c=this.searchResultMappings)==null?void 0:c.buttonHref),this.imageSrc=de(r,(u=this.searchResultMappings)==null?void 0:u.imageSource),this.footerContent=de(r,(l=this.searchResultMappings)==null?void 0:l.footer)}render(){const r=this.parseStyles(),s=this.imageSrc&&f("img",{alt:this.imageAlt,class:"searchcraft-search-result-image",src:this.imageSrc,style:r.image||{}}),n=f(Jt,null,this.imageSrc&&this.imagePlacement==="left"&&s,f("div",{class:"searchcraft-base-search-result-content-container"},this.titleContent&&f("h2",{class:"searchcraft-base-search-result-title",style:r.title||{}},this.titleContent),this.subtitleContent&&f("h3",{class:"searchcraft-base-search-result-subtitle",style:r.subtitle||{}},this.subtitleContent),this.bodyContent&&f("p",{class:"searchcraft-base-search-result-body-content",style:r.primaryContent||{}},this.bodyContent),this.footerContent&&f("p",{class:"searchcraft-base-search-result-footer-content",style:r.secondaryContent||{}},this.footerContent),this.buttonHref&&!this.containerHref&&this.buttonLabel&&f("a",{class:"searchcraft-search-result-button",href:this.buttonHref,style:r.button||{},target:this.buttonTarget,rel:this.buttonRel},this.buttonLabel)),this.imageSrc&&this.imagePlacement==="right"&&s);return this.containerHref?f("a",{class:"searchcraft-search-result-container",onClick:this.handleLinkClick,href:this.containerHref,rel:this.containerRel,style:r.container||{},tabindex:"0",target:this.containerTarget},n):f("div",{class:"searchcraft-search-result-container",style:r.container||{}},n)}},[0,"searchcraft-base-search-result",{item:[16],searchResultMappings:[16],containerTarget:[1,"container-target"],containerRel:[1,"container-rel"],buttonTarget:[1,"button-target"],buttonRel:[1,"button-rel"],imagePlacement:[1,"image-placement"],customStyles:[1,"custom-styles"],documentPosition:[2,"document-position"],titleContent:[32],subtitleContent:[32],bodyContent:[32],footerContent:[32],buttonLabel:[32],buttonHref:[32],containerHref:[32],imageSrc:[32],imageAlt:[32]}]);function As(){if(typeof customElements>"u")return;["searchcraft-base-search-result"].forEach(t=>{switch(t){case"searchcraft-base-search-result":customElements.get(t)||customElements.define(t,No);break}})}const Uo=As;function rt(e){if(typeof e=="string")try{return JSON.parse(e)}catch{return console.error("Invalid customStyles format:",e),{}}return e||{}}function zo(e){try{return JSON.stringify(e)}catch(t){return console.error("Error serializing styles:",t),"{}"}}const Ho=U(class extends N{constructor(){super();h(this,"errorMessage");this.__registerHost()}render(){return f("p",{key:"dc97bb66da10a98fca027f928deaaf80d945417b",class:"searchcraft-error-message"},this.errorMessage||"Search term is required.")}},[0,"searchcraft-error-message",{errorMessage:[1,"error-message"]}]);function Tt(){if(typeof customElements>"u")return;["searchcraft-error-message"].forEach(t=>{switch(t){case"searchcraft-error-message":customElements.get(t)||customElements.define(t,Ho);break}})}const Bo=U(class extends N{constructor(){super();h(this,"customStylesForResults");h(this,"searchResultMappings");h(this,"resultImagePlacement","right");h(this,"buttonLabel");h(this,"buttonTarget","_blank");h(this,"buttonRel");h(this,"containerTarget","_blank");h(this,"containerRel");h(this,"searchTerm","");h(this,"searchClientResponseItems");h(this,"adClientResponseItems",[]);h(this,"searchResultsPerPage");h(this,"searchResultsPage");h(this,"isSearchInProgress",!0);h(this,"config");h(this,"unsubscribe",()=>{});this.__registerHost()}get serializedStyles(){let r="";return this.customStylesForResults&&(r=typeof this.customStylesForResults=="string"?this.customStylesForResults:zo(this.customStylesForResults)),r}componentDidLoad(){var s;this.unsubscribe=A.subscribe(n=>this.handleStateChange(n));const r=A.getState();this.handleStateChange(r),this.searchClientResponseItems=r.searchClientResponseItems,this.searchTerm=r.searchTerm,this.config=(s=r.core)==null?void 0:s.config}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleStateChange(r){var s;this.searchClientResponseItems=[...r.searchClientResponseItems],this.adClientResponseItems=[...r.adClientResponseItems],this.searchTerm=r.searchTerm,this.searchResultsPage=r.searchResultsPage,this.searchResultsPerPage=r.searchResultsPerPage,this.config=(s=r.core)==null?void 0:s.config,this.isSearchInProgress=r.isSearchInProgress}renderEmptyState(){return f("div",{class:"searchcraft-search-results-empty-state-container"},f("slot",{name:"empty-search"}))}renderNoResultsFoundState(){return f("div",{class:"searchcraft-search-results-container"},f("div",{class:"searchcraft-search-results-error-message-container"},f("searchcraft-error-message",{"error-message":`No search results found for "${this.searchTerm}" query`})))}renderWithADMAds(){var r,s;return f("div",{class:"searchcraft-search-results-container"},(r=this.adClientResponseItems)==null?void 0:r.map(n=>f("searchcraft-ad",{adSource:"adMarketplace",adClientResponseItem:n,key:n.id})),(s=this.searchClientResponseItems)==null?void 0:s.map((n,o)=>f("searchcraft-base-search-result",{key:n.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+o,searchResultMappings:this.searchResultMappings,item:n})))}renderWithCustomAds(){var u,l,i,p;const r=[],s=((u=this.config)==null?void 0:u.customAdInterstitialInterval)||0,n=((l=this.config)==null?void 0:l.customAdInterstitialQuantity)||1,o=((i=this.config)==null?void 0:i.customAdStartQuantity)||0,a=((p=this.config)==null?void 0:p.customAdEndQuantity)||0,c=this.searchClientResponseItems||[];for(let m=0;m<o;m++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m}-ad`}));c.forEach((m,b)=>{if(s&&b%s===0&&b+s<c.length&&b>=s)for(let v=0;v<n;v++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m.id}-ad-${v}`}));r.push(f("searchcraft-base-search-result",{key:m.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+b,searchResultMappings:this.searchResultMappings,item:m}))});for(let m=0;m<a;m++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m}-ad`}));return f("div",{class:"searchcraft-search-results-container"},r)}renderWithNativoAds(){var l,i,p,m,b;const r=[],s=((l=this.config)==null?void 0:l.nativoAdInterstialStartIndex)||0,n=((i=this.config)==null?void 0:i.nativoAdInterstitialInterval)||0,o=((p=this.config)==null?void 0:p.nativoAdInterstitialQuantity)||1,a=((m=this.config)==null?void 0:m.nativoAdStartQuantity)||0,c=((b=this.config)==null?void 0:b.nativoAdEndQuantity)||0,u=this.searchClientResponseItems||[];for(let v=0;v<a;v++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v}-ad`}));u.forEach((v,$)=>{if(n&&($+s)%n===0&&$+n<u.length&&$>=n)for(let z=0;z<o;z++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v.id}-ad-${z}`}));r.push(f("searchcraft-base-search-result",{key:v.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+$,searchResultMappings:this.searchResultMappings,item:v}))});for(let v=0;v<c;v++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v}-ad`}));return f("div",{class:"searchcraft-search-results-container"},r)}renderWithNoAds(){var r;return f("div",{class:"searchcraft-search-results-container"},(r=this.searchClientResponseItems)==null?void 0:r.map((s,n)=>f("searchcraft-base-search-result",{key:s.id,"custom-styles":this.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":this.searchResultsPerPage*(this.searchResultsPage-1)+n,searchResultMappings:this.searchResultMappings,item:s})))}render(){var r;if(this.searchTerm.trim()==="")return this.renderEmptyState();if(this.searchTerm.length>0&&(this.searchClientResponseItems||[]).length===0&&!this.isSearchInProgress)return this.renderNoResultsFoundState();switch(((r=this.config)==null?void 0:r.adSource)||"None"){case"adMarketplace":return this.renderWithADMAds();case"Custom":return this.renderWithCustomAds();case"Nativo":return this.renderWithNativoAds();default:return this.renderWithNoAds()}}},[4,"searchcraft-base-search-results",{customStylesForResults:[1,"custom-styles-for-results"],searchResultMappings:[16],resultImagePlacement:[1,"result-image-placement"],buttonLabel:[1,"button-label"],buttonTarget:[1,"button-target"],buttonRel:[1,"button-rel"],containerTarget:[1,"container-target"],containerRel:[1,"container-rel"],searchTerm:[32],searchClientResponseItems:[32],adClientResponseItems:[32],searchResultsPerPage:[32],searchResultsPage:[32],isSearchInProgress:[32],config:[32]}]);function jo(){if(typeof customElements>"u")return;["searchcraft-base-search-results","searchcraft-ad","searchcraft-base-search-result","searchcraft-error-message"].forEach(t=>{switch(t){case"searchcraft-base-search-results":customElements.get(t)||customElements.define(t,Bo);break;case"searchcraft-ad":customElements.get(t)||kt();break;case"searchcraft-base-search-result":customElements.get(t)||As();break;case"searchcraft-error-message":customElements.get(t)||Tt();break}})}const Vo=jo;var Is={exports:{}};/*!
31
31
  Copyright (c) 2018 Jed Watson.
32
32
  Licensed under the MIT License (MIT), see
33
33
  http://jedwatson.github.io/classnames
34
- */(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var o="",s=0;s<arguments.length;s++){var c=arguments[s];c&&(o=n(o,a(c)))}return o}function a(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return r.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var s="";for(var c in o)t.call(o,c)&&o[c]&&(s=n(s,c));return s}function n(o,s){return s?o?o+" "+s:o+s:o}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(Ia);const M=Ia.exports,jo=N(class extends D{constructor(){super();h(this,"hierarchy","primary");h(this,"disabled",!1);h(this,"icon");h(this,"iconOnly",!1);h(this,"iconPosition","left");h(this,"label","Search");h(this,"type","button");h(this,"buttonClick");h(this,"handleButtonClick",()=>{this.buttonClick.emit()});this.__registerHost(),this.buttonClick=Ce(this,"buttonClick")}render(){return d("button",{key:"ff883b930d03da6cbfb40badd3be1de0a873f853","aria-label":this.label,class:M("searchcraft-button",{"searchcraft-button-primary":this.hierarchy==="primary","searchcraft-button-tertiary":this.hierarchy==="tertiary","searchcraft-button-disabled":this.disabled}),disabled:this.disabled,onClick:this.handleButtonClick,type:this.type},this.iconOnly?this.icon:d(Jt,null,this.iconPosition==="left"&&this.icon,d("span",null,this.label),this.iconPosition==="right"&&this.icon))}},[0,"searchcraft-button",{hierarchy:[1],disabled:[4],icon:[16],iconOnly:[4,"icon-only"],iconPosition:[1,"icon-position"],label:[1],type:[1]}]);function xt(){if(typeof customElements>"u")return;["searchcraft-button"].forEach(t=>{switch(t){case"searchcraft-button":customElements.get(t)||customElements.define(t,jo);break}})}const Go=xt,Wo=Ct;function Ma(e,t){const r={...e};for(const a in t)t.hasOwnProperty(a)&&(t[a]instanceof Object&&e[a]instanceof Object?r[a]=Ma(e[a],t[a]):r[a]=t[a]);return r}function Vo(e){return e.filter((t,r,a)=>!a.some((n,o)=>o!==r&&n.includes(t)))}function La(e){const t={},r=a=>{var n;t[a.path]={count:a.count,path:a.path},(n=a.children)==null||n.forEach(o=>{r(o)})};return r(e),t}function qo(e){const t={count:0,path:"/",children:{}};return Object.keys(e).forEach(r=>{const a=e[r];if(!a||a.path==="/")return;const n=a.path.substring(1).split("/");let o=t,s="";n.forEach((c,u)=>{const l=`${s}/${c}`;o.children[l]||(o.children[l]={count:0,path:l,children:{}}),u===n.length-1&&(o.children[l].count=a.count),s=l,o=o.children[l]})}),t}function Oa(e){const t={count:e.count,path:e.path,children:[]};return Object.keys(e.children).length>0&&(t.children=Object.values(e.children).map(r=>Oa(r))),t}function Yo(e,t){const r=Object.keys(e),a=Object.keys(t),n=new Set(a.filter(s=>s.split("/").length>2).map(s=>s.substring(0,s.lastIndexOf("/"))));return Object.fromEntries(r.filter(s=>!n.has(s.substring(0,s.lastIndexOf("/")))).map(s=>[s,e[s]]))}function Ko(e,t,r){const a=t[e],n=r[e],o={count:0,path:"/",children:a},s={count:0,path:"/",children:n},c=La(o),u=La(s),l=Yo(c,u),i=Ma(l,u),p=qo(i),g=Oa(p);return{[e]:g.children}}const Xo=N(class extends D{constructor(){super();h(this,"fieldName","");h(this,"facetSelectionUpdated");h(this,"baseFacetRoot");h(this,"facetRoot");h(this,"selectedPaths",{});h(this,"lastTimeTaken");h(this,"hasNewSearchTerm",!1);h(this,"lastSearchTerm");h(this,"lastSearchMode");h(this,"lastSortType");h(this,"unsubscribe");h(this,"searchStore",_.getState());h(this,"formatLabel",r=>{const a=r.path.replace(/^\//,""),n=r.count;return`${a.replace(/-/g," ").replace(/\b\w/g,o=>o.toUpperCase())} (${n})`});h(this,"formatSubLabel",(r,a)=>{const o=r.path.substring(a.path.length).replace(/^\//,""),s=r.count;return`${o.replace(/-/g," ").replace(/\b\w/g,c=>c.toUpperCase())} (${s})`});this.__registerHost(),this.facetSelectionUpdated=Ce(this,"facetSelectionUpdated")}handleStateUpdate(r){const a=r.searchResponseFacetPrime,n=r.searchResponseTimeTaken;if(this.fieldName){if((r.searchTerm!==this.lastSearchTerm||r.searchMode!==this.lastSearchMode||r.sortType!==this.lastSortType)&&(this.selectedPaths={},this.hasNewSearchTerm=!0),n!==this.lastTimeTaken&&a){this.facetRoot=void 0;const o=a.find(s=>this.fieldName===Object.keys(s)[0]);this.hasNewSearchTerm?(this.baseFacetRoot=o,this.facetRoot=o,this.hasNewSearchTerm=!1):this.baseFacetRoot&&o&&(this.facetRoot=Ko(this.fieldName,this.baseFacetRoot,o))}this.lastSearchTerm=r.searchTerm,this.lastSearchMode=r.searchMode,this.lastSortType=r.sortType,this.lastTimeTaken=n}}connectedCallback(){this.handleStateUpdate(this.searchStore),this.unsubscribe=_.subscribe(r=>{this.handleStateUpdate(r)})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleCheckboxChange(r){var s;if(!this.selectedPaths[r])this.selectedPaths={...this.selectedPaths,[r]:!0};else{const c=Object.keys(this.selectedPaths).filter(u=>!u.includes(r));this.selectedPaths=c.reduce((u,l)=>(u[l]=!0,u),{})}const n=Object.keys(this.selectedPaths).filter(c=>this.selectedPaths[c]),o=Vo(n);(s=this.facetSelectionUpdated)==null||s.emit({paths:o})}render(){var a;if(!this.fieldName)return;const r=(a=this.facetRoot)==null?void 0:a[this.fieldName];return d("div",{class:M("filtersListContainer","searchcraft-filters-list-container")},!r&&d("p",{class:"searchcraft-facet-message"},"Enter a search to view facets."),r==null?void 0:r.map(n=>{var s;const o=n.children?(s=n.children)==null?void 0:s.some(c=>this.selectedPaths[c.path]):!1;return d("div",{key:n.path,class:M("searchcraft-filters-list-item")},d("label",{class:M("filterCheckboxLabel","searchcraft-filters-list-checkbox-label")},d("input",{checked:this.selectedPaths[n.path],onChange:c=>this.handleCheckboxChange(n.path),type:"checkbox"}),o?d("div",{class:M("dashContainer","searchcraft-filter-list-dash-container")},d("svg",{width:"14",height:"3",viewBox:"0 0 14 3",fill:"none"},d("title",null,"Checkbox Dash"),d("line",{x1:"1.5",y1:"1.5",x2:"12.5",y2:"1.5",stroke:"white","stroke-width":"3","stroke-linecap":"round"}))):d("div",{class:M("checkContainer","searchcraft-filter-list-check-container")},d("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},d("title",null,"Checkbox Check"),d("path",{d:"M13.9999 2L5.74988 10L1.99988 6.36364",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"}))),this.formatLabel(n)),n.children&&n.children.length>0&&d(Jt,null,n.children.map(c=>d("label",{key:c.path,class:M("childFilterCheckboxLabel","searchcraft-child-filter-checkbox-label"),style:{display:this.selectedPaths[n.path]?"flex":"none"}},d("input",{checked:this.selectedPaths[c.path],onChange:u=>{this.handleCheckboxChange(c.path)},type:"checkbox"}),d("div",{class:M("checkContainer","searchcraft-filter-list-check-container")},d("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},d("title",null,"Checkbox Check"),d("path",{d:"M13.9999 2L5.74988 10L1.99988 6.36364",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"}))),this.formatSubLabel(c,n)))))}))}},[0,"searchcraft-facet-list",{fieldName:[1,"field-name"],baseFacetRoot:[32],facetRoot:[32],selectedPaths:[32],lastTimeTaken:[32],hasNewSearchTerm:[32],lastSearchTerm:[32],lastSearchMode:[32],lastSortType:[32],unsubscribe:[32]}]);function Fa(){if(typeof customElements>"u")return;["searchcraft-facet-list"].forEach(t=>{switch(t){case"searchcraft-facet-list":customElements.get(t)||customElements.define(t,Xo);break}})}const Qo=Fa,Jo=N(class extends D{constructor(){super();h(this,"max",100);h(this,"min",0);h(this,"granularity",_a("month"));h(this,"dataType","number");h(this,"endValue",this.max);h(this,"startValue",this.min);h(this,"lastFocusedHandle","max");h(this,"rangeChanged");h(this,"emitUpdate",async()=>{var r;(r=this.rangeChanged)==null||r.emit({startValue:this.startValue,endValue:this.endValue})});h(this,"handleStartValueChange",r=>{const a=r.target,n=Number.parseInt(a.value,10);this.lastFocusedHandle="min",n<=this.endValue?(this.startValue=n,this.emitUpdate()):(this.startValue=this.endValue,a.value=`${this.endValue}`)});h(this,"handleEndValueChange",r=>{const a=r.target,n=Number.parseInt(a.value,10);this.lastFocusedHandle="max",n>=this.startValue?(this.endValue=n,this.emitUpdate()):(this.endValue=this.startValue,a.value=`${this.startValue}`)});this.__registerHost(),this.rangeChanged=Ce(this,"rangeChanged")}componentDidLoad(){this.startValue=this.min,this.endValue=this.max}render(){const r=this.min,a=this.max,n=(this.startValue-r)/(a-r)*100,o=(this.endValue-r)/(a-r)*100,s=this.dataType==="number"?this.startValue:new Date(this.startValue).getFullYear(),c=this.dataType==="number"?this.endValue:new Date(this.endValue).getFullYear();return d("div",{key:"ec4a36e1ce6534b7c077114086d759e0b1e7a24e",class:"searchcraft-slider-container"},d("div",{key:"35487cbeaeeb23052631804704645ca929340f70",class:"searchcraft-slider-range-container"},d("div",{key:"186e699def8e7a6e58e8ad5f04953ac1c6584344",class:"searchcraft-slider-active-range",style:{left:`${n}%`,width:`${o-n}%`}}),d("input",{key:"97638e2a1471888c2be47f7526e9dd98fea58683",class:M("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}),d("input",{key:"db2abded80b606d17bde1677e4acc09a85e6e20e",class:M("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})),d("div",{key:"83954b6955a872a17377d506d2d8458059acac03",class:"searchcraft-slider-label-container"},d("span",{key:"b5315b4438385ecf5df3f76579fdf102b6a8c39c",class:"searchcraft-slider-label"},s),d("span",{key:"875094ac7ee69e04c3a16407388dd27f167b3c8f",class:"searchcraft-slider-label"},c)))}},[0,"searchcraft-slider",{max:[2],min:[2],granularity:[2],dataType:[1,"data-type"],endValue:[32],startValue:[32],lastFocusedHandle:[32]}]);function Da(){if(typeof customElements>"u")return;["searchcraft-slider"].forEach(t=>{switch(t){case"searchcraft-slider":customElements.get(t)||customElements.define(t,Jo);break}})}const Zo=N(class extends D{constructor(){super();h(this,"label","Toggle");h(this,"subLabel");h(this,"toggleUpdated");h(this,"isActive",!1);h(this,"unsubscribe");h(this,"lastSearchTerm");h(this,"handleToggle",async()=>{var r;this.isActive=!this.isActive,(r=this.toggleUpdated)==null||r.emit(this.isActive)});this.__registerHost(),this.toggleUpdated=Ce(this,"toggleUpdated")}connectedCallback(){this.unsubscribe=_.subscribe(r=>{r.searchTerm!==this.lastSearchTerm&&r.searchTerm.trim().length===0&&(this.isActive=!1),this.lastSearchTerm=r.searchTerm})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}render(){return d("div",{key:"25f3acd2b5dd6837182c8f07c092c54c35542c2f",class:"searchcraft-toggle-button-container"},d("div",{key:"d2951f2673af55159ad6f39d381d272a3f9f872b"},d("p",{key:"2468e261d46b454ce896b614ca2a076d27a31a8b",class:"searchcraft-toggle-button-label"},this.label),this.subLabel&&d("p",{key:"1d9887dc12f30fb1982cf0d8a692ebfeca8edc1a",class:"searchcraft-toggle-button-sub-label"},this.subLabel)),d("button",{key:"f51bb553d6b210233aa6ebfc4318aa521036d922",class:M("searchcraft-toggle-button-background",{active:this.isActive}),onClick:this.handleToggle,type:"button"},d("div",{key:"a34339f1bb5ab4742d897b01b61fe6c8c23e7e1e",class:M("searchcraft-toggle-button-handle",{active:this.isActive})})))}},[0,"searchcraft-toggle-button",{label:[1],subLabel:[1,"sub-label"],isActive:[32],unsubscribe:[32],lastSearchTerm:[32]}]);function Na(){if(typeof customElements>"u")return;["searchcraft-toggle-button"].forEach(t=>{switch(t){case"searchcraft-toggle-button":customElements.get(t)||customElements.define(t,Zo);break}})}const ei=N(class extends D{constructor(){super();h(this,"items",[]);h(this,"unsubscribe");h(this,"lastSearchTerm");h(this,"searchStore",_.getState());this.__registerHost()}componentDidLoad(){this.unsubscribe=_.subscribe(r=>{this.lastSearchTerm=r.searchTerm||""})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleDateRangeChanged(r,a,n){const o=new Date(new Date(a).getFullYear(),0,1),s=new Date(new Date(n).getFullYear()+1,0,0);this.searchStore.addRangeValueForIndexField({fieldName:r,value:`${r}:[${o.toISOString()} TO ${s.toISOString()}]`}),this.searchStore.search()}handleNumericRangeChanged(r,a,n){this.searchStore.addRangeValueForIndexField({fieldName:r,value:`${r}:[${a} TO ${n}]`}),this.searchStore.search()}handleFacetSelectionUpdated(r,a){a.length>0?this.searchStore.addFacetPathsForIndexField({fieldName:r,value:`${r}: IN [${a.join(" ")}]`}):this.searchStore.removeFacetPathsForIndexField(r),this.searchStore.search()}handleExactMatchToggleUpdated(r){this.searchStore.setSearchMode(r?"exact":"fuzzy"),this.searchStore.search()}handleMostRecentToggleUpdated(r){this.searchStore.setSortType(r?"desc":"asc"),this.searchStore.search()}render(){return d("div",{key:"73ca2e0efab911c5095c23ba33e85a26cc440b4a",class:"searchcraft-filter-panel"},this.items.map(r=>{switch(r.type){case"dateRange":{const a=r,n=new Date(a.options.minDate).getTime(),o=new Date(a.options.maxDate).getTime(),s=_a(a.options.granularity);return d("div",{class:"searchcraft-filter-panel-section"},d("p",{class:"searchcraft-filter-panel-label"},r.label),d("searchcraft-slider",{min:n,max:o,granularity:s,dataType:"date",onRangeChanged:c=>{this.handleDateRangeChanged(a.fieldName,c.detail.startValue,c.detail.endValue)}}))}case"numericRange":{const a=r;return d("div",{class:"searchcraft-filter-panel-section"},d("p",{class:"searchcraft-filter-panel-label"},r.label),d("searchcraft-slider",{min:a.options.min,max:a.options.max,granularity:a.options.granularity,onRangeChanged:n=>{this.handleNumericRangeChanged(a.fieldName,n.detail.startValue,n.detail.endValue)}}))}case"facets":{const a=r;return d("div",{class:"searchcraft-filter-panel-section"},d("p",{class:"searchcraft-filter-panel-label"},r.label),d("searchcraft-facet-list",{fieldName:a.fieldName,onFacetSelectionUpdated:n=>{this.handleFacetSelectionUpdated(a.fieldName,n.detail.paths)}}))}case"exactMatchToggle":{const a=r;return d("searchcraft-toggle-button",{label:a.label,subLabel:a.options.subLabel,onToggleUpdated:n=>{this.handleExactMatchToggleUpdated(n.detail)}})}case"mostRecentToggle":{const a=r;return d("searchcraft-toggle-button",{label:a.label,subLabel:a.options.subLabel,onToggleUpdated:n=>{this.handleMostRecentToggleUpdated(n.detail)}})}}}))}},[0,"searchcraft-filter-panel",{items:[16],unsubscribe:[32],lastSearchTerm:[32]}]);function ti(){if(typeof customElements>"u")return;["searchcraft-filter-panel","searchcraft-facet-list","searchcraft-slider","searchcraft-toggle-button"].forEach(t=>{switch(t){case"searchcraft-filter-panel":customElements.get(t)||customElements.define(t,ei);break;case"searchcraft-facet-list":customElements.get(t)||Fa();break;case"searchcraft-slider":customElements.get(t)||Da();break;case"searchcraft-toggle-button":customElements.get(t)||Na();break}})}const ri=ti,ai=N(class extends D{constructor(){super();h(this,"inputLabelClassName","");h(this,"label","");this.__registerHost()}render(){return d("label",{key:"528396d4be9f22ff0c02d95d8bcea056576aed41",class:M("searchcraft-input-label",this.inputLabelClassName),htmlFor:"searchcraft-input-id"},this.label)}},[0,"searchcraft-input-label",{inputLabelClassName:[1,"input-label-class-name"],label:[1]}]);function lr(){if(typeof customElements>"u")return;["searchcraft-input-label"].forEach(t=>{switch(t){case"searchcraft-input-label":customElements.get(t)||customElements.define(t,ai);break}})}const si=N(class extends D{constructor(){super();h(this,"autoSearch",!0);h(this,"buttonPlacement","none");h(this,"buttonLabel");h(this,"inputLabel");h(this,"customStyles",{});h(this,"placeholderValue","Enter Search");h(this,"searchTerm","");h(this,"inputFocus");h(this,"inputBlur");h(this,"inputInit");h(this,"inputValue",this.searchTerm);h(this,"error",!1);h(this,"core");h(this,"searchStore",_.getState());h(this,"handleOnInput",r=>{const a=r.target;this.inputValue=a.value,this.autoSearch&&this.performSearch(a.value)});h(this,"performSearch",async r=>{if(r!==_.getState().searchTerm){this.searchTerm=r.trim(),this.error=!1,this.searchStore.setSearchTerm(this.searchTerm);try{await this.searchStore.search()}catch(a){console.log(a),this.error=!0}}});h(this,"handleClearInput",()=>{this.inputValue="",this.searchTerm="",this.searchStore.setSearchTerm(""),this.searchStore.setSearchClientResponseItems([]),this.error=!1});h(this,"handleFormSubmit",async r=>{r.preventDefault(),await this.performSearch(this.searchTerm)});this.__registerHost(),this.inputFocus=Ce(this,"inputFocus"),this.inputBlur=Ce(this,"inputBlur"),this.inputInit=Ce(this,"inputInit")}init(){var r;this.core&&(this.searchStore.initialize(this.core),(r=this.inputInit)==null||r.emit())}connectedCallback(){this.init()}onCoreChange(){this.init()}render(){const r=rt(this.customStyles),a=this.inputValue.length>0,n=M("searchcraft-input-grid",{"searchcraft-input-grid-buttonLeft":this.buttonPlacement==="left","searchcraft-input-grid-buttonRight":this.buttonPlacement==="right","searchcraft-input-grid-buttonNone":this.buttonPlacement==="none"}),s={gap:this.inputLabel||this.error?"4px 8px":"0px 8px"};return d("form",{key:"52760b113a209c51638bcb005e0b6c3d5bf9741d",class:"searchcraft-input-form",onSubmit:this.handleFormSubmit},d("div",{key:"6b20020b8a67c9d860fca7da67150a8d75bd3313",class:n,style:s},d("div",{key:"67bba2889e6fde70c4f349dfbd61d9a632c08301",class:"searchcraft-input-button-wrapper"},d("searchcraft-button",{key:"a839e1a67d238bfbe6d47857f6339e49d14f9560",onButtonClick:this.handleFormSubmit,label:this.buttonLabel})),this.inputLabel&&d("div",{key:"a2a69b7dbdf1142459d6ffad90dc26a38a76276d",class:"searchcraft-input-label-wrapper"},d("searchcraft-input-label",{key:"621a4903821ba8c1854e3ff89d30a24dba3ed0fb",label:this.inputLabel})),this.error&&d("div",{key:"b4cd633a139488cac185c38123b138fc5d51cd20",class:"searchcraft-input-error-wrapper"},d("searchcraft-error-message",{key:"ccadaf96ac8317b6415a83e6523816328e83eb3e",errorMessage:"Something went wrong."})),d("div",{key:"0f13777c2e5f806ce12fff9680d7862a27b2e260",class:"searchcraft-input-wrapper"},d("input",{key:"a9b58a486dfaadaedf3eeb9aec5e4c3c3548536b",autoComplete:"off",class:"searchcraft-input",onFocus:()=>{var c;return(c=this.inputFocus)==null?void 0:c.emit()},onBlur:()=>{var c;return(c=this.inputBlur)==null?void 0:c.emit()},onInput:c=>{this.handleOnInput(c)},placeholder:this.placeholderValue,style:r,type:"text",value:this.inputValue}),d("div",{key:"a57e4f72ee1383e42158bbc9e35d47d2c468acf5",class:"searchcraft-input-search-icon-wrapper"},d("svg",{key:"c7bda92af1488981d5de08af0f9ae3064c76c354",class:"searchcraft-input-search-icon",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},d("title",{key:"f4dc47ae6c88517eeaea574fe819423b3d6e6cb5",id:"searchcraft-title"},"Searchcraft Search Icon Light"),d("path",{key:"c77497591b4f31de0f3e008baa79c006fd0a2eb9",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:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))),a&&d("button",{key:"e125b759eaa21dfdd4058bf36f3c10233f067835",type:"button",class:"searchcraft-input-clear-button",onClick:this.handleClearInput},d("svg",{key:"b2767658bb9edbc51efd6430e051127b08c9ab83",class:"searchcraft-input-clear-icon",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},d("title",{key:"990ff3c8f207d09192e954b0f5d059e0683db2d4",id:"icon-title"},"Searchcraft Clear Input Icon Light"),d("path",{key:"5322d9abb4d60a75869ca943a17157a32c502035",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:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))))))}static get watchers(){return{core:["onCoreChange"]}}},[0,"searchcraft-input-form",{autoSearch:[4,"auto-search"],buttonPlacement:[1,"button-placement"],buttonLabel:[1,"button-label"],inputLabel:[1,"input-label"],customStyles:[1,"custom-styles"],placeholderValue:[1,"placeholder-value"],searchTerm:[1,"search-term"],core:[16],inputValue:[32],error:[32]},void 0,{core:["onCoreChange"]}]);function Ua(){if(typeof customElements>"u")return;["searchcraft-input-form","searchcraft-button","searchcraft-error-message","searchcraft-input-label"].forEach(t=>{switch(t){case"searchcraft-input-form":customElements.get(t)||customElements.define(t,si);break;case"searchcraft-button":customElements.get(t)||xt();break;case"searchcraft-error-message":customElements.get(t)||Ct();break;case"searchcraft-input-label":customElements.get(t)||lr();break}})}const ni=Ua,oi=lr,ii=N(class extends D{constructor(){super();h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPerPage");h(this,"searchResultsPage");h(this,"searchResultsCount");h(this,"searchResultsPagesCount",1);h(this,"searchResultsRangeMin",1);h(this,"searchResultsRangeMax",1);h(this,"setSearchResultsPage",()=>{});h(this,"unsubscribe",()=>{});this.__registerHost()}componentDidLoad(){this.unsubscribe=_.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsPage=r.searchResultsPage,this.searchResultsCount=r.searchResultsCount,this.searchResultsPagesCount=Math.ceil(this.searchResultsCount/this.searchResultsPerPage),this.searchResultsRangeMin=(this.searchResultsPage-1)*this.searchResultsPerPage+1,this.searchResultsRangeMax=(this.searchResultsPerPage-1)*this.searchResultsPerPage+this.searchResultsPerPage,this.setSearchResultsPage=r.setSearchResultsPage})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleGoToPage(r){this.setSearchResultsPage(r)}renderOddPaginationItem(r){return d("li",null,d("button",{class:M("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===r}),onClick:()=>this.handleGoToPage(r),type:"button"},r))}renderEvenPaginationItem(r){if(!(this.searchResultsPagesCount<=r))return(this.searchResultsPagesCount<=5||r<Math.ceil(this.searchResultsPagesCount/2)?this.searchResultsPage<=r+1:this.searchResultsPage>=r-1)?d("li",null,d("button",{class:M("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===r}),onClick:()=>this.handleGoToPage(r),type:"button"},r)):d("li",null,d("span",{class:"searchcraft-pagination-item"},"..."))}renderMiddlePaginationItem(){if(!(this.searchResultsPagesCount<=3))return this.searchResultsPagesCount<=5||this.searchResultsPage<=3||this.searchResultsPage>=this.searchResultsPagesCount-2?d("li",null,d("button",{class:M("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===3||this.searchResultsPage===this.searchResultsPagesCount-2}),type:"button",onClick:()=>this.handleGoToPage(this.searchResultsPage>=this.searchResultsPagesCount-2?this.searchResultsPagesCount-2:3)},this.searchResultsPage>=this.searchResultsPagesCount-2?this.searchResultsPagesCount-2:3)):d("li",null,d("span",{class:"searchcraft-pagination-item searchcraft-pagination-item-active"},this.searchResultsPage))}render(){if(!(!this.searchTerm||this.searchResultsPagesCount<=1))return d("div",{class:M("searchcraft-pagination",rt(this.customStyles||{}))},d("div",{class:"searchcraft-pagination-control"},d("searchcraft-button",{disabled:this.searchResultsPage===1,hierarchy:"tertiary",onButtonClick:()=>this.handleGoToPage(Math.max(1,this.searchResultsPage-1)),label:"Previous",iconPosition:"left",icon:d("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("title",null,"Previous page icon"),d("path",{d:"M12.5 15L7.5 10L12.5 5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})),iconOnly:!0})),d("ul",{class:"searchcraft-pagination-list"},this.renderOddPaginationItem(1),this.renderEvenPaginationItem(2),this.renderMiddlePaginationItem(),this.renderEvenPaginationItem(this.searchResultsPagesCount>4?this.searchResultsPagesCount-1:4),this.renderOddPaginationItem(this.searchResultsPagesCount)),d("div",{class:"searchcraft-pagination-control"},d("searchcraft-button",{disabled:this.searchResultsPage===this.searchResultsPagesCount,hierarchy:"tertiary",onButtonClick:()=>{this.handleGoToPage(Math.min(this.searchResultsPagesCount,this.searchResultsPage+1))},label:"Next",iconPosition:"right",icon:d("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("title",null,"Next page icon"),d("path",{d:"M7.5 15L12.5 10L7.5 5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})),iconOnly:!0})))}},[0,"searchcraft-pagination",{customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPerPage:[32],searchResultsPage:[32],searchResultsCount:[32],searchResultsPagesCount:[32],searchResultsRangeMin:[32],searchResultsRangeMax:[32],setSearchResultsPage:[32]}]);function ci(){if(typeof customElements>"u")return;["searchcraft-pagination","searchcraft-button"].forEach(t=>{switch(t){case"searchcraft-pagination":customElements.get(t)||customElements.define(t,ii);break;case"searchcraft-button":customElements.get(t)||xt();break}})}const li=ci,ui=N(class extends D{constructor(){super(),this.__registerHost()}handleOnClick(){_.getState().setPopoverVisibility(!0)}render(){return d("button",{key:"a8ee70b49a5309cfb1363a272ea0870c48c59688",type:"button",onClick:this.handleOnClick.bind(this)},d("slot",{key:"9ac712ed1f6e69d73e7ade3d42501fb67a02c7ff"}))}},[4,"searchcraft-popover-button"]);function hi(){if(typeof customElements>"u")return;["searchcraft-popover-button"].forEach(t=>{switch(t){case"searchcraft-popover-button":customElements.get(t)||customElements.define(t,ui);break}})}const fi=hi,di=N(class extends D{constructor(){super();h(this,"item");h(this,"popoverResultMappings");h(this,"documentPosition",0);h(this,"href");h(this,"imageSrc");h(this,"imageAlt");h(this,"titleContent");h(this,"subtitleContent");h(this,"handleLinkClick",()=>{var n;const r=_.getState(),a=r.getSearchcraftInstance();if(a){const o=this.documentPosition,s=r.searchTerm,c=r.searchClientResponseItems.length||0;(n=a.measureClient)==null||n.sendMeasureEvent("document_clicked",{document_position:o,number_of_documents:c,search_term:s})}});this.__registerHost()}mapValuesFromDocument(r){var a,n,o,s,c;this.titleContent=he(r,(a=this.popoverResultMappings)==null?void 0:a.title),this.subtitleContent=he(r,(n=this.popoverResultMappings)==null?void 0:n.subtitle),this.href=he(r,(o=this.popoverResultMappings)==null?void 0:o.href),this.imageSrc=he(r,(s=this.popoverResultMappings)==null?void 0:s.imageSource),this.imageAlt=he(r,(c=this.popoverResultMappings)==null?void 0:c.imageAlt)}connectedCallback(){this.item&&this.mapValuesFromDocument(this.item.document)}disconnectedCallback(){}render(){return d("a",{key:"870fae8c0019ea24d9ecd173a781a38e3b17f8de",class:"searchcraft-popover-list-item",href:this.href,onClick:this.handleLinkClick.bind(this)},this.imageSrc&&d("div",{key:"9e200a2be177fed7f6303fdc1ba466fc47817b5d",class:"searchcraft-popover-list-item-image-wrapper"},d("img",{key:"22124b2856cd41220ac852a1fbc94cbf2a1cd9f9",alt:this.imageAlt,src:this.imageSrc,class:"searchcraft-popover-list-item-image"})),d("div",{key:"b3f0bb6784a36befd044e71798915994093177ab",class:"searchcraft-popover-list-item-info-wrapper"},d("p",{key:"caa22a8d68b56814ee29498db48fe1c65d8d7644",class:"searchcraft-popover-list-item-title"},this.titleContent),d("p",{key:"63e11be221d6f274855f7989b3a9dc4532c08e05",class:"searchcraft-popover-list-item-subtitle"},this.subtitleContent)))}},[0,"searchcraft-popover-list-item",{item:[16],popoverResultMappings:[16],documentPosition:[2,"document-position"],href:[32],imageSrc:[32],imageAlt:[32],titleContent:[32],subtitleContent:[32]}]);function ur(){if(typeof customElements>"u")return;["searchcraft-popover-list-item"].forEach(t=>{switch(t){case"searchcraft-popover-list-item":customElements.get(t)||customElements.define(t,di);break}})}const pi=N(class extends D{constructor(){super();h(this,"popoverResultMappings");h(this,"searchClientResponseItems");h(this,"adClientResponseItems");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"config",(Ya=_.getState().core)==null?void 0:Ya.config);this.__registerHost()}renderWithADMAds(){var r,a;return d("div",{class:"searchcraft-popover-list-view"},(r=this.adClientResponseItems)==null?void 0:r.map(n=>d("searchcraft-ad",{adClientResponseItem:n,adSource:"adMarketplace",key:n.id})),(a=this.searchClientResponseItems)==null?void 0:a.map((n,o)=>d("searchcraft-popover-list-item",{item:n,key:n.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+o})))}renderWithCustomAds(){var u,l,i,p;const r=[],a=((u=this.config)==null?void 0:u.customAdInterstitialInterval)||0,n=((l=this.config)==null?void 0:l.customAdInterstitialQuantity)||1,o=((i=this.config)==null?void 0:i.customAdStartQuantity)||0,s=((p=this.config)==null?void 0:p.customAdEndQuantity)||0,c=this.searchClientResponseItems||[];for(let g=0;g<o;g++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g}-ad`}));c.forEach((g,S)=>{if(a&&S%a===0&&S+a<c.length&&S>=a)for(let P=0;P<n;P++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g.id}-ad-${P}`}));r.push(d("searchcraft-popover-list-item",{item:g,key:g.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+S}))});for(let g=0;g<s;g++)r.push(d("searchcraft-ad",{adSource:"Custom",key:`${g}-ad`}));return d("div",{class:"searchcraft-popover-list-view"},r)}renderWithNoAds(){var r;return d("div",{class:"searchcraft-popover-list-view"},(r=this.searchClientResponseItems)==null?void 0:r.map((a,n)=>d("searchcraft-popover-list-item",{item:a,key:a.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+n})))}render(){var r;switch(((r=this.config)==null?void 0:r.adSource)||"None"){case"adMarketplace":return this.renderWithADMAds();case"Custom":return this.renderWithCustomAds();default:return this.renderWithNoAds()}}},[0,"searchcraft-popover-list-view",{popoverResultMappings:[16],searchClientResponseItems:[16],adClientResponseItems:[16],searchResultsPage:[2,"search-results-page"],searchResultsPerPage:[2,"search-results-per-page"]}]);function za(){if(typeof customElements>"u")return;["searchcraft-popover-list-view","searchcraft-ad","searchcraft-popover-list-item"].forEach(t=>{switch(t){case"searchcraft-popover-list-view":customElements.get(t)||customElements.define(t,pi);break;case"searchcraft-ad":customElements.get(t)||Tt();break;case"searchcraft-popover-list-item":customElements.get(t)||ur();break}})}const mi=N(class extends D{constructor(){super();h(this,"type","inline");h(this,"popoverResultMappings");h(this,"hotkey","k");h(this,"hotkeyModifier","meta");h(this,"isPopoverVisibleInState",!1);h(this,"unsubscribe");h(this,"searchClientResponseItems",[]);h(this,"adClientResponseItems",[]);h(this,"searchTerm");h(this,"isFocused",!1);h(this,"breakpointSm",576);h(this,"breakpointMd",768);h(this,"breakpointLg",992);h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"modalElement");h(this,"handleDocumentClick",r=>{this.hostElement.contains(r.target)||(this.isFocused=!1)});h(this,"handleDocumentKeyDown",r=>{if(r.key===this.hotkey&&this.handleHotkeyPressed(r),!!this.hostElement.contains(document.activeElement))switch(r.key){case"ArrowDown":case"ArrowUp":r.preventDefault(),this.focusOnNextListItem(r.key);break;case"Escape":_.getState().setPopoverVisibility(!1);break;default:return}});h(this,"handleInputInit",()=>{const r=this.hostElement.querySelector(".searchcraft-input");r==null||r.focus()});this.__registerHost()}get hostElement(){return this}componentDidLoad(){const r=getComputedStyle(document.documentElement);this.breakpointSm=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-sm").trim()),this.breakpointMd=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-md").trim()),this.breakpointLg=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-lg").trim()),this.isPopoverVisibleInState=_.getState().isPopoverVisible,document.addEventListener("click",this.handleDocumentClick),document.addEventListener("keydown",this.handleDocumentKeyDown),this.unsubscribe=_.subscribe(a=>{this.isPopoverVisibleInState!==a.isPopoverVisible&&this.handlePopoverVisibilityChange(a.isPopoverVisible),this.searchClientResponseItems=[...a.searchClientResponseItems],this.adClientResponseItems=[...a.adClientResponseItems],this.searchTerm=a.searchTerm,this.searchResultsPage=a.searchResultsPage,this.searchResultsPerPage=a.searchResultsPerPage})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this),document.removeEventListener("click",this.handleDocumentClick),document.removeEventListener("keydown",this.handleDocumentKeyDown)}handlePopoverVisibilityChange(r){this.isPopoverVisibleInState=r,document.body.style.overflow=r?"hidden":"auto"}handleInputFocus(){this.isFocused=!0,this.type==="inline"&&window.visualViewport&&window.visualViewport.width<this.breakpointSm&&(_.getState().setPopoverVisibility(!0),this.modalElement||(this.modalElement=document.createElement("searchcraft-popover-form"),this.modalElement.popoverResultMappings=this.popoverResultMappings,this.modalElement.setAttribute("type","fullscreen"),document.body.appendChild(this.modalElement)))}handleModalBackdropClick(r){_.getState().setPopoverVisibility(!1)}handleHotkeyPressed(r){if(r.ctrlKey&&this.hotkeyModifier==="ctrl"||r.altKey&&this.hotkeyModifier==="alt"||r.metaKey&&this.hotkeyModifier==="meta")if(r.preventDefault(),this.type==="inline"&&!this.isPopoverVisibleInState){const a=this.hostElement.querySelector(".searchcraft-input");a==null||a.focus()}else _.getState().setPopoverVisibility(!this.isPopoverVisibleInState)}handleCancelButtonClick(){_.getState().setPopoverVisibility(!1)}focusOnNextListItem(r){var o,s;const a=Array.from(document.querySelectorAll("a.searchcraft-popover-list-item")).filter(c=>!c.hasAttribute("disabled")&&c.offsetParent!==null),n=a.indexOf(document.activeElement);if(r==="ArrowDown")(o=a[(n+1)%a.length])==null||o.focus();else if(r==="ArrowUp")if(n>=1)(s=a[n-1])==null||s.focus();else{const c=document.querySelector(".searchcraft-input");c&&(c.focus(),requestAnimationFrame(()=>{c.selectionEnd=c.value.length,c.selectionStart=c.value.length}))}}get hasResultsToShow(){var r,a;return this.searchTerm&&((a=(r=this.searchTerm)==null?void 0:r.trim())==null?void 0:a.length)>0&&this.searchClientResponseItems.length>0}renderInlinePopover(){const r=this.hasResultsToShow&&this.isFocused,a=M("searchcraft-popover-form searchcraft-popover-form-inline",{"searchcraft-popover-form-active":r});return d("div",{class:a},d("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this)}),r&&d("div",{class:"searchcraft-popover-inline-wrapper-outer"},d("div",{class:"searchcraft-popover-inline-wrapper-inner"},d("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage}))))}renderModalPopover(){if(this.isPopoverVisibleInState){const r=M("searchcraft-popover-form",{"searchcraft-popover-form-active":this.hasResultsToShow});return d("div",{class:"searchcraft-popover-form-modal"},d("div",{class:"searchcraft-popover-form-modal-backdrop",onClick:this.handleModalBackdropClick}),d("div",{class:"searchcraft-popover-form-modal-inner"},d("div",{class:r},d("div",{class:"searchcraft-popover-form-input-wrapper"},d("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this),onInputInit:this.handleInputInit.bind(this)}),d("button",{type:"button",class:"searchcraft-popover-form-cancel-button",onClick:this.handleCancelButtonClick.bind(this)},"Cancel")),this.hasResultsToShow&&d("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage}))))}}renderFullscreenPopover(){if(this.isPopoverVisibleInState)return d("div",{class:"searchcraft-popover-form-fullscreen"},d("div",{class:"searchcraft-popover-form"},d("div",{class:"searchcraft-popover-form-input-wrapper"},d("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this),onInputInit:this.handleInputInit.bind(this)}),d("button",{type:"button",class:"searchcraft-popover-form-cancel-button",onClick:this.handleCancelButtonClick.bind(this)},"Cancel")),this.hasResultsToShow&&d("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage})))}render(){switch(this.type){case"inline":return this.renderInlinePopover();case"modal":return this.renderModalPopover();case"fullscreen":return this.renderFullscreenPopover()}}},[0,"searchcraft-popover-form",{type:[1],popoverResultMappings:[16],hotkey:[1],hotkeyModifier:[1,"hotkey-modifier"],isPopoverVisibleInState:[32],unsubscribe:[32],searchClientResponseItems:[32],adClientResponseItems:[32],searchTerm:[32],isFocused:[32],breakpointSm:[32],breakpointMd:[32],breakpointLg:[32],searchResultsPage:[32],searchResultsPerPage:[32],modalElement:[32]}]);function Ha(){if(typeof customElements>"u")return;["searchcraft-popover-form","searchcraft-ad","searchcraft-button","searchcraft-error-message","searchcraft-input-form","searchcraft-input-label","searchcraft-popover-form","searchcraft-popover-list-item","searchcraft-popover-list-view"].forEach(t=>{switch(t){case"searchcraft-popover-form":customElements.get(t)||customElements.define(t,mi);break;case"searchcraft-ad":customElements.get(t)||Tt();break;case"searchcraft-button":customElements.get(t)||xt();break;case"searchcraft-error-message":customElements.get(t)||Ct();break;case"searchcraft-input-form":customElements.get(t)||Ua();break;case"searchcraft-input-label":customElements.get(t)||lr();break;case"searchcraft-popover-form":customElements.get(t)||Ha();break;case"searchcraft-popover-list-item":customElements.get(t)||ur();break;case"searchcraft-popover-list-view":customElements.get(t)||za();break}})}const gi=Ha,bi=ur,vi=za,yi=N(class extends D{constructor(){super();h(this,"customFormatter");h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"searchResultsCount");h(this,"count",0);h(this,"range",[0,0]);h(this,"responseTime","0");h(this,"unsubscribe",()=>{});this.__registerHost()}connectedCallback(){this.unsubscribe=_.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPage=r.searchResultsPage,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsCount=r.searchResultsCount,this.count=this.searchResultsCount,this.range[0]=this.searchResultsPage<=1?1:this.searchResultsPerPage*(this.searchResultsPage-1),this.range[1]=this.searchResultsPerPage*this.searchResultsPage,this.range[1]=this.range[1]>this.searchResultsCount?this.searchResultsCount:this.range[1],this.responseTime=((r.searchResponseTimeTaken||0)*1e3).toFixed(2)})}disconnectedCallback(){this.unsubscribe&&this.unsubscribe()}render(){return!this.searchTerm||this.searchResultsCount===0?null:d("p",{class:M("searchcraft-results-info",rt(this.customStyles||{}))},this.customFormatter?this.customFormatter([cr(this.range[0]),cr(this.range[1])],cr(this.count),this.responseTime):`${this.count} results found in ${this.responseTime}ms`)}},[0,"searchcraft-results-info",{customFormatter:[16],customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPage:[32],searchResultsPerPage:[32],searchResultsCount:[32],count:[32],range:[32],responseTime:[32]}]);function Si(){if(typeof customElements>"u")return;["searchcraft-results-info"].forEach(t=>{switch(t){case"searchcraft-results-info":customElements.get(t)||customElements.define(t,yi);break}})}const wi=Si,Ri=N(class extends D{constructor(){super();h(this,"caption");h(this,"disabled",!1);h(this,"inputId");h(this,"label");h(this,"labelId");h(this,"name");h(this,"options",[]);h(this,"customStyles");h(this,"selectChange");h(this,"searchResultsPerPage");h(this,"setSearchResultsPage",()=>{});h(this,"setSearchResultsPerPage",()=>{});h(this,"handleSelectChange",r=>{this.selectChange.emit(r.target.value)});this.__registerHost(),this.selectChange=Ce(this,"selectChange")}handleGoToPage(r){this.setSearchResultsPage(r)}render(){return d("div",{key:"5024d49d89a3649a5de591d37ded304a9dfb36d9",class:M("searchcraft-select",rt(this.customStyles||{}))},this.label&&d("label",{key:"005aea9b190e5a6c041721e20395be23f76faab6",class:"searchcraft-select-label",id:this.labelId||`${this.inputId}-label`,htmlFor:this.inputId},this.label),d("div",{key:"209d56844c0bcd241e73bafcad24fac927fe7ffa",class:"searchcraft-select-input-wrapper"},d("select",{key:"010c9e596ef45a303f84c0ac0fa54ab67556d7b6","aria-labelledby":this.label?this.labelId||`${this.inputId}-label`:void 0,class:"searchcraft-select-input",disabled:this.disabled,id:this.inputId,name:this.name,onChange:this.handleSelectChange},(typeof this.options=="string"?JSON.parse(this.options):this.options).map(({label:r,value:a,selected:n})=>d("option",{key:a,value:a,selected:n},r))),d("svg",{key:"51d9fb79381468ee0992475ba376df5a5961116c",class:"searchcraft-select-input-icon",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("title",{key:"59186138953557764915d41708d4bcc23a9bb97f"},"Select dropdown icon"),d("path",{key:"ec2c962df16cb68bdaf3e2c32e57d875a63957a9",d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))),this.caption&&d("p",{key:"742bc2dbd8371938894d49bb37d429d1b7a07d7a",class:"searchcraft-select-caption"},this.caption))}},[0,"searchcraft-select",{caption:[1],disabled:[4],inputId:[1,"input-id"],label:[1],labelId:[1,"label-id"],name:[1],options:[1],customStyles:[1,"custom-styles"],searchResultsPerPage:[32],setSearchResultsPage:[32],setSearchResultsPerPage:[32]}]);function Ba(){if(typeof customElements>"u")return;["searchcraft-select"].forEach(t=>{switch(t){case"searchcraft-select":customElements.get(t)||customElements.define(t,Ri);break}})}const Ei=N(class extends D{constructor(){super();h(this,"increment",20);h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"searchResultsCount");h(this,"searchResultsPagesCount");h(this,"initialSearchResultsPerPage");h(this,"setSearchResultsPerPage",()=>{});h(this,"setSearchResultsPage",()=>{});h(this,"unsubscribe",()=>{});this.__registerHost()}componentDidLoad(){this.unsubscribe=_.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsPage=r.searchResultsPage,this.searchResultsCount=r.searchResultsCount,this.searchResultsPagesCount=Math.ceil(this.searchResultsCount/this.searchResultsPerPage),this.setSearchResultsPage=r.setSearchResultsPage,this.setSearchResultsPerPage=r.setSearchResultsPerPage}),this.initialSearchResultsPerPage=_.getState().searchResultsPerPage}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}render(){if(!(!this.searchTerm||this.searchResultsPagesCount<=1))return d("div",{class:M("searchcraft-search-results-per-page",rt(this.customStyles||{}))},d("div",{class:"searchcraft-search-results-per-page-select"},d("label",{class:"searchcraft-search-results-per-page-select-label",htmlFor:"searchcraft-search-results-per-page-select-input"},"Results Per Page"),d("div",{class:"searchcraft-search-results-per-page-select-input"},d("searchcraft-select",{inputId:"searchcraft-search-results-per-page-select-input",name:"results-per-page",options:[...Array(5)].map((r,a)=>{const n=this.initialSearchResultsPerPage+Number(this.increment)*a;return{label:`${n}`,value:n}}),onSelectChange:r=>{this.setSearchResultsPerPage(Number(r.detail)),this.setSearchResultsPage(1)}}))))}},[0,"searchcraft-search-results-per-page",{increment:[8],customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPage:[32],searchResultsPerPage:[32],searchResultsCount:[32],searchResultsPagesCount:[32],initialSearchResultsPerPage:[32],setSearchResultsPerPage:[32],setSearchResultsPage:[32]}]);function Pi(){if(typeof customElements>"u")return;["searchcraft-search-results-per-page","searchcraft-select"].forEach(t=>{switch(t){case"searchcraft-search-results-per-page":customElements.get(t)||customElements.define(t,Ei);break;case"searchcraft-select":customElements.get(t)||Ba();break}})}const ki=Pi,Ti=Ba,Ci=Da,xi=`:root{--sc-text-base-size: 1em;--sc-text-scale-ratio: 1.1;--sc-font-family: sans-serif;--sc-font-bold: 700;--sc-font-normal: 400;--sc-heading-1-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-2-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-3-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-4-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-5-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-6-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) );--sc-body-font-size: calc(var(--sc-text-base-size));--sc-body-small-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) )}:root{--sc-border-radius: 8px;--sc-border-radius-sm: calc(var(--sc-border-radius) / 2);--sc-border-radius-lg: calc(var(--sc-border-radius) * 2)}:root{--sc-breakpoint-sm: 576px;--sc-breakpoint-md: 768px;--sc-breakpoint-lg: 992px}:root{--sc-surface-neutral-primary: var(--sc-color-background, #ffffff);--sc-color-background-hover: hsl( from var(--sc-color-background) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-primary-hover: var(--sc-color-background-hover, #fafafa);--sc-color-background-active: hsl( from var(--sc-color-background) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-primary-active: var( --sc-color-background-active, #f7f7f7 );--sc-surface-neutral-secondary: var( --sc-color-background-secondary, var(--sc-color-background, #f3f3f3) );--sc-surface-neutral-secondary-hover: var( --sc-color-background-secondary-hover, var(--sc-color-background-hover, #e6e6e6) );--sc-surface-neutral-secondary-active: var( --sc-color-background-secondary-active, var(--sc-color-background-active, #e0e0e0) );--sc-surface-neutral-light: #ffffff;--sc-content-neutral-primary: var(--sc-color-foreground, #292929);--sc-color-foreground-secondary: hsl( from var(--sc-color-foreground) h s clamp(10, calc(l + 5), 90) );--sc-content-neutral-secondary: var(--sc-color-foreground-secondary, #404040);--sc-border-neutral: rgba(0, 0, 0, 0.1);--sc-surface-brand-primary: var(--sc-color-brand, #000000);--sc-color-brand-hover: hsl( from var(--sc-color-brand) h s clamp(20, calc(l + 5), 95) );--sc-surface-brand-primary-hover: var(--sc-color-brand-hover, #2e2e2e);--sc-color-brand-active: hsl( from var(--sc-color-brand) h s clamp(10, calc(l - 5), 85) );--sc-surface-brand-primary-active: var(--sc-color-brand-active, #292929);--sc-surface-brand-secondary: var( --sc-color-brand-secondary, var(--sc-color-brand, #e6e6e6) );--sc-surface-brand-secondary-hover: var( --sc-color-brand-secondary-hover, var(--sc-color-brand-hover, #ebebeb) );--sc-surface-brand-secondary-active: var( --sc-color-brand-secondary-active, var(--sc-color-brand-active, #e0e0e0) );--sc-content-brand: var( --sc-color-brand-text, var(--sc-surface-brand-primary) );--sc-content-brand-on-primary: #ffffff;--sc-border-brand: var(--sc-surface-brand-primary);--sc-surface-success-primary: var(--sc-color-success, #008000);--sc-color-success-primary-hover: hsl(from var(--sc-color-success) h s 30);--sc-surface-success-primary-hover: var( --sc-color-success-primary-hover, #009900 );--sc-color-success-primary-active: hsl(from var(--sc-color-success) h s 20);--sc-surface-success-primary-active: var( --sc-color-success-primary-active, #006600 );--sc-color-success-secondary: hsl(from var(--sc-color-success) h s 90);--sc-surface-success-secondary: var(--sc-color-success-secondary, #ccffcc);--sc-color-success-secondary-hover: hsl( from var(--sc-color-success-secondary) h s 95 );--sc-surface-success-secondary-hover: var( --sc-color-success-secondary-hover, #e6ffe6 );--sc-color-success-secondary-active: hsl( from var(--sc-color-success-secondary) h s 85 );--sc-surface-success-secondary-active: var( --sc-color-success-secondary-active, #b2ffb2 );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30) );--sc-content-success-on-primary: #ffffff;--sc-border-success: var(--sc-surface-success-primary);--sc-surface-caution-primary: var(--sc-color-caution, #cc6600);--sc-color-caution-primary-hover: hsl(from var(--sc-color-caution) h s 30);--sc-surface-caution-primary-hover: var( --sc-color-caution-primary-hover, #e57300 );--sc-color-caution-primary-active: hsl(from var(--sc-color-caution) h s 20);--sc-surface-caution-primary-active: var( --sc-color-caution-primary-active, #b25a00 );--sc-color-caution-secondary: hsl(from var(--sc-color-caution) h s 90);--sc-surface-caution-secondary: var(--sc-color-caution-secondary, #ffd9b3);--sc-color-caution-secondary-hover: hsl( from var(--sc-color-caution-secondary) h s 95 );--sc-surface-caution-secondary-hover: var( --sc-color-caution-secondary-hover, #ffe5cc );--sc-color-caution-secondary-active: hsl( from var(--sc-color-caution-secondary) h s 85 );--sc-surface-caution-secondary-active: var( --sc-color-caution-secondary-active, #ffcc99 );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30) );--sc-content-caution-on-primary: #ffffff;--sc-border-caution: var(--sc-surface-caution-primary);--sc-surface-danger-primary: var(--sc-color-danger, #cc0000);--sc-color-danger-primary-hover: hsl(from var(--sc-color-danger) h s 30);--sc-surface-danger-primary-hover: var( --sc-color-danger-primary-hover, #e50000 );--sc-color-danger-primary-active: hsl(from var(--sc-color-danger) h s 20);--sc-surface-danger-primary-active: var( --sc-color-danger-primary-active, #b30000 );--sc-color-danger-secondary: hsl(from var(--sc-color-danger) h s 90);--sc-surface-danger-secondary: var(--sc-color-danger-secondary, #ffcccc);--sc-color-danger-secondary-hover: hsl( from var(--sc-color-danger-secondary) h s 95 );--sc-surface-danger-secondary-hover: var( --sc-color-danger-secondary-hover, #ffe7e7 );--sc-color-danger-secondary-active: hsl( from var(--sc-color-danger-secondary) h s 85 );--sc-surface-danger-secondary-active: var( --sc-color-danger-secondary-active, #ffb3b3 );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30) );--sc-content-danger-on-primary: #ffffff;--sc-border-danger: var(--sc-surface-danger-primary);--sc-color-disabled: hsl(from var(--sc-color-page-primary) h s calc(l * 0.5));--sc-surface-disabled: var(--sc-color-disabled, #d9d9d9);--sc-color-disabled-text: hsl( from var(--sc-color-text-primary) h s calc(l * 0.5) );--sc-content-disabled: var(--sc-color-disabled-text, #737373);--sc-content-disabled-on-disabled: var(--sc-color-disabled-text, #737373)}@supports(hanging-punctuation: first) and (font: -apple-system-body) and (-webkit-appearance: none){:root{--sc-color-background-hover: hsl( from var(--sc-color-background) h s clamp(10%, calc(l + 5%), 95%) );--sc-color-background-active: hsl( from var(--sc-color-background) h s clamp(5%, calc(l - 5%), 90%) );--sc-color-foreground-secondary: hsl( from var(--sc-color-foreground) h s clamp(10%, calc(l + 5%), 90%) );--sc-color-brand-hover: hsl( from var(--sc-color-brand) h s clamp(20%, calc(l + 5%), 95%) );--sc-color-brand-active: hsl( from var(--sc-color-brand) h s clamp(10%, calc(l - 5%), 85%) );--sc-color-success-primary-hover: hsl(from var(--sc-color-success) h s 30%);--sc-color-success-primary-active: hsl( from var(--sc-color-success) h s 20% );--sc-color-success-secondary: hsl(from var(--sc-color-success) h s 90%);--sc-color-success-secondary-hover: hsl( from var(--sc-color-success-secondary) h s 95% );--sc-color-success-secondary-active: hsl( from var(--sc-color-success-secondary) h s 85% );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30%) );--sc-color-caution-primary-hover: hsl(from var(--sc-color-caution) h s 30%);--sc-color-caution-primary-active: hsl( from var(--sc-color-caution) h s 20% );--sc-color-caution-secondary: hsl(from var(--sc-color-caution) h s 90%);--sc-color-caution-secondary-hover: hsl( from var(--sc-color-caution-secondary) h s 95% );--sc-color-caution-secondary-active: hsl( from var(--sc-color-caution-secondary) h s 85% );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30%) );--sc-color-danger-primary-hover: hsl(from var(--sc-color-danger) h s 30%);--sc-color-danger-primary-active: hsl(from var(--sc-color-danger) h s 20%);--sc-color-danger-secondary: hsl(from var(--sc-color-danger) h s 90%);--sc-color-danger-secondary-hover: hsl( from var(--sc-color-danger-secondary) h s 95% );--sc-color-danger-secondary-active: hsl( from var(--sc-color-danger-secondary) h s 85% );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30%) )}}.searchcraft-custom-ad{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size)}.searchcraft-adm-ad{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);border:1px solid blue}.searchcraft-adm-ad:focus{background-color:var(--sc-surface-neutral-secondary-active);color:var(--sc-content-neutral-secondary)}.searchcraft-adm-ad:hover{background-color:var(--sc-surface-neutral-secondary-hover);color:var(--sc-content-neutral-secondary)}.searchcraft-adm-ad-title{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:inherit}.searchcraft-adm-ad-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);margin:0;color:inherit}.searchcraft-adm-ad-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-adm-ad-image{max-width:var(--sc-popover-list-item-image-size);max-height:var(--sc-popover-list-item-image-size)}.searchcraft-adm-ad-info-wrapper{display:flex;flex-direction:column;gap:8px;justify-content:center}.searchcraft-search-result-container{all:unset;align-items:flex-start;border-radius:var(--sc-border-radius-lg);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:calc(--sc-border-radius-lg - 8px);border-radius:calc(var(--sc-border-radius-lg) - 8px);width:100%}@media(min-width: 768px){.searchcraft-search-result-image{width:200px}}.searchcraft-base-search-result-title{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin:0}.searchcraft-base-search-result-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-disabled);margin:0}.searchcraft-base-search-result-body-content{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-neutral-secondary);margin:0}.searchcraft-base-search-result-footer-content{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-disabled);margin:0}.searchcraft-search-results-container{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-results-empty-state-container{text-align:center}.searchcraft-search-results-error-message-container{text-align:center}.searchcraft-button{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);background:none;border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;gap:4px;padding:12px;position:relative}.searchcraft-button.searchcraft-button-disabled{cursor:not-allowed}.searchcraft-button-primary{background-color:var(--sc-surface-brand-primary);color:var(--sc-content-brand-on-primary);font-weight:var(--sc-font-bold)}.searchcraft-button-primary:hover{background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button-primary:focus{border-color:var(--sc-border-primary)}.searchcraft-button-primary:active{background-color:var(--sc-surface-brand-primary-active)}.searchcraft-button-primary.searchcraft-button-disabled,.searchcraft-button-primary.searchcraft-button-disabled:hover,.searchcraft-button-primary.searchcraft-button-disabled:focus,.searchcraft-button-primary.searchcraft-button-disabled:active{background-color:var(--sc-surface-disabled);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-tertiary{background-color:var(--sc-surface-neutral-primary);color:var(--sc-content-brand);font-weight:var(--sc-font-normal)}.searchcraft-button-tertiary:hover{background-color:var(--sc-surface-brand-secondary-hover)}.searchcraft-button-tertiary:focus{background-color:var(--sc-surface-neutral-light);border-color:var(--sc-border-primary)}.searchcraft-button-tertiary:active{background-color:var(--sc-surface-brand-secondary-active)}.searchcraft-button-tertiary.searchcraft-button-disabled,.searchcraft-button-tertiary.searchcraft-button-disabled:hover,.searchcraft-button-tertiary.searchcraft-button-disabled:focus,.searchcraft-button-tertiary.searchcraft-button-disabled:active{background-color:var(--sc-surface-neutral-light);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-error-message{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-danger);margin:0}.filtersListContainer{width:100%}.filterCheckboxLabel{align-items:center;color:var(--sc-content-brand);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-neutral-secondary);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-neutral-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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-disabled);text-align:center}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-bold)}:root{--sc-input-border-radius: var(--sc-border-radius);--sc-input-search-icon-size: 20px;--sc-input-clear-icon-size: 20px;--sc-input-padding-left: 44px;--sc-input-padding-right: 44px}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);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);color:var(--sc-content-neutral-secondary)}.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);color:var(--sc-content-brand)}.searchcraft-input-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin-top:4px;margin-bottom:4px}:root{--sc-popover-form-border-radius: var(--sc-border-radius);--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}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);border-radius:calc(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);border:0;outline:0;padding:0;flex-shrink:0;background:none;cursor:pointer;padding-left:12px;padding-right:12px}.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:rgba(0,0,0,0)}}.searchcraft-popover-form-modal .searchcraft-input{border-radius:calc(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);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,.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(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);outline-width:1px;outline-color:var(--sc-border-neutral)}.searchcraft-popover-form-fullscreen searchcraft-popover-list-view{overflow:scroll}.searchcraft-popover-list-item{all:unset;color:var(--sc-content-neutral-secondary);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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:inherit}.searchcraft-popover-list-item-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);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}.searchcraft-results-info{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-primary);margin:0}.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:rgba(0,0,0,0);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}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-toggle-button-background{transition:background-color .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,.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 .3s ease;width:18px}.searchcraft-toggle-button-handle.active{transform:translateX(16px)}.searchcraft-pagination{display:inline-grid;gap:16px;grid-template-columns:repeat(3, auto);grid-template-rows:1fr}.searchcraft-pagination-list{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius);display:flex;list-style-type:none;margin:0;overflow:hidden;padding:0;width:auto}.searchcraft-pagination-list li{border-right:1px solid var(--sc-border-neutral);height:100%;min-height:44px;width:44px}.searchcraft-pagination-list li:last-child{border-right:none}.searchcraft-pagination-item{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);align-items:center;background-color:var(--sc-surface-neutral-primary);border:none;display:flex;height:100%;justify-content:center;width:100%}.searchcraft-pagination-item-active{background-color:var(--sc-surface-brand-secondary);font-weight:var(--sc-font-bold)}.searchcraft-pagination-control{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius)}.searchcraft-pagination-range{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);align-items:center;display:flex}.searchcraft-select{display:flex;flex-direction:column;gap:4px}.searchcraft-select-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-bold)}.searchcraft-select-input-wrapper{position:relative}.searchcraft-select-input{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);appearance:none;background-color:var(--sc-surface-neutral-secondary);border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;height:44px;padding:0 44px 0 16px;width:100%}.searchcraft-select-input:hover{background-color:var(--sc-surface-neutral-secondary-hover)}.searchcraft-select-input:active{background-color:var(--sc-surface-neutral-secondary-active)}.searchcraft-select-input:focus{border-color:var(--sc-border-brand);outline:none}.searchcraft-select-input-icon{pointer-events:none;position:absolute;right:12px;top:50%;transform:translateY(-50%)}.searchcraft-select-caption{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size)}.searchcraft-search-results-per-page{display:flex}.searchcraft-search-results-per-page-select{align-items:center;display:flex;gap:12px}.searchcraft-search-results-per-page-select-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size)}.searchcraft-search-results-per-page-select-input{min-width:120px}/*# sourceMappingURL=hologram.css.map */
35
- `,$i=N(class extends D{constructor(){super();h(this,"theme");h(this,"customTheme");h(this,"camelToKebab",r=>r.replace(/[A-Z]/g,a=>`-${a.toLowerCase()}`).toLowerCase());this.__registerHost()}componentDidLoad(){const r=document.querySelector("#searchcraft-theme")||document.createElement("style");r.innerHTML=xi,r.id="searchcraft-theme";const a=document.head||document.getElementsByTagName("head")[0];a.contains(r)||(a.firstChild?a.insertBefore(r,a.firstChild):a.appendChild(r)),document.body.dataset.theme=this.theme||"light",Object.entries(JSON.parse(this.customTheme||"[]")).map(([n,o])=>{document.documentElement.style.setProperty(`--${this.camelToKebab(n)}`,`${o}`)})}render(){}},[0,"searchcraft-theme",{theme:[1],customTheme:[1,"custom-theme"]}]);function _i(){if(typeof customElements>"u")return;["searchcraft-theme"].forEach(t=>{switch(t){case"searchcraft-theme":customElements.get(t)||customElements.define(t,$i);break}})}const Ai=_i,Ii=Na,ja=()=>{Lo(),Do(),Bo(),Go(),Wo(),Qo(),ri(),ni(),oi(),li(),fi(),gi(),bi(),vi(),wi(),ki(),Ti(),Ci(),Ai(),Ii()};ja();const Ga={name:"@searchcraft/vue-sdk",version:"0.9.4",private:!1,description:"Searchcraft Vue SDK.",type:"module",license:"Apache-2.0",keywords:["searchcraft"],scripts:{dev:"vite",clean:"rm -rf dist",build:"yarn clean && vite build && yarn docs",docs:"typedoc --options typedoc.json",preview:"vite preview","build-only":"vite build","type-check":"vue-tsc --build"},repository:{type:"git",url:"https://bitbucket.org/madebychalk/searchcraft-javascript-sdks/"},engines:{node:">=18.0.0",npm:">=10.0.0"},main:"./dist/index.umd.js",module:"./dist/index.es.js",types:"./dist/index.d.ts",exports:{".":{types:"./dist/index.d.ts",import:"./dist/index.es.js",require:"./dist/index.umd.js"},"./components":"./dist/components/index.d.ts","./plugin":"./dist/plugin.d.ts"},files:["dist"],peerDependencies:{vue:"^3.5.13"},devDependencies:{"@searchcraft/core":"^0.9.4","@searchcraft/javascript-sdk":"^0.9.4","@tsconfig/node22":"^22.0.0","@types/node":"^22.10.7","@vitejs/plugin-vue":"^5.2.1","@vitejs/plugin-vue-jsx":"^4.1.1","@vue/runtime-dom":"^3.5.13","@vue/tsconfig":"^0.7.0","npm-run-all2":"^7.0.2",vite:"^6.0.11","vite-plugin-dts":"^4.5.0","vite-plugin-vue-devtools":"^7.7.0","vue-docgen-web-types":"^0.1.8","vue-tsc":"^2.2.0"}},hr="routerLink",Wa="navManager",Mi="router",Li="aria",at=Symbol(),Va={default:at},qa=e=>(e==null?void 0:e.split(" "))||[],Oi=(e,t,r=[])=>{var a;return[...Array.from(((a=e.value)==null?void 0:a.classList)||[]),...r].filter((n,o,s)=>!t.has(n)&&s.indexOf(n)===o)},we=(e,t,r=[],a=[],n,o)=>{t!==void 0&&t();const s=G.defineComponent((c,{attrs:u,slots:l,emit:i})=>{var K;const p=G.ref(),g=new Set(qa(u.class)),S=G.getCurrentInstance(),U=((K=S==null?void 0:S.appContext)==null?void 0:K.provides[Wa])?G.inject(Wa):void 0,pe=$=>{const{routerLink:Re}=c;if(Re!==at)if(U!==void 0){$.preventDefault();let ce={event:$};for(const Le in c){const z=c[Le];c.hasOwnProperty(Le)&&Le.startsWith(Mi)&&z!==at&&(ce[Le]=z)}U.navigate(ce)}else console.warn("Tried to navigate, but no router was found. Make sure you have mounted Vue Router.")};return()=>{c[n],qa(u.class).forEach(z=>{g.add(z)});const $=c.onClick,Re=z=>{$!==void 0&&$(z),z.defaultPrevented||pe(z)};let ce={ref:p,class:Oi(p,g),onClick:Re};for(const z in c){const ne=c[z];(c.hasOwnProperty(z)&&ne!==at||z.startsWith(Li))&&(ce[z]=ne);const H="on"+z.slice(0,1).toUpperCase()+z.slice(1),Oe=u[H];p.value&&u.hasOwnProperty(H)&&"addEventListener"in p.value&&p.value.addEventListener(z,Oe)}return hr in c&&c[hr]!==at&&(ce={...ce,href:c[hr]}),G.h(e,ce,l.default&&l.default())}});if(typeof s!="function"){let c=[],u={};u.ROUTER_LINK_VALUE=Va,r.forEach(l=>u[l]=Va),c=a,s.name=e,s.emits=c,s.props=u}return s},Fi=we("searchcraft-base-search-results",()=>{},["customStylesForResults","searchResultMappings","resultImagePlacement","buttonLabel","buttonTarget","buttonRel","containerTarget","containerRel"]),Di=we("searchcraft-filter-panel",()=>{},["items"]),Ni=we("searchcraft-input-form",()=>{},["autoSearch","buttonPlacement","buttonLabel","inputLabel","customStyles","placeholderValue","searchTerm","core","inputFocus","inputBlur","inputInit"],["inputFocus","inputBlur","inputInit"]),Ui=we("searchcraft-pagination",()=>{},["customStyles"]),zi=we("searchcraft-popover-button",()=>{}),Hi=we("searchcraft-popover-form",()=>{},["type","popoverResultMappings","hotkey","hotkeyModifier"]),Bi=we("searchcraft-results-info",()=>{},["customFormatter","customStyles"]),ji=we("searchcraft-search-results-per-page",()=>{},["increment","customStyles"]),Gi=we("searchcraft-theme",()=>{},["theme","customTheme"]),Wi=Fi,Vi=Di,qi=Ni,Yi=zi,Ki=Hi,Xi=Bi,Qi=Gi,Ji=Ui,Zi=ji;class ec extends sn{constructor(t){super(t,{sdkName:Ga.name,sdkVersion:Ga.version})}}ja(),L.Searchcraft=ec,L.SearchcraftBaseSearchResults=Wi,L.SearchcraftFilterPanel=Vi,L.SearchcraftInputForm=qi,L.SearchcraftPagination=Ji,L.SearchcraftPopoverButton=Yi,L.SearchcraftPopoverForm=Ki,L.SearchcraftResultsInfo=Xi,L.SearchcraftSearchResultsPerPage=Zi,L.SearchcraftTheme=Qi,Object.defineProperty(L,Symbol.toStringTag,{value:"Module"})});
34
+ */(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var o="",a=0;a<arguments.length;a++){var c=arguments[a];c&&(o=n(o,s(c)))}return o}function s(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return r.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var a="";for(var c in o)t.call(o,c)&&o[c]&&(a=n(a,c));return a}function n(o,a){return a?o?o+" "+a:o+a:o}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(Is);const L=Is.exports,Wo=U(class extends N{constructor(){super();h(this,"hierarchy","primary");h(this,"disabled",!1);h(this,"icon");h(this,"iconOnly",!1);h(this,"iconPosition","left");h(this,"label","Search");h(this,"type","button");h(this,"buttonClick");h(this,"handleButtonClick",()=>{this.buttonClick.emit()});this.__registerHost(),this.buttonClick=Te(this,"buttonClick")}render(){return f("button",{key:"ff883b930d03da6cbfb40badd3be1de0a873f853","aria-label":this.label,class:L("searchcraft-button",{"searchcraft-button-primary":this.hierarchy==="primary","searchcraft-button-tertiary":this.hierarchy==="tertiary","searchcraft-button-disabled":this.disabled}),disabled:this.disabled,onClick:this.handleButtonClick,type:this.type},this.iconOnly?this.icon:f(Jt,null,this.iconPosition==="left"&&this.icon,f("span",null,this.label),this.iconPosition==="right"&&this.icon))}},[0,"searchcraft-button",{hierarchy:[1],disabled:[4],icon:[16],iconOnly:[4,"icon-only"],iconPosition:[1,"icon-position"],label:[1],type:[1]}]);function xt(){if(typeof customElements>"u")return;["searchcraft-button"].forEach(t=>{switch(t){case"searchcraft-button":customElements.get(t)||customElements.define(t,Wo);break}})}const Go=xt,qo=Tt;function Ms(e,t){const r={...e};for(const s in t)t.hasOwnProperty(s)&&(t[s]instanceof Object&&e[s]instanceof Object?r[s]=Ms(e[s],t[s]):r[s]=t[s]);return r}function Yo(e){return e.filter((t,r,s)=>!s.some((n,o)=>o!==r&&n.includes(t)))}function Ls(e){const t={},r=s=>{var n;t[s.path]={count:s.count,path:s.path},(n=s.children)==null||n.forEach(o=>{r(o)})};return r(e),t}function Qo(e){const t={count:0,path:"/",children:{}};return Object.keys(e).forEach(r=>{const s=e[r];if(!s||s.path==="/")return;const n=s.path.substring(1).split("/");let o=t,a="";n.forEach((c,u)=>{const l=`${a}/${c}`;o.children[l]||(o.children[l]={count:0,path:l,children:{}}),u===n.length-1&&(o.children[l].count=s.count),a=l,o=o.children[l]})}),t}function Os(e){const t={count:e.count,path:e.path,children:[]};return Object.keys(e.children).length>0&&(t.children=Object.values(e.children).map(r=>Os(r))),t}function Ko(e,t){const r=Object.keys(e),s=Object.keys(t),n=new Set(s.filter(a=>a.split("/").length>2).map(a=>a.substring(0,a.lastIndexOf("/"))));return Object.fromEntries(r.filter(a=>!n.has(a.substring(0,a.lastIndexOf("/")))).map(a=>[a,e[a]]))}function Xo(e,t,r){const s=t[e],n=r[e],o={count:0,path:"/",children:s},a={count:0,path:"/",children:n},c=Ls(o),u=Ls(a),l=Ko(c,u),i=Ms(l,u),p=Qo(i),m=Os(p);return{[e]:m.children}}const Jo=U(class extends N{constructor(){super();h(this,"fieldName","");h(this,"facetSelectionUpdated");h(this,"baseFacetRoot");h(this,"facetRoot");h(this,"selectedPaths",{});h(this,"lastTimeTaken");h(this,"hasNewSearchTerm",!1);h(this,"lastSearchTerm");h(this,"lastSearchMode");h(this,"lastSortType");h(this,"unsubscribe");h(this,"searchStore",A.getState());h(this,"formatLabel",r=>{const s=r.path.replace(/^\//,""),n=r.count;return`${s.replace(/-/g," ").replace(/\b\w/g,o=>o.toUpperCase())} (${n})`});h(this,"formatSubLabel",(r,s)=>{const o=r.path.substring(s.path.length).replace(/^\//,""),a=r.count;return`${o.replace(/-/g," ").replace(/\b\w/g,c=>c.toUpperCase())} (${a})`});this.__registerHost(),this.facetSelectionUpdated=Te(this,"facetSelectionUpdated")}handleStateUpdate(r){const s=r.searchResponseFacetPrime,n=r.searchResponseTimeTaken;if(this.fieldName){if((r.searchTerm!==this.lastSearchTerm||r.searchMode!==this.lastSearchMode||r.sortType!==this.lastSortType)&&(this.selectedPaths={},this.hasNewSearchTerm=!0),n!==this.lastTimeTaken&&s){this.facetRoot=void 0;const o=s.find(a=>this.fieldName===Object.keys(a)[0]);this.hasNewSearchTerm?(this.baseFacetRoot=o,this.facetRoot=o,this.hasNewSearchTerm=!1):this.baseFacetRoot&&o&&(this.facetRoot=Xo(this.fieldName,this.baseFacetRoot,o))}this.lastSearchTerm=r.searchTerm,this.lastSearchMode=r.searchMode,this.lastSortType=r.sortType,this.lastTimeTaken=n}}connectedCallback(){this.handleStateUpdate(this.searchStore),this.unsubscribe=A.subscribe(r=>{this.handleStateUpdate(r)})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleCheckboxChange(r){var a;if(!this.selectedPaths[r])this.selectedPaths={...this.selectedPaths,[r]:!0};else{const c=Object.keys(this.selectedPaths).filter(u=>!u.includes(r));this.selectedPaths=c.reduce((u,l)=>(u[l]=!0,u),{})}const n=Object.keys(this.selectedPaths).filter(c=>this.selectedPaths[c]),o=Yo(n);(a=this.facetSelectionUpdated)==null||a.emit({paths:o})}render(){var s;if(!this.fieldName)return;const r=(s=this.facetRoot)==null?void 0:s[this.fieldName];return f("div",{class:L("filtersListContainer","searchcraft-filters-list-container")},!r&&f("p",{class:"searchcraft-facet-message"},"Enter a search to view facets."),r==null?void 0:r.map(n=>{var a;const o=n.children?(a=n.children)==null?void 0:a.some(c=>this.selectedPaths[c.path]):!1;return f("div",{key:n.path,class:L("searchcraft-filters-list-item")},f("label",{class:L("filterCheckboxLabel","searchcraft-filters-list-checkbox-label")},f("input",{checked:this.selectedPaths[n.path],onChange:c=>this.handleCheckboxChange(n.path),type:"checkbox"}),o?f("div",{class:L("dashContainer","searchcraft-filter-list-dash-container")},f("svg",{width:"14",height:"3",viewBox:"0 0 14 3",fill:"none"},f("title",null,"Checkbox Dash"),f("line",{x1:"1.5",y1:"1.5",x2:"12.5",y2:"1.5",stroke:"white","stroke-width":"3","stroke-linecap":"round"}))):f("div",{class:L("checkContainer","searchcraft-filter-list-check-container")},f("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},f("title",null,"Checkbox Check"),f("path",{d:"M13.9999 2L5.74988 10L1.99988 6.36364",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"}))),this.formatLabel(n)),n.children&&n.children.length>0&&f(Jt,null,n.children.map(c=>f("label",{key:c.path,class:L("childFilterCheckboxLabel","searchcraft-child-filter-checkbox-label"),style:{display:this.selectedPaths[n.path]?"flex":"none"}},f("input",{checked:this.selectedPaths[c.path],onChange:u=>{this.handleCheckboxChange(c.path)},type:"checkbox"}),f("div",{class:L("checkContainer","searchcraft-filter-list-check-container")},f("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},f("title",null,"Checkbox Check"),f("path",{d:"M13.9999 2L5.74988 10L1.99988 6.36364",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"}))),this.formatSubLabel(c,n)))))}))}},[0,"searchcraft-facet-list",{fieldName:[1,"field-name"],baseFacetRoot:[32],facetRoot:[32],selectedPaths:[32],lastTimeTaken:[32],hasNewSearchTerm:[32],lastSearchTerm:[32],lastSearchMode:[32],lastSortType:[32],unsubscribe:[32]}]);function Fs(){if(typeof customElements>"u")return;["searchcraft-facet-list"].forEach(t=>{switch(t){case"searchcraft-facet-list":customElements.get(t)||customElements.define(t,Jo);break}})}const Zo=Fs,ei=U(class extends N{constructor(){super();h(this,"max",100);h(this,"min",0);h(this,"granularity",_s("month"));h(this,"dataType","number");h(this,"endValue",this.max);h(this,"startValue",this.min);h(this,"lastFocusedHandle","max");h(this,"rangeChanged");h(this,"emitUpdate",async()=>{var r;(r=this.rangeChanged)==null||r.emit({startValue:this.startValue,endValue:this.endValue})});h(this,"handleStartValueChange",r=>{const s=r.target,n=Number.parseInt(s.value,10);this.lastFocusedHandle="min",n<=this.endValue?(this.startValue=n,this.emitUpdate()):(this.startValue=this.endValue,s.value=`${this.endValue}`)});h(this,"handleEndValueChange",r=>{const s=r.target,n=Number.parseInt(s.value,10);this.lastFocusedHandle="max",n>=this.startValue?(this.endValue=n,this.emitUpdate()):(this.endValue=this.startValue,s.value=`${this.startValue}`)});this.__registerHost(),this.rangeChanged=Te(this,"rangeChanged")}componentDidLoad(){this.startValue=this.min,this.endValue=this.max}render(){const r=this.min,s=this.max,n=(this.startValue-r)/(s-r)*100,o=(this.endValue-r)/(s-r)*100,a=this.dataType==="number"?this.startValue:new Date(this.startValue).getFullYear(),c=this.dataType==="number"?this.endValue:new Date(this.endValue).getFullYear();return f("div",{key:"ec4a36e1ce6534b7c077114086d759e0b1e7a24e",class:"searchcraft-slider-container"},f("div",{key:"35487cbeaeeb23052631804704645ca929340f70",class:"searchcraft-slider-range-container"},f("div",{key:"186e699def8e7a6e58e8ad5f04953ac1c6584344",class:"searchcraft-slider-active-range",style:{left:`${n}%`,width:`${o-n}%`}}),f("input",{key:"97638e2a1471888c2be47f7526e9dd98fea58683",class:L("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}),f("input",{key:"db2abded80b606d17bde1677e4acc09a85e6e20e",class:L("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})),f("div",{key:"83954b6955a872a17377d506d2d8458059acac03",class:"searchcraft-slider-label-container"},f("span",{key:"b5315b4438385ecf5df3f76579fdf102b6a8c39c",class:"searchcraft-slider-label"},a),f("span",{key:"875094ac7ee69e04c3a16407388dd27f167b3c8f",class:"searchcraft-slider-label"},c)))}},[0,"searchcraft-slider",{max:[2],min:[2],granularity:[2],dataType:[1,"data-type"],endValue:[32],startValue:[32],lastFocusedHandle:[32]}]);function Ds(){if(typeof customElements>"u")return;["searchcraft-slider"].forEach(t=>{switch(t){case"searchcraft-slider":customElements.get(t)||customElements.define(t,ei);break}})}const ti=U(class extends N{constructor(){super();h(this,"label","Toggle");h(this,"subLabel");h(this,"toggleUpdated");h(this,"isActive",!1);h(this,"unsubscribe");h(this,"lastSearchTerm");h(this,"handleToggle",async()=>{var r;this.isActive=!this.isActive,(r=this.toggleUpdated)==null||r.emit(this.isActive)});this.__registerHost(),this.toggleUpdated=Te(this,"toggleUpdated")}connectedCallback(){this.unsubscribe=A.subscribe(r=>{r.searchTerm!==this.lastSearchTerm&&r.searchTerm.trim().length===0&&(this.isActive=!1),this.lastSearchTerm=r.searchTerm})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}render(){return f("div",{key:"25f3acd2b5dd6837182c8f07c092c54c35542c2f",class:"searchcraft-toggle-button-container"},f("div",{key:"d2951f2673af55159ad6f39d381d272a3f9f872b"},f("p",{key:"2468e261d46b454ce896b614ca2a076d27a31a8b",class:"searchcraft-toggle-button-label"},this.label),this.subLabel&&f("p",{key:"1d9887dc12f30fb1982cf0d8a692ebfeca8edc1a",class:"searchcraft-toggle-button-sub-label"},this.subLabel)),f("button",{key:"f51bb553d6b210233aa6ebfc4318aa521036d922",class:L("searchcraft-toggle-button-background",{active:this.isActive}),onClick:this.handleToggle,type:"button"},f("div",{key:"a34339f1bb5ab4742d897b01b61fe6c8c23e7e1e",class:L("searchcraft-toggle-button-handle",{active:this.isActive})})))}},[0,"searchcraft-toggle-button",{label:[1],subLabel:[1,"sub-label"],isActive:[32],unsubscribe:[32],lastSearchTerm:[32]}]);function Ns(){if(typeof customElements>"u")return;["searchcraft-toggle-button"].forEach(t=>{switch(t){case"searchcraft-toggle-button":customElements.get(t)||customElements.define(t,ti);break}})}const ri=U(class extends N{constructor(){super();h(this,"items",[]);h(this,"unsubscribe");h(this,"lastSearchTerm");h(this,"searchStore",A.getState());this.__registerHost()}componentDidLoad(){this.unsubscribe=A.subscribe(r=>{this.lastSearchTerm=r.searchTerm||""})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleDateRangeChanged(r,s,n){const o=new Date(new Date(s).getFullYear(),0,1),a=new Date(new Date(n).getFullYear()+1,0,0);this.searchStore.addRangeValueForIndexField({fieldName:r,value:`${r}:[${o.toISOString()} TO ${a.toISOString()}]`}),this.searchStore.search()}handleNumericRangeChanged(r,s,n){this.searchStore.addRangeValueForIndexField({fieldName:r,value:`${r}:[${s} TO ${n}]`}),this.searchStore.search()}handleFacetSelectionUpdated(r,s){s.length>0?this.searchStore.addFacetPathsForIndexField({fieldName:r,value:`${r}: IN [${s.join(" ")}]`}):this.searchStore.removeFacetPathsForIndexField(r),this.searchStore.search()}handleExactMatchToggleUpdated(r){this.searchStore.setSearchMode(r?"exact":"fuzzy"),this.searchStore.search()}handleMostRecentToggleUpdated(r){this.searchStore.setSortType(r?"desc":"asc"),this.searchStore.search()}render(){return f("div",{key:"73ca2e0efab911c5095c23ba33e85a26cc440b4a",class:"searchcraft-filter-panel"},this.items.map(r=>{switch(r.type){case"dateRange":{const s=r,n=new Date(s.options.minDate).getTime(),o=new Date(s.options.maxDate).getTime(),a=_s(s.options.granularity);return f("div",{class:"searchcraft-filter-panel-section"},f("p",{class:"searchcraft-filter-panel-label"},r.label),f("searchcraft-slider",{min:n,max:o,granularity:a,dataType:"date",onRangeChanged:c=>{this.handleDateRangeChanged(s.fieldName,c.detail.startValue,c.detail.endValue)}}))}case"numericRange":{const s=r;return f("div",{class:"searchcraft-filter-panel-section"},f("p",{class:"searchcraft-filter-panel-label"},r.label),f("searchcraft-slider",{min:s.options.min,max:s.options.max,granularity:s.options.granularity,onRangeChanged:n=>{this.handleNumericRangeChanged(s.fieldName,n.detail.startValue,n.detail.endValue)}}))}case"facets":{const s=r;return f("div",{class:"searchcraft-filter-panel-section"},f("p",{class:"searchcraft-filter-panel-label"},r.label),f("searchcraft-facet-list",{fieldName:s.fieldName,onFacetSelectionUpdated:n=>{this.handleFacetSelectionUpdated(s.fieldName,n.detail.paths)}}))}case"exactMatchToggle":{const s=r;return f("searchcraft-toggle-button",{label:s.label,subLabel:s.options.subLabel,onToggleUpdated:n=>{this.handleExactMatchToggleUpdated(n.detail)}})}case"mostRecentToggle":{const s=r;return f("searchcraft-toggle-button",{label:s.label,subLabel:s.options.subLabel,onToggleUpdated:n=>{this.handleMostRecentToggleUpdated(n.detail)}})}}}))}},[0,"searchcraft-filter-panel",{items:[16],unsubscribe:[32],lastSearchTerm:[32]}]);function si(){if(typeof customElements>"u")return;["searchcraft-filter-panel","searchcraft-facet-list","searchcraft-slider","searchcraft-toggle-button"].forEach(t=>{switch(t){case"searchcraft-filter-panel":customElements.get(t)||customElements.define(t,ri);break;case"searchcraft-facet-list":customElements.get(t)||Fs();break;case"searchcraft-slider":customElements.get(t)||Ds();break;case"searchcraft-toggle-button":customElements.get(t)||Ns();break}})}const ai=si,ni=U(class extends N{constructor(){super();h(this,"inputLabelClassName","");h(this,"label","");this.__registerHost()}render(){return f("label",{key:"528396d4be9f22ff0c02d95d8bcea056576aed41",class:L("searchcraft-input-label",this.inputLabelClassName),htmlFor:"searchcraft-input-id"},this.label)}},[0,"searchcraft-input-label",{inputLabelClassName:[1,"input-label-class-name"],label:[1]}]);function lr(){if(typeof customElements>"u")return;["searchcraft-input-label"].forEach(t=>{switch(t){case"searchcraft-input-label":customElements.get(t)||customElements.define(t,ni);break}})}const oi=U(class extends N{constructor(){super();h(this,"autoSearch",!0);h(this,"buttonPlacement","none");h(this,"buttonLabel");h(this,"inputLabel");h(this,"customStyles",{});h(this,"placeholderValue","Enter Search");h(this,"inputFocus");h(this,"inputBlur");h(this,"inputInit");h(this,"inputValue","");h(this,"searchTerm","");h(this,"error",!1);h(this,"core");h(this,"searchStore",A.getState());h(this,"handleOnInput",r=>{const s=r.target;this.inputValue=s.value,this.autoSearch&&this.performSearch(s.value)});h(this,"performSearch",async r=>{if(r!==A.getState().searchTerm){this.searchTerm=r.trim(),this.error=!1,this.searchStore.setSearchTerm(this.searchTerm);try{await this.searchStore.search()}catch(s){console.log(s),this.error=!0}}});h(this,"handleClearInput",()=>{this.inputValue="",this.searchTerm="",this.searchStore.setSearchTerm(""),this.searchStore.setSearchClientResponseItems([]),this.error=!1});h(this,"handleFormSubmit",async r=>{r.preventDefault(),await this.performSearch(this.searchTerm)});this.__registerHost(),this.inputFocus=Te(this,"inputFocus"),this.inputBlur=Te(this,"inputBlur"),this.inputInit=Te(this,"inputInit")}init(){var r;this.core&&(this.searchStore.initialize(this.core),(r=this.inputInit)==null||r.emit())}connectedCallback(){this.init()}onCoreChange(){this.init()}render(){const r=rt(this.customStyles),s=this.inputValue.length>0,n=L("searchcraft-input-grid",{"searchcraft-input-grid-buttonLeft":this.buttonPlacement==="left","searchcraft-input-grid-buttonRight":this.buttonPlacement==="right","searchcraft-input-grid-buttonNone":this.buttonPlacement==="none"}),a={gap:this.inputLabel||this.error?"4px 8px":"0px 8px"};return f("form",{key:"f08b30d8688e110230c99dbdc0b08aaa259680d1",class:"searchcraft-input-form",onSubmit:this.handleFormSubmit},f("div",{key:"32e8cbea58acd0d1e8b14a3ca7363f648df052f1",class:n,style:a},f("div",{key:"769484880d0228a5b865fad2c83e6537ae55686a",class:"searchcraft-input-button-wrapper"},f("searchcraft-button",{key:"75902602813c266d77c038d106f5a033ff64c477",onButtonClick:this.handleFormSubmit,label:this.buttonLabel})),this.inputLabel&&f("div",{key:"356356b1eac93b52f8622c9c2f414fe76b70e0fe",class:"searchcraft-input-label-wrapper"},f("searchcraft-input-label",{key:"4c5a680712b8d26a6326dde48223317b690e7a30",label:this.inputLabel})),this.error&&f("div",{key:"e2275fe0907d60e13ac3cb6b2a23e0872c475eb3",class:"searchcraft-input-error-wrapper"},f("searchcraft-error-message",{key:"26e7ffbe8fe43f3f5340176e68cf7763d71c4eab",errorMessage:"Something went wrong."})),f("div",{key:"cfc0d53d4ec644fd453fe39b3091986d9abf2b49",class:"searchcraft-input-wrapper"},f("input",{key:"44dcf30e32dcf4de2aeb5c64d445db468fde605b",autoComplete:"off",class:"searchcraft-input",onFocus:()=>{var c;return(c=this.inputFocus)==null?void 0:c.emit()},onBlur:()=>{var c;return(c=this.inputBlur)==null?void 0:c.emit()},onInput:c=>{this.handleOnInput(c)},placeholder:this.placeholderValue,style:r,type:"text",value:this.inputValue}),f("div",{key:"a510ee45c5c1fcd8991220dcaed42bdbcef39b49",class:"searchcraft-input-search-icon-wrapper"},f("svg",{key:"5dc9bc129a7f550f400aa23b09b38df7aa412821",class:"searchcraft-input-search-icon",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"searchcraft-title"},f("title",{key:"af9c2cb95db7d1f182d4312bccefa97ac95e06aa",id:"searchcraft-title"},"Searchcraft Search Icon Light"),f("path",{key:"c2e8b250f1113670cb2435664a57725563d34efd",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:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))),s&&f("button",{key:"0630c1533ab1c9654e9e984a1194759dec2ab535",type:"button",class:"searchcraft-input-clear-button",onClick:this.handleClearInput},f("svg",{key:"052abaa409746a98ee94e09e87e5345c05687dba",class:"searchcraft-input-clear-icon",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":"icon-title"},f("title",{key:"795d7435b5cac2069063a6e6bf40868ddba76516",id:"icon-title"},"Searchcraft Clear Input Icon Light"),f("path",{key:"29be529ce60d62136bde73baa2600f3664479c7f",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:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))))))}static get watchers(){return{core:["onCoreChange"]}}},[0,"searchcraft-input-form",{autoSearch:[4,"auto-search"],buttonPlacement:[1,"button-placement"],buttonLabel:[1,"button-label"],inputLabel:[1,"input-label"],customStyles:[1,"custom-styles"],placeholderValue:[1,"placeholder-value"],core:[16],inputValue:[32],searchTerm:[32],error:[32]},void 0,{core:["onCoreChange"]}]);function Us(){if(typeof customElements>"u")return;["searchcraft-input-form","searchcraft-button","searchcraft-error-message","searchcraft-input-label"].forEach(t=>{switch(t){case"searchcraft-input-form":customElements.get(t)||customElements.define(t,oi);break;case"searchcraft-button":customElements.get(t)||xt();break;case"searchcraft-error-message":customElements.get(t)||Tt();break;case"searchcraft-input-label":customElements.get(t)||lr();break}})}const ii=Us,ci=lr,li=U(class extends N{constructor(){super();h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPerPage");h(this,"searchResultsPage");h(this,"searchResultsCount");h(this,"searchResultsPagesCount",1);h(this,"searchResultsRangeMin",1);h(this,"searchResultsRangeMax",1);h(this,"setSearchResultsPage",()=>{});h(this,"unsubscribe",()=>{});this.__registerHost()}componentDidLoad(){this.unsubscribe=A.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsPage=r.searchResultsPage,this.searchResultsCount=r.searchResultsCount,this.searchResultsPagesCount=Math.ceil(this.searchResultsCount/this.searchResultsPerPage),this.searchResultsRangeMin=(this.searchResultsPage-1)*this.searchResultsPerPage+1,this.searchResultsRangeMax=(this.searchResultsPerPage-1)*this.searchResultsPerPage+this.searchResultsPerPage,this.setSearchResultsPage=r.setSearchResultsPage})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}handleGoToPage(r){this.setSearchResultsPage(r)}renderOddPaginationItem(r){return f("li",null,f("button",{class:L("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===r}),onClick:()=>this.handleGoToPage(r),type:"button"},r))}renderEvenPaginationItem(r){if(!(this.searchResultsPagesCount<=r))return(this.searchResultsPagesCount<=5||r<Math.ceil(this.searchResultsPagesCount/2)?this.searchResultsPage<=r+1:this.searchResultsPage>=r-1)?f("li",null,f("button",{class:L("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===r}),onClick:()=>this.handleGoToPage(r),type:"button"},r)):f("li",null,f("span",{class:"searchcraft-pagination-item"},"..."))}renderMiddlePaginationItem(){if(!(this.searchResultsPagesCount<=3))return this.searchResultsPagesCount<=5||this.searchResultsPage<=3||this.searchResultsPage>=this.searchResultsPagesCount-2?f("li",null,f("button",{class:L("searchcraft-pagination-item",{"searchcraft-pagination-item-active":this.searchResultsPage===3||this.searchResultsPage===this.searchResultsPagesCount-2}),type:"button",onClick:()=>this.handleGoToPage(this.searchResultsPage>=this.searchResultsPagesCount-2?this.searchResultsPagesCount-2:3)},this.searchResultsPage>=this.searchResultsPagesCount-2?this.searchResultsPagesCount-2:3)):f("li",null,f("span",{class:"searchcraft-pagination-item searchcraft-pagination-item-active"},this.searchResultsPage))}render(){if(!(!this.searchTerm||this.searchResultsPagesCount<=1))return f("div",{class:L("searchcraft-pagination",rt(this.customStyles||{}))},f("div",{class:"searchcraft-pagination-control"},f("searchcraft-button",{disabled:this.searchResultsPage===1,hierarchy:"tertiary",onButtonClick:()=>this.handleGoToPage(Math.max(1,this.searchResultsPage-1)),label:"Previous",iconPosition:"left",icon:f("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},f("title",null,"Previous page icon"),f("path",{d:"M12.5 15L7.5 10L12.5 5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})),iconOnly:!0})),f("ul",{class:"searchcraft-pagination-list"},this.renderOddPaginationItem(1),this.renderEvenPaginationItem(2),this.renderMiddlePaginationItem(),this.renderEvenPaginationItem(this.searchResultsPagesCount>4?this.searchResultsPagesCount-1:4),this.renderOddPaginationItem(this.searchResultsPagesCount)),f("div",{class:"searchcraft-pagination-control"},f("searchcraft-button",{disabled:this.searchResultsPage===this.searchResultsPagesCount,hierarchy:"tertiary",onButtonClick:()=>{this.handleGoToPage(Math.min(this.searchResultsPagesCount,this.searchResultsPage+1))},label:"Next",iconPosition:"right",icon:f("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},f("title",null,"Next page icon"),f("path",{d:"M7.5 15L12.5 10L7.5 5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})),iconOnly:!0})))}},[0,"searchcraft-pagination",{customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPerPage:[32],searchResultsPage:[32],searchResultsCount:[32],searchResultsPagesCount:[32],searchResultsRangeMin:[32],searchResultsRangeMax:[32],setSearchResultsPage:[32]}]);function ui(){if(typeof customElements>"u")return;["searchcraft-pagination","searchcraft-button"].forEach(t=>{switch(t){case"searchcraft-pagination":customElements.get(t)||customElements.define(t,li);break;case"searchcraft-button":customElements.get(t)||xt();break}})}const hi=ui,di=U(class extends N{constructor(){super(),this.__registerHost()}handleOnClick(){A.getState().setPopoverVisibility(!0)}render(){return f("button",{key:"a8ee70b49a5309cfb1363a272ea0870c48c59688",type:"button",onClick:this.handleOnClick.bind(this)},f("slot",{key:"9ac712ed1f6e69d73e7ade3d42501fb67a02c7ff"}))}},[4,"searchcraft-popover-button"]);function fi(){if(typeof customElements>"u")return;["searchcraft-popover-button"].forEach(t=>{switch(t){case"searchcraft-popover-button":customElements.get(t)||customElements.define(t,di);break}})}const pi=fi,mi=U(class extends N{constructor(){super();h(this,"item");h(this,"popoverResultMappings");h(this,"documentPosition",0);h(this,"href");h(this,"imageSrc");h(this,"imageAlt");h(this,"titleContent");h(this,"subtitleContent");h(this,"handleLinkClick",()=>{var n;const r=A.getState(),s=r.getSearchcraftInstance();if(s){const o=this.documentPosition,a=r.searchTerm,c=r.searchClientResponseItems.length||0;(n=s.measureClient)==null||n.sendMeasureEvent("document_clicked",{document_position:o,number_of_documents:c,search_term:a})}});this.__registerHost()}mapValuesFromDocument(r){var s,n,o,a,c;this.titleContent=de(r,(s=this.popoverResultMappings)==null?void 0:s.title),this.subtitleContent=de(r,(n=this.popoverResultMappings)==null?void 0:n.subtitle),this.href=de(r,(o=this.popoverResultMappings)==null?void 0:o.href),this.imageSrc=de(r,(a=this.popoverResultMappings)==null?void 0:a.imageSource),this.imageAlt=de(r,(c=this.popoverResultMappings)==null?void 0:c.imageAlt)}connectedCallback(){this.item&&this.mapValuesFromDocument(this.item.document)}disconnectedCallback(){}render(){return f("a",{key:"870fae8c0019ea24d9ecd173a781a38e3b17f8de",class:"searchcraft-popover-list-item",href:this.href,onClick:this.handleLinkClick.bind(this)},this.imageSrc&&f("div",{key:"9e200a2be177fed7f6303fdc1ba466fc47817b5d",class:"searchcraft-popover-list-item-image-wrapper"},f("img",{key:"22124b2856cd41220ac852a1fbc94cbf2a1cd9f9",alt:this.imageAlt,src:this.imageSrc,class:"searchcraft-popover-list-item-image"})),f("div",{key:"b3f0bb6784a36befd044e71798915994093177ab",class:"searchcraft-popover-list-item-info-wrapper"},f("p",{key:"caa22a8d68b56814ee29498db48fe1c65d8d7644",class:"searchcraft-popover-list-item-title"},this.titleContent),f("p",{key:"63e11be221d6f274855f7989b3a9dc4532c08e05",class:"searchcraft-popover-list-item-subtitle"},this.subtitleContent)))}},[0,"searchcraft-popover-list-item",{item:[16],popoverResultMappings:[16],documentPosition:[2,"document-position"],href:[32],imageSrc:[32],imageAlt:[32],titleContent:[32],subtitleContent:[32]}]);function ur(){if(typeof customElements>"u")return;["searchcraft-popover-list-item"].forEach(t=>{switch(t){case"searchcraft-popover-list-item":customElements.get(t)||customElements.define(t,mi);break}})}const gi=U(class extends N{constructor(){super();h(this,"popoverResultMappings");h(this,"searchClientResponseItems");h(this,"adClientResponseItems");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"config",(Ys=A.getState().core)==null?void 0:Ys.config);this.__registerHost()}renderWithADMAds(){var r,s;return f("div",{class:"searchcraft-popover-list-view"},(r=this.adClientResponseItems)==null?void 0:r.map(n=>f("searchcraft-ad",{adClientResponseItem:n,adSource:"adMarketplace",key:n.id})),(s=this.searchClientResponseItems)==null?void 0:s.map((n,o)=>f("searchcraft-popover-list-item",{item:n,key:n.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+o})))}renderWithCustomAds(){var u,l,i,p;const r=[],s=((u=this.config)==null?void 0:u.customAdInterstitialInterval)||0,n=((l=this.config)==null?void 0:l.customAdInterstitialQuantity)||1,o=((i=this.config)==null?void 0:i.customAdStartQuantity)||0,a=((p=this.config)==null?void 0:p.customAdEndQuantity)||0,c=this.searchClientResponseItems||[];for(let m=0;m<o;m++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m}-ad`}));c.forEach((m,b)=>{if(s&&b%s===0&&b+s<c.length&&b>=s)for(let v=0;v<n;v++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m.id}-ad-${v}`}));r.push(f("searchcraft-popover-list-item",{item:m,key:m.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+b}))});for(let m=0;m<a;m++)r.push(f("searchcraft-ad",{adSource:"Custom",key:`${m}-ad`}));return f("div",{class:"searchcraft-popover-list-view"},r)}renderWithNativoAds(){var l,i,p,m,b;const r=[],s=((l=this.config)==null?void 0:l.nativoAdInterstialStartIndex)||0,n=((i=this.config)==null?void 0:i.nativoAdInterstitialInterval)||0,o=((p=this.config)==null?void 0:p.nativoAdInterstitialQuantity)||1,a=((m=this.config)==null?void 0:m.nativoAdStartQuantity)||0,c=((b=this.config)==null?void 0:b.nativoAdEndQuantity)||0,u=this.searchClientResponseItems||[];for(let v=0;v<a;v++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v}-ad`}));u.forEach((v,$)=>{if(n&&($+s)%n===0&&$+n<u.length&&$>=n)for(let z=0;z<o;z++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v.id}-ad-${z}`}));r.push(f("searchcraft-popover-list-item",{item:v,key:v.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+$}))});for(let v=0;v<c;v++)r.push(f("searchcraft-ad",{adSource:"Nativo",key:`${v}-ad`}));return f("div",{class:"searchcraft-popover-list-view"},r)}renderWithNoAds(){var r;return f("div",{class:"searchcraft-popover-list-view"},(r=this.searchClientResponseItems)==null?void 0:r.map((s,n)=>f("searchcraft-popover-list-item",{item:s,key:s.id,popoverResultMappings:this.popoverResultMappings,documentPosition:this.searchResultsPerPage*(this.searchResultsPage-1)+n})))}render(){var r;switch(((r=this.config)==null?void 0:r.adSource)||"None"){case"adMarketplace":return this.renderWithADMAds();case"Custom":return this.renderWithCustomAds();case"Nativo":return this.renderWithNativoAds();default:return this.renderWithNoAds()}}},[0,"searchcraft-popover-list-view",{popoverResultMappings:[16],searchClientResponseItems:[16],adClientResponseItems:[16],searchResultsPage:[2,"search-results-page"],searchResultsPerPage:[2,"search-results-per-page"]}]);function zs(){if(typeof customElements>"u")return;["searchcraft-popover-list-view","searchcraft-ad","searchcraft-popover-list-item"].forEach(t=>{switch(t){case"searchcraft-popover-list-view":customElements.get(t)||customElements.define(t,gi);break;case"searchcraft-ad":customElements.get(t)||kt();break;case"searchcraft-popover-list-item":customElements.get(t)||ur();break}})}const vi=U(class extends N{constructor(){super();h(this,"type","inline");h(this,"popoverResultMappings");h(this,"hotkey","k");h(this,"hotkeyModifier","meta");h(this,"isPopoverVisibleInState",!1);h(this,"unsubscribe");h(this,"searchClientResponseItems",[]);h(this,"adClientResponseItems",[]);h(this,"searchTerm");h(this,"isFocused",!1);h(this,"breakpointSm",576);h(this,"breakpointMd",768);h(this,"breakpointLg",992);h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"modalElement");h(this,"handleDocumentClick",r=>{this.hostElement.contains(r.target)||(this.isFocused=!1)});h(this,"handleDocumentKeyDown",r=>{if(r.key===this.hotkey&&this.handleHotkeyPressed(r),!!this.hostElement.contains(document.activeElement))switch(r.key){case"ArrowDown":case"ArrowUp":r.preventDefault(),this.focusOnNextListItem(r.key);break;case"Escape":A.getState().setPopoverVisibility(!1);break;default:return}});h(this,"handleInputInit",()=>{const r=this.hostElement.querySelector(".searchcraft-input");r==null||r.focus()});this.__registerHost()}get hostElement(){return this}componentDidLoad(){const r=getComputedStyle(document.documentElement);this.breakpointSm=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-sm").trim()),this.breakpointMd=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-md").trim()),this.breakpointLg=Number.parseFloat(r.getPropertyValue("--sc-breakpoint-lg").trim()),this.isPopoverVisibleInState=A.getState().isPopoverVisible,document.addEventListener("click",this.handleDocumentClick),document.addEventListener("keydown",this.handleDocumentKeyDown),this.unsubscribe=A.subscribe(s=>{this.isPopoverVisibleInState!==s.isPopoverVisible&&this.handlePopoverVisibilityChange(s.isPopoverVisible),this.searchClientResponseItems=[...s.searchClientResponseItems],this.adClientResponseItems=[...s.adClientResponseItems],this.searchTerm=s.searchTerm,this.searchResultsPage=s.searchResultsPage,this.searchResultsPerPage=s.searchResultsPerPage})}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this),document.removeEventListener("click",this.handleDocumentClick),document.removeEventListener("keydown",this.handleDocumentKeyDown)}handlePopoverVisibilityChange(r){this.isPopoverVisibleInState=r,document.body.style.overflow=r?"hidden":"auto"}handleInputFocus(){this.isFocused=!0,this.type==="inline"&&window.visualViewport&&window.visualViewport.width<this.breakpointSm&&(A.getState().setPopoverVisibility(!0),this.modalElement||(this.modalElement=document.createElement("searchcraft-popover-form"),this.modalElement.popoverResultMappings=this.popoverResultMappings,this.modalElement.setAttribute("type","fullscreen"),document.body.appendChild(this.modalElement)))}handleModalBackdropClick(r){A.getState().setPopoverVisibility(!1)}handleHotkeyPressed(r){if(r.ctrlKey&&this.hotkeyModifier==="ctrl"||r.altKey&&this.hotkeyModifier==="alt"||r.metaKey&&this.hotkeyModifier==="meta")if(r.preventDefault(),this.type==="inline"&&!this.isPopoverVisibleInState){const s=this.hostElement.querySelector(".searchcraft-input");s==null||s.focus()}else A.getState().setPopoverVisibility(!this.isPopoverVisibleInState)}handleCancelButtonClick(){A.getState().setPopoverVisibility(!1)}focusOnNextListItem(r){var o,a;const s=Array.from(document.querySelectorAll("a.searchcraft-popover-list-item")).filter(c=>!c.hasAttribute("disabled")&&c.offsetParent!==null),n=s.indexOf(document.activeElement);if(r==="ArrowDown")(o=s[(n+1)%s.length])==null||o.focus();else if(r==="ArrowUp")if(n>=1)(a=s[n-1])==null||a.focus();else{const c=document.querySelector(".searchcraft-input");c&&(c.focus(),requestAnimationFrame(()=>{c.selectionEnd=c.value.length,c.selectionStart=c.value.length}))}}get hasResultsToShow(){var r,s;return this.searchTerm&&((s=(r=this.searchTerm)==null?void 0:r.trim())==null?void 0:s.length)>0&&this.searchClientResponseItems.length>0}renderInlinePopover(){const r=this.hasResultsToShow&&this.isFocused,s=L("searchcraft-popover-form searchcraft-popover-form-inline",{"searchcraft-popover-form-active":r});return f("div",{class:s},f("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this)}),r&&f("div",{class:"searchcraft-popover-inline-wrapper-outer"},f("div",{class:"searchcraft-popover-inline-wrapper-inner"},f("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage}))))}renderModalPopover(){if(this.isPopoverVisibleInState){const r=L("searchcraft-popover-form",{"searchcraft-popover-form-active":this.hasResultsToShow});return f("div",{class:"searchcraft-popover-form-modal"},f("div",{class:"searchcraft-popover-form-modal-backdrop",onClick:this.handleModalBackdropClick}),f("div",{class:"searchcraft-popover-form-modal-inner"},f("div",{class:r},f("div",{class:"searchcraft-popover-form-input-wrapper"},f("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this),onInputInit:this.handleInputInit.bind(this)}),f("button",{type:"button",class:"searchcraft-popover-form-cancel-button",onClick:this.handleCancelButtonClick.bind(this)},"Cancel")),this.hasResultsToShow&&f("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage}))))}}renderFullscreenPopover(){if(this.isPopoverVisibleInState)return f("div",{class:"searchcraft-popover-form-fullscreen"},f("div",{class:"searchcraft-popover-form"},f("div",{class:"searchcraft-popover-form-input-wrapper"},f("searchcraft-input-form",{onInputFocus:this.handleInputFocus.bind(this),onInputInit:this.handleInputInit.bind(this)}),f("button",{type:"button",class:"searchcraft-popover-form-cancel-button",onClick:this.handleCancelButtonClick.bind(this)},"Cancel")),this.hasResultsToShow&&f("searchcraft-popover-list-view",{popoverResultMappings:this.popoverResultMappings,searchClientResponseItems:this.searchClientResponseItems,adClientResponseItems:this.adClientResponseItems,searchResultsPage:this.searchResultsPage,searchResultsPerPage:this.searchResultsPerPage})))}render(){switch(this.type){case"inline":return this.renderInlinePopover();case"modal":return this.renderModalPopover();case"fullscreen":return this.renderFullscreenPopover()}}},[0,"searchcraft-popover-form",{type:[1],popoverResultMappings:[16],hotkey:[1],hotkeyModifier:[1,"hotkey-modifier"],isPopoverVisibleInState:[32],unsubscribe:[32],searchClientResponseItems:[32],adClientResponseItems:[32],searchTerm:[32],isFocused:[32],breakpointSm:[32],breakpointMd:[32],breakpointLg:[32],searchResultsPage:[32],searchResultsPerPage:[32],modalElement:[32]}]);function Hs(){if(typeof customElements>"u")return;["searchcraft-popover-form","searchcraft-ad","searchcraft-button","searchcraft-error-message","searchcraft-input-form","searchcraft-input-label","searchcraft-popover-form","searchcraft-popover-list-item","searchcraft-popover-list-view"].forEach(t=>{switch(t){case"searchcraft-popover-form":customElements.get(t)||customElements.define(t,vi);break;case"searchcraft-ad":customElements.get(t)||kt();break;case"searchcraft-button":customElements.get(t)||xt();break;case"searchcraft-error-message":customElements.get(t)||Tt();break;case"searchcraft-input-form":customElements.get(t)||Us();break;case"searchcraft-input-label":customElements.get(t)||lr();break;case"searchcraft-popover-form":customElements.get(t)||Hs();break;case"searchcraft-popover-list-item":customElements.get(t)||ur();break;case"searchcraft-popover-list-view":customElements.get(t)||zs();break}})}const bi=Hs,yi=ur,Si=zs,wi=U(class extends N{constructor(){super();h(this,"customFormatter");h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"searchResultsCount");h(this,"count",0);h(this,"range",[0,0]);h(this,"responseTime","0");h(this,"unsubscribe",()=>{});this.__registerHost()}connectedCallback(){this.unsubscribe=A.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPage=r.searchResultsPage,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsCount=r.searchResultsCount,this.count=this.searchResultsCount,this.range[0]=this.searchResultsPage<=1?1:this.searchResultsPerPage*(this.searchResultsPage-1),this.range[1]=this.searchResultsPerPage*this.searchResultsPage,this.range[1]=this.range[1]>this.searchResultsCount?this.searchResultsCount:this.range[1],this.responseTime=((r.searchResponseTimeTaken||0)*1e3).toFixed(2)})}disconnectedCallback(){this.unsubscribe&&this.unsubscribe()}render(){return!this.searchTerm||this.searchResultsCount===0?null:f("p",{class:L("searchcraft-results-info",rt(this.customStyles||{}))},this.customFormatter?this.customFormatter([cr(this.range[0]),cr(this.range[1])],cr(this.count),this.responseTime):`${this.count} results found in ${this.responseTime}ms`)}},[0,"searchcraft-results-info",{customFormatter:[16],customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPage:[32],searchResultsPerPage:[32],searchResultsCount:[32],count:[32],range:[32],responseTime:[32]}]);function Ri(){if(typeof customElements>"u")return;["searchcraft-results-info"].forEach(t=>{switch(t){case"searchcraft-results-info":customElements.get(t)||customElements.define(t,wi);break}})}const Ei=Ri,Pi=U(class extends N{constructor(){super();h(this,"caption");h(this,"disabled",!1);h(this,"inputId");h(this,"label");h(this,"labelId");h(this,"name");h(this,"options",[]);h(this,"customStyles");h(this,"selectChange");h(this,"searchResultsPerPage");h(this,"setSearchResultsPage",()=>{});h(this,"setSearchResultsPerPage",()=>{});h(this,"handleSelectChange",r=>{this.selectChange.emit(r.target.value)});this.__registerHost(),this.selectChange=Te(this,"selectChange")}handleGoToPage(r){this.setSearchResultsPage(r)}render(){return f("div",{key:"5024d49d89a3649a5de591d37ded304a9dfb36d9",class:L("searchcraft-select",rt(this.customStyles||{}))},this.label&&f("label",{key:"005aea9b190e5a6c041721e20395be23f76faab6",class:"searchcraft-select-label",id:this.labelId||`${this.inputId}-label`,htmlFor:this.inputId},this.label),f("div",{key:"209d56844c0bcd241e73bafcad24fac927fe7ffa",class:"searchcraft-select-input-wrapper"},f("select",{key:"010c9e596ef45a303f84c0ac0fa54ab67556d7b6","aria-labelledby":this.label?this.labelId||`${this.inputId}-label`:void 0,class:"searchcraft-select-input",disabled:this.disabled,id:this.inputId,name:this.name,onChange:this.handleSelectChange},(typeof this.options=="string"?JSON.parse(this.options):this.options).map(({label:r,value:s,selected:n})=>f("option",{key:s,value:s,selected:n},r))),f("svg",{key:"51d9fb79381468ee0992475ba376df5a5961116c",class:"searchcraft-select-input-icon",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},f("title",{key:"59186138953557764915d41708d4bcc23a9bb97f"},"Select dropdown icon"),f("path",{key:"ec2c962df16cb68bdaf3e2c32e57d875a63957a9",d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))),this.caption&&f("p",{key:"742bc2dbd8371938894d49bb37d429d1b7a07d7a",class:"searchcraft-select-caption"},this.caption))}},[0,"searchcraft-select",{caption:[1],disabled:[4],inputId:[1,"input-id"],label:[1],labelId:[1,"label-id"],name:[1],options:[1],customStyles:[1,"custom-styles"],searchResultsPerPage:[32],setSearchResultsPage:[32],setSearchResultsPerPage:[32]}]);function Bs(){if(typeof customElements>"u")return;["searchcraft-select"].forEach(t=>{switch(t){case"searchcraft-select":customElements.get(t)||customElements.define(t,Pi);break}})}const Ci=U(class extends N{constructor(){super();h(this,"increment",20);h(this,"customStyles");h(this,"searchTerm");h(this,"searchResultsPage");h(this,"searchResultsPerPage");h(this,"searchResultsCount");h(this,"searchResultsPagesCount");h(this,"initialSearchResultsPerPage");h(this,"setSearchResultsPerPage",()=>{});h(this,"setSearchResultsPage",()=>{});h(this,"unsubscribe",()=>{});this.__registerHost()}componentDidLoad(){this.unsubscribe=A.subscribe(r=>{this.searchTerm=r.searchTerm,this.searchResultsPerPage=r.searchResultsPerPage,this.searchResultsPage=r.searchResultsPage,this.searchResultsCount=r.searchResultsCount,this.searchResultsPagesCount=Math.ceil(this.searchResultsCount/this.searchResultsPerPage),this.setSearchResultsPage=r.setSearchResultsPage,this.setSearchResultsPerPage=r.setSearchResultsPerPage}),this.initialSearchResultsPerPage=A.getState().searchResultsPerPage}disconnectedCallback(){var r;(r=this.unsubscribe)==null||r.call(this)}render(){if(!(!this.searchTerm||this.searchResultsPagesCount<=1))return f("div",{class:L("searchcraft-search-results-per-page",rt(this.customStyles||{}))},f("div",{class:"searchcraft-search-results-per-page-select"},f("label",{class:"searchcraft-search-results-per-page-select-label",htmlFor:"searchcraft-search-results-per-page-select-input"},"Results Per Page"),f("div",{class:"searchcraft-search-results-per-page-select-input"},f("searchcraft-select",{inputId:"searchcraft-search-results-per-page-select-input",name:"results-per-page",options:[...Array(5)].map((r,s)=>{const n=this.initialSearchResultsPerPage+Number(this.increment)*s;return{label:`${n}`,value:n}}),onSelectChange:r=>{this.setSearchResultsPerPage(Number(r.detail)),this.setSearchResultsPage(1)}}))))}},[0,"searchcraft-search-results-per-page",{increment:[8],customStyles:[1,"custom-styles"],searchTerm:[32],searchResultsPage:[32],searchResultsPerPage:[32],searchResultsCount:[32],searchResultsPagesCount:[32],initialSearchResultsPerPage:[32],setSearchResultsPerPage:[32],setSearchResultsPage:[32]}]);function ki(){if(typeof customElements>"u")return;["searchcraft-search-results-per-page","searchcraft-select"].forEach(t=>{switch(t){case"searchcraft-search-results-per-page":customElements.get(t)||customElements.define(t,Ci);break;case"searchcraft-select":customElements.get(t)||Bs();break}})}const Ti=ki,xi=Bs,$i=Ds,_i=`:root{--sc-text-base-size: 1em;--sc-text-scale-ratio: 1.1;--sc-font-family: sans-serif;--sc-font-bold: 700;--sc-font-normal: 400;--sc-heading-1-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-2-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-3-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-4-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-5-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-6-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) );--sc-body-font-size: calc(var(--sc-text-base-size));--sc-body-small-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) )}:root{--sc-border-radius: 8px;--sc-border-radius-sm: calc(var(--sc-border-radius) / 2);--sc-border-radius-lg: calc(var(--sc-border-radius) * 2)}:root{--sc-breakpoint-sm: 576px;--sc-breakpoint-md: 768px;--sc-breakpoint-lg: 992px}:root{--sc-surface-neutral-primary: var(--sc-color-background, #ffffff);--sc-color-background-hover: hsl( from var(--sc-color-background) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-primary-hover: var(--sc-color-background-hover, #fafafa);--sc-color-background-active: hsl( from var(--sc-color-background) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-primary-active: var( --sc-color-background-active, #f7f7f7 );--sc-surface-neutral-secondary: var( --sc-color-background-secondary, var(--sc-color-background, #f3f3f3) );--sc-surface-neutral-secondary-hover: var( --sc-color-background-secondary-hover, var(--sc-color-background-hover, #e6e6e6) );--sc-surface-neutral-secondary-active: var( --sc-color-background-secondary-active, var(--sc-color-background-active, #e0e0e0) );--sc-surface-neutral-light: #ffffff;--sc-content-neutral-primary: var(--sc-color-foreground, #292929);--sc-color-foreground-secondary: hsl( from var(--sc-color-foreground) h s clamp(10, calc(l + 5), 90) );--sc-content-neutral-secondary: var(--sc-color-foreground-secondary, #404040);--sc-border-neutral: rgba(0, 0, 0, 0.1);--sc-surface-brand-primary: var(--sc-color-brand, #000000);--sc-color-brand-hover: hsl( from var(--sc-color-brand) h s clamp(20, calc(l + 5), 95) );--sc-surface-brand-primary-hover: var(--sc-color-brand-hover, #2e2e2e);--sc-color-brand-active: hsl( from var(--sc-color-brand) h s clamp(10, calc(l - 5), 85) );--sc-surface-brand-primary-active: var(--sc-color-brand-active, #292929);--sc-surface-brand-secondary: var( --sc-color-brand-secondary, var(--sc-color-brand, #e6e6e6) );--sc-surface-brand-secondary-hover: var( --sc-color-brand-secondary-hover, var(--sc-color-brand-hover, #ebebeb) );--sc-surface-brand-secondary-active: var( --sc-color-brand-secondary-active, var(--sc-color-brand-active, #e0e0e0) );--sc-content-brand: var( --sc-color-brand-text, var(--sc-surface-brand-primary) );--sc-content-brand-on-primary: #ffffff;--sc-border-brand: var(--sc-surface-brand-primary);--sc-surface-success-primary: var(--sc-color-success, #008000);--sc-color-success-primary-hover: hsl(from var(--sc-color-success) h s 30);--sc-surface-success-primary-hover: var( --sc-color-success-primary-hover, #009900 );--sc-color-success-primary-active: hsl(from var(--sc-color-success) h s 20);--sc-surface-success-primary-active: var( --sc-color-success-primary-active, #006600 );--sc-color-success-secondary: hsl(from var(--sc-color-success) h s 90);--sc-surface-success-secondary: var(--sc-color-success-secondary, #ccffcc);--sc-color-success-secondary-hover: hsl( from var(--sc-color-success-secondary) h s 95 );--sc-surface-success-secondary-hover: var( --sc-color-success-secondary-hover, #e6ffe6 );--sc-color-success-secondary-active: hsl( from var(--sc-color-success-secondary) h s 85 );--sc-surface-success-secondary-active: var( --sc-color-success-secondary-active, #b2ffb2 );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30) );--sc-content-success-on-primary: #ffffff;--sc-border-success: var(--sc-surface-success-primary);--sc-surface-caution-primary: var(--sc-color-caution, #cc6600);--sc-color-caution-primary-hover: hsl(from var(--sc-color-caution) h s 30);--sc-surface-caution-primary-hover: var( --sc-color-caution-primary-hover, #e57300 );--sc-color-caution-primary-active: hsl(from var(--sc-color-caution) h s 20);--sc-surface-caution-primary-active: var( --sc-color-caution-primary-active, #b25a00 );--sc-color-caution-secondary: hsl(from var(--sc-color-caution) h s 90);--sc-surface-caution-secondary: var(--sc-color-caution-secondary, #ffd9b3);--sc-color-caution-secondary-hover: hsl( from var(--sc-color-caution-secondary) h s 95 );--sc-surface-caution-secondary-hover: var( --sc-color-caution-secondary-hover, #ffe5cc );--sc-color-caution-secondary-active: hsl( from var(--sc-color-caution-secondary) h s 85 );--sc-surface-caution-secondary-active: var( --sc-color-caution-secondary-active, #ffcc99 );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30) );--sc-content-caution-on-primary: #ffffff;--sc-border-caution: var(--sc-surface-caution-primary);--sc-surface-danger-primary: var(--sc-color-danger, #cc0000);--sc-color-danger-primary-hover: hsl(from var(--sc-color-danger) h s 30);--sc-surface-danger-primary-hover: var( --sc-color-danger-primary-hover, #e50000 );--sc-color-danger-primary-active: hsl(from var(--sc-color-danger) h s 20);--sc-surface-danger-primary-active: var( --sc-color-danger-primary-active, #b30000 );--sc-color-danger-secondary: hsl(from var(--sc-color-danger) h s 90);--sc-surface-danger-secondary: var(--sc-color-danger-secondary, #ffcccc);--sc-color-danger-secondary-hover: hsl( from var(--sc-color-danger-secondary) h s 95 );--sc-surface-danger-secondary-hover: var( --sc-color-danger-secondary-hover, #ffe7e7 );--sc-color-danger-secondary-active: hsl( from var(--sc-color-danger-secondary) h s 85 );--sc-surface-danger-secondary-active: var( --sc-color-danger-secondary-active, #ffb3b3 );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30) );--sc-content-danger-on-primary: #ffffff;--sc-border-danger: var(--sc-surface-danger-primary);--sc-color-disabled: hsl(from var(--sc-color-page-primary) h s calc(l * 0.5));--sc-surface-disabled: var(--sc-color-disabled, #d9d9d9);--sc-color-disabled-text: hsl( from var(--sc-color-text-primary) h s calc(l * 0.5) );--sc-content-disabled: var(--sc-color-disabled-text, #737373);--sc-content-disabled-on-disabled: var(--sc-color-disabled-text, #737373)}@supports(hanging-punctuation: first) and (font: -apple-system-body) and (-webkit-appearance: none){:root{--sc-color-background-hover: hsl( from var(--sc-color-background) h s clamp(10%, calc(l + 5%), 95%) );--sc-color-background-active: hsl( from var(--sc-color-background) h s clamp(5%, calc(l - 5%), 90%) );--sc-color-foreground-secondary: hsl( from var(--sc-color-foreground) h s clamp(10%, calc(l + 5%), 90%) );--sc-color-brand-hover: hsl( from var(--sc-color-brand) h s clamp(20%, calc(l + 5%), 95%) );--sc-color-brand-active: hsl( from var(--sc-color-brand) h s clamp(10%, calc(l - 5%), 85%) );--sc-color-success-primary-hover: hsl(from var(--sc-color-success) h s 30%);--sc-color-success-primary-active: hsl( from var(--sc-color-success) h s 20% );--sc-color-success-secondary: hsl(from var(--sc-color-success) h s 90%);--sc-color-success-secondary-hover: hsl( from var(--sc-color-success-secondary) h s 95% );--sc-color-success-secondary-active: hsl( from var(--sc-color-success-secondary) h s 85% );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30%) );--sc-color-caution-primary-hover: hsl(from var(--sc-color-caution) h s 30%);--sc-color-caution-primary-active: hsl( from var(--sc-color-caution) h s 20% );--sc-color-caution-secondary: hsl(from var(--sc-color-caution) h s 90%);--sc-color-caution-secondary-hover: hsl( from var(--sc-color-caution-secondary) h s 95% );--sc-color-caution-secondary-active: hsl( from var(--sc-color-caution-secondary) h s 85% );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30%) );--sc-color-danger-primary-hover: hsl(from var(--sc-color-danger) h s 30%);--sc-color-danger-primary-active: hsl(from var(--sc-color-danger) h s 20%);--sc-color-danger-secondary: hsl(from var(--sc-color-danger) h s 90%);--sc-color-danger-secondary-hover: hsl( from var(--sc-color-danger-secondary) h s 95% );--sc-color-danger-secondary-active: hsl( from var(--sc-color-danger-secondary) h s 85% );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30%) )}}.searchcraft-custom-ad{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size)}.searchcraft-adm-ad{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);border:1px solid blue}.searchcraft-adm-ad:focus{background-color:var(--sc-surface-neutral-secondary-active);color:var(--sc-content-neutral-secondary)}.searchcraft-adm-ad:hover{background-color:var(--sc-surface-neutral-secondary-hover);color:var(--sc-content-neutral-secondary)}.searchcraft-adm-ad-title{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:inherit}.searchcraft-adm-ad-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);margin:0;color:inherit}.searchcraft-adm-ad-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-adm-ad-image{max-width:var(--sc-popover-list-item-image-size);max-height:var(--sc-popover-list-item-image-size)}.searchcraft-adm-ad-info-wrapper{display:flex;flex-direction:column;gap:8px;justify-content:center}.searchcraft-search-result-container{all:unset;align-items:flex-start;border-radius:var(--sc-border-radius-lg);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:calc(--sc-border-radius-lg - 8px);border-radius:calc(var(--sc-border-radius-lg) - 8px);width:100%}@media(min-width: 768px){.searchcraft-search-result-image{width:200px}}.searchcraft-base-search-result-title{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin:0}.searchcraft-base-search-result-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-disabled);margin:0}.searchcraft-base-search-result-body-content{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-neutral-secondary);margin:0}.searchcraft-base-search-result-footer-content{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-disabled);margin:0}.searchcraft-search-results-container{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-results-empty-state-container{text-align:center}.searchcraft-search-results-error-message-container{text-align:center}.searchcraft-button{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);background:none;border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;gap:4px;padding:12px;position:relative}.searchcraft-button.searchcraft-button-disabled{cursor:not-allowed}.searchcraft-button-primary{background-color:var(--sc-surface-brand-primary);color:var(--sc-content-brand-on-primary);font-weight:var(--sc-font-bold)}.searchcraft-button-primary:hover{background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button-primary:focus{border-color:var(--sc-border-primary)}.searchcraft-button-primary:active{background-color:var(--sc-surface-brand-primary-active)}.searchcraft-button-primary.searchcraft-button-disabled,.searchcraft-button-primary.searchcraft-button-disabled:hover,.searchcraft-button-primary.searchcraft-button-disabled:focus,.searchcraft-button-primary.searchcraft-button-disabled:active{background-color:var(--sc-surface-disabled);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-tertiary{background-color:var(--sc-surface-neutral-primary);color:var(--sc-content-brand);font-weight:var(--sc-font-normal)}.searchcraft-button-tertiary:hover{background-color:var(--sc-surface-brand-secondary-hover)}.searchcraft-button-tertiary:focus{background-color:var(--sc-surface-neutral-light);border-color:var(--sc-border-primary)}.searchcraft-button-tertiary:active{background-color:var(--sc-surface-brand-secondary-active)}.searchcraft-button-tertiary.searchcraft-button-disabled,.searchcraft-button-tertiary.searchcraft-button-disabled:hover,.searchcraft-button-tertiary.searchcraft-button-disabled:focus,.searchcraft-button-tertiary.searchcraft-button-disabled:active{background-color:var(--sc-surface-neutral-light);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-error-message{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-danger);margin:0}.filtersListContainer{width:100%}.filterCheckboxLabel{align-items:center;color:var(--sc-content-brand);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-neutral-secondary);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-neutral-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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-disabled);text-align:center}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-bold)}:root{--sc-input-border-radius: var(--sc-border-radius);--sc-input-search-icon-size: 20px;--sc-input-clear-icon-size: 20px;--sc-input-padding-left: 44px;--sc-input-padding-right: 44px}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);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);color:var(--sc-content-neutral-secondary)}.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);color:var(--sc-content-brand)}.searchcraft-input-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin-top:4px;margin-bottom:4px}:root{--sc-popover-form-border-radius: var(--sc-border-radius);--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}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);border-radius:calc(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);border:0;outline:0;padding:0;flex-shrink:0;background:none;cursor:pointer;padding-left:12px;padding-right:12px}.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:rgba(0,0,0,0)}}.searchcraft-popover-form-modal .searchcraft-input{border-radius:calc(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);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,.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(--sc-popover-form-border-radius - 12px);border-radius:calc(var(--sc-popover-form-border-radius) - 12px);outline-width:1px;outline-color:var(--sc-border-neutral)}.searchcraft-popover-form-fullscreen searchcraft-popover-list-view{overflow:scroll}.searchcraft-popover-list-item{all:unset;color:var(--sc-content-neutral-secondary);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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:inherit}.searchcraft-popover-list-item-subtitle{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);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}.searchcraft-results-info{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);color:var(--sc-content-primary);margin:0}.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:rgba(0,0,0,0);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}.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);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);margin:0;color:var(--sc-content-neutral-primary)}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);margin:0;color:var(--sc-content-neutral-secondary)}.searchcraft-toggle-button-background{transition:background-color .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,.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 .3s ease;width:18px}.searchcraft-toggle-button-handle.active{transform:translateX(16px)}.searchcraft-pagination{display:inline-grid;gap:16px;grid-template-columns:repeat(3, auto);grid-template-rows:1fr}.searchcraft-pagination-list{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius);display:flex;list-style-type:none;margin:0;overflow:hidden;padding:0;width:auto}.searchcraft-pagination-list li{border-right:1px solid var(--sc-border-neutral);height:100%;min-height:44px;width:44px}.searchcraft-pagination-list li:last-child{border-right:none}.searchcraft-pagination-item{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);align-items:center;background-color:var(--sc-surface-neutral-primary);border:none;display:flex;height:100%;justify-content:center;width:100%}.searchcraft-pagination-item-active{background-color:var(--sc-surface-brand-secondary);font-weight:var(--sc-font-bold)}.searchcraft-pagination-control{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius)}.searchcraft-pagination-range{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);align-items:center;display:flex}.searchcraft-select{display:flex;flex-direction:column;gap:4px}.searchcraft-select-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-bold)}.searchcraft-select-input-wrapper{position:relative}.searchcraft-select-input{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);appearance:none;background-color:var(--sc-surface-neutral-secondary);border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;height:44px;padding:0 44px 0 16px;width:100%}.searchcraft-select-input:hover{background-color:var(--sc-surface-neutral-secondary-hover)}.searchcraft-select-input:active{background-color:var(--sc-surface-neutral-secondary-active)}.searchcraft-select-input:focus{border-color:var(--sc-border-brand);outline:none}.searchcraft-select-input-icon{pointer-events:none;position:absolute;right:12px;top:50%;transform:translateY(-50%)}.searchcraft-select-caption{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size)}.searchcraft-search-results-per-page{display:flex}.searchcraft-search-results-per-page-select{align-items:center;display:flex;gap:12px}.searchcraft-search-results-per-page-select-label{font-family:var(--sc-font-family);font-weight:var(--sc-font-normal);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size)}.searchcraft-search-results-per-page-select-input{min-width:120px}/*# sourceMappingURL=hologram.css.map */
35
+ `,Ai=U(class extends N{constructor(){super();h(this,"theme");h(this,"customTheme");h(this,"camelToKebab",r=>r.replace(/[A-Z]/g,s=>`-${s.toLowerCase()}`).toLowerCase());this.__registerHost()}componentDidLoad(){const r=document.querySelector("#searchcraft-theme")||document.createElement("style");r.innerHTML=_i,r.id="searchcraft-theme";const s=document.head||document.getElementsByTagName("head")[0];s.contains(r)||(s.firstChild?s.insertBefore(r,s.firstChild):s.appendChild(r)),document.body.dataset.theme=this.theme||"light",Object.entries(JSON.parse(this.customTheme||"[]")).map(([n,o])=>{document.documentElement.style.setProperty(`--${this.camelToKebab(n)}`,`${o}`)})}render(){}},[0,"searchcraft-theme",{theme:[1],customTheme:[1,"custom-theme"]}]);function Ii(){if(typeof customElements>"u")return;["searchcraft-theme"].forEach(t=>{switch(t){case"searchcraft-theme":customElements.get(t)||customElements.define(t,Ai);break}})}const Mi=Ii,Li=Ns,js=()=>{Fo(),Uo(),Vo(),Go(),qo(),Zo(),ai(),ii(),ci(),hi(),pi(),bi(),yi(),Si(),Ei(),Ti(),xi(),$i(),Mi(),Li()};js();const Vs={name:"@searchcraft/vue-sdk",version:"0.9.6",private:!1,description:"Searchcraft Vue SDK.",type:"module",license:"Apache-2.0",keywords:["searchcraft"],scripts:{dev:"vite",clean:"rm -rf dist",build:"yarn clean && vite build && yarn docs",docs:"typedoc --options typedoc.json",preview:"vite preview","build-only":"vite build","type-check":"vue-tsc --build"},repository:{type:"git",url:"https://bitbucket.org/madebychalk/searchcraft-javascript-sdks/"},engines:{node:">=18.0.0",npm:">=10.0.0"},main:"./dist/index.umd.js",module:"./dist/index.es.js",types:"./dist/index.d.ts",exports:{".":{types:"./dist/index.d.ts",import:"./dist/index.es.js",require:"./dist/index.umd.js"},"./components":"./dist/components/index.d.ts","./plugin":"./dist/plugin.d.ts"},files:["dist"],peerDependencies:{vue:"^3.5.13"},devDependencies:{"@searchcraft/core":"^0.9.6","@searchcraft/javascript-sdk":"^0.9.6","@tsconfig/node22":"^22.0.0","@types/node":"^22.10.7","@vitejs/plugin-vue":"^5.2.1","@vitejs/plugin-vue-jsx":"^4.1.1","@vue/runtime-dom":"^3.5.13","@vue/tsconfig":"^0.7.0","npm-run-all2":"^7.0.2",vite:"^6.0.11","vite-plugin-dts":"^4.5.0","vite-plugin-vue-devtools":"^7.7.0","vue-docgen-web-types":"^0.1.8","vue-tsc":"^2.2.0"}},hr="routerLink",Ws="navManager",Oi="router",Fi="aria",st=Symbol(),Gs={default:st},qs=e=>(e==null?void 0:e.split(" "))||[],Di=(e,t,r=[])=>{var s;return[...Array.from(((s=e.value)==null?void 0:s.classList)||[]),...r].filter((n,o,a)=>!t.has(n)&&a.indexOf(n)===o)},we=(e,t,r=[],s=[],n,o)=>{t!==void 0&&t();const a=W.defineComponent((c,{attrs:u,slots:l,emit:i})=>{var K;const p=W.ref(),m=new Set(qs(u.class)),b=W.getCurrentInstance(),$=((K=b==null?void 0:b.appContext)==null?void 0:K.provides[Ws])?W.inject(Ws):void 0,z=_=>{const{routerLink:Re}=c;if(Re!==st)if($!==void 0){_.preventDefault();let le={event:_};for(const Le in c){const H=c[Le];c.hasOwnProperty(Le)&&Le.startsWith(Oi)&&H!==st&&(le[Le]=H)}$.navigate(le)}else console.warn("Tried to navigate, but no router was found. Make sure you have mounted Vue Router.")};return()=>{c[n],qs(u.class).forEach(H=>{m.add(H)});const _=c.onClick,Re=H=>{_!==void 0&&_(H),H.defaultPrevented||z(H)};let le={ref:p,class:Di(p,m),onClick:Re};for(const H in c){const oe=c[H];(c.hasOwnProperty(H)&&oe!==st||H.startsWith(Fi))&&(le[H]=oe);const B="on"+H.slice(0,1).toUpperCase()+H.slice(1),Oe=u[B];p.value&&u.hasOwnProperty(B)&&"addEventListener"in p.value&&p.value.addEventListener(H,Oe)}return hr in c&&c[hr]!==st&&(le={...le,href:c[hr]}),W.h(e,le,l.default&&l.default())}});if(typeof a!="function"){let c=[],u={};u.ROUTER_LINK_VALUE=Gs,r.forEach(l=>u[l]=Gs),c=s,a.name=e,a.emits=c,a.props=u}return a},Ni=we("searchcraft-base-search-results",()=>{},["customStylesForResults","searchResultMappings","resultImagePlacement","buttonLabel","buttonTarget","buttonRel","containerTarget","containerRel"]),Ui=we("searchcraft-filter-panel",()=>{},["items"]),zi=we("searchcraft-input-form",()=>{},["autoSearch","buttonPlacement","buttonLabel","inputLabel","customStyles","placeholderValue","core","inputFocus","inputBlur","inputInit"],["inputFocus","inputBlur","inputInit"]),Hi=we("searchcraft-pagination",()=>{},["customStyles"]),Bi=we("searchcraft-popover-button",()=>{}),ji=we("searchcraft-popover-form",()=>{},["type","popoverResultMappings","hotkey","hotkeyModifier"]),Vi=we("searchcraft-results-info",()=>{},["customFormatter","customStyles"]),Wi=we("searchcraft-search-results-per-page",()=>{},["increment","customStyles"]),Gi=we("searchcraft-theme",()=>{},["theme","customTheme"]),qi=Ni,Yi=Ui,Qi=zi,Ki=Bi,Xi=ji,Ji=Vi,Zi=Gi,ec=Hi,tc=Wi;class rc extends on{constructor(t){super(t,{sdkName:Vs.name,sdkVersion:Vs.version})}}js(),O.Searchcraft=rc,O.SearchcraftBaseSearchResults=qi,O.SearchcraftFilterPanel=Yi,O.SearchcraftInputForm=Qi,O.SearchcraftPagination=ec,O.SearchcraftPopoverButton=Ki,O.SearchcraftPopoverForm=Xi,O.SearchcraftResultsInfo=Ji,O.SearchcraftSearchResultsPerPage=tc,O.SearchcraftTheme=Zi,Object.defineProperty(O,Symbol.toStringTag,{value:"Module"})});
36
36
  //# sourceMappingURL=index.umd.js.map