var rootLinkSearchTest="https://apps.omegatheme.com/searchify",rootLinkSearch="https://apps.omegatheme.com/searchify",shopNameSearch=Shopify.shop,searchRequest=null,resultSuggest={},selectCollection="",settingsSearch,moneyFormatSearch,window_jQuery;if(typeof window.checkJSES>"u"){let loadJquerySearch2=function(callback){typeof jQuery>"u"?getScript2({source:"//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js",callback:()=>{jQuery224=jQuery.noConflict(!0),callback(jQuery224)}}):callback(jQuery)},elasticSearchLoadFile2=function(){var d=new Date,ver=d.getTime();getScript2({source:rootLinkSearch+"/appSuggest.js?v="+ver,callback:function(){ot_elasticSearch()}}),getScript2({source:rootLinkSearch+"/appResult.js?v="+ver,callback:function(){elasticSearchResult_init()}})},getScript2=function({source,callback}){var script=document.createElement("script"),prior=document.getElementsByTagName("script")[0];script.async=1,script.onload=script.onreadystatechange=function(_,isAbort){(isAbort||!script.readyState||/loaded|complete/.test(script.readyState))&&(script.onload=script.onreadystatechange=null,script=void 0,isAbort||callback&&callback())},script.src=source,prior.parentNode.insertBefore(script,prior)},omgrfq_checkInstallApp2=function(){var $2=window_jQuery,d=new Date,ver=d.getTime();return new Promise(resolve=>{$2.getJSON(rootLinkSearchTest+"/cache/"+shopNameSearch+"/data.json?v="+ver,function(data){resolve(data)})})};var loadJquerySearch=loadJquerySearch2,elasticSearchLoadFile=elasticSearchLoadFile2,getScript=getScript2,omgrfq_checkInstallApp=omgrfq_checkInstallApp2;window.checkJSES=1,loadJquerySearch2(function(jQuery2){elasticSearch_init(jQuery2)});async function elasticSearch_init(jQuery2){window_jQuery=jQuery2;var result=await omgrfq_checkInstallApp2();result!=null&&result.enable_app==1&&(settingsSearch=result,moneyFormatSearch=result.moneyFormat,elasticSearchLoadFile2())}}function getCssFormSuggestion(element){var body=$("body").width(),top=element.offset().top+element.outerHeight(),left=element.offset().left,width=element.outerWidth(),right=body-left-width;if(screen.width>380&&(width<380||width>800)&&(width=380),top>1500){var style={width:width+"px"};$(".ot-content-search").css(style),$(".dropdown-arrow").addClass("dropdown-arrow-top"),$(".dropdown-arrow-right").addClass("dropdown-arrow-right-top"),$(".dropdown-arrow-left").addClass("dropdown-arrow-left-top")}else{var style={top:top+"px",width:width+"px"};$(".ot-content-search").css(style),$(".dropdown-arrow").removeClass("dropdown-arrow-top"),$(".dropdown-arrow-right").removeClass("dropdown-arrow-right-top"),$(".dropdown-arrow-left").removeClass("dropdown-arrow-left-top")}screen.height>700?$(".dropsearch").css("max-height","600px"):$(".dropsearch").css("max-height","445px"),left"u"?def:opt}function formatWithDelimiters(number,precision,thousands,decimal){if(precision=defaultOption(precision,2),thousands=defaultOption(thousands,","),decimal=defaultOption(decimal,"."),isNaN(number)||number==null)return 0;number=(number/100).toFixed(precision);var parts=number.split("."),dollars=parts[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+thousands),cents2=parts[1]?decimal+parts[1]:"";return dollars+cents2}switch(formatString.match(placeholderRegex)[1]){case"amount":value=formatWithDelimiters(cents,2);break;case"amount_no_decimals":value=formatWithDelimiters(cents,0);break;case"amount_with_comma_separator":value=formatWithDelimiters(cents,2,".",",");break;case"amount_no_decimals_with_comma_separator":value=formatWithDelimiters(cents,0,".",",");break}return formatString.replace(placeholderRegex,value)}function shortString(string,limit,charReplace=null){if(charReplace==null&&(charReplace="..."),typeof string=="string"){var length=string.length;if(length>limit){var subString=string.substr(0,limit-1);return subString+charReplace}else return string}else console.log("Please enter string!")} //# sourceMappingURL=/cdn/shop/t/27/assets/better-search.js.map?v=97788684063957842491614572292