var BoostPFS=function(J){function z($){for(var V,x,w=$[0],_=$[1],I=$[2],j=0,k=[];j0&&(c=N.a.mergeObject(c,boostPFSAppConfig)),typeof boostPFSThemeConfig!="undefined"&&Object.keys(boostPFSThemeConfig).length>0&&(c=N.a.mergeObject(c,boostPFSThemeConfig)),typeof boostPFSFilterConfig!="undefined"&&Object.keys(boostPFSFilterConfig).length>0&&(c=N.a.mergeObject(c,boostPFSFilterConfig)),typeof boostPFSInstantSearchConfig!="undefined"&&Object.keys(boostPFSInstantSearchConfig).length>0&&(c=N.a.mergeObject(c,boostPFSInstantSearchConfig)),typeof Shopify!="undefined"&&Shopify.hasOwnProperty("locale")&&c.hasOwnProperty("label")&&c.hasOwnProperty("labelTranslations")&&c.labelTranslations!==void 0&&c.labelTranslations.hasOwnProperty(Shopify.locale)){var g=c.labelTranslations[Shopify.locale];c.label=N.a.mergeObject(c.label||{},g)}h=c},getSettingValue:function(c){var g="";if(h.hasOwnProperty(c))return h[c];if(c.indexOf(".")>-1)for(var f=c.split("."),P=0;P-1)return!0;return!1},encodeURIParamValue:function(p){return encodeURIComponent(p).replace(/&/g,"%26").replace(/'/g,"%27").replace(/\*/g,"%2A")}},H=(l(109),l(8));function b(p){return(b=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(m){return typeof m}:function(m){return m&&typeof Symbol=="function"&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m})(p)}var $=function(){return c.a.getSettingValue("general.paginationTypeAdvanced")},V=function(){return c.a.getSettingValue("general.paginationType")=="load_more"},x=function(){return c.a.getSettingValue("general.paginationType")=="infinite"},w={getSortingList:function(){var p=c.a.getSettingValue("general.sortingList"),m=c.a.getSettingValue("general.customSortingList");if(m!="")for(var d=(p=m.trim().split("|")).length-1;d>=0;d--)p[d]==""&&p.splice(d,1);var v=c.a.getSettingValue("general.extraSortingList");if(v&&(p=p.concat(v.split("|"))),E.isSearchPage()){var O=E.findIndexArray("manual",p);O>=0&&p.splice(O,1)}else{var R=E.findIndexArray("relevance",p);R>=0&&p.splice(R,1)}for(var U={},G=0;G0&&v.indexOf(p[G])>-1){var Y=p[G].replace(/-/g,"_");K=H.a[Y]}if(U[p[G]]=K,H.a.sortByOptions){var te=H.a.sortByOptions[p[G]];te&&te.length>0&&(U[p[G]]=te)}}return U},getDefaultSorting:function(p){var m=c.a.getSettingValue("default_sort_order"),d="";return b(m)=="object"&&p!==void 0&&((d=m[p=p.toString()])||(d=p=="search"?"relevance":m.all)),d},getProductMetafield:function(p,m,d){if(p.hasOwnProperty("metafields")){var v=p.metafields.filter(function(O){return O.namespace==m&&O.key==d});if(v[0]!==void 0)return v[0].value}return null},isAdvancedPaginationType:$,buildProductItemUrl:function(p,m){var d=E.getWindowLocation().search.substring(1),v=window.location.pathname,O=v.split("/"),R=b(p)==="object"&&p.hasOwnProperty("handle")?p.handle:p;if(m=m!==void 0?m:c.a.getSettingValue("general.addCollectionToProductUrl")){if(v=="/"||E.isSearchPage()||E.isVendorPage()||E.isTypePage())return(U=O.indexOf(boostPFSAppConfig.general.current_locale)>-1?"/"+boostPFSAppConfig.general.current_locale+"/collections/all/products/":"/collections/all/products/")+R;if(E.isTagPage()){var U=O.indexOf(boostPFSAppConfig.general.current_locale)>-1?"/"+boostPFSAppConfig.general.current_locale+"/collections/":"/collections/",G=O.indexOf("collections")+1;return O.length>=4?U+O[G]+"/products/"+R:"/collections/all/products/"+R}if(d.indexOf("cache:")>-1){var K="all",Y=d.split("&")[0].split("?")[0].split("collections/");return Y.length>1&&(K=Y[1].indexOf("/")>-1?Y[1].split("/")[0]:Y[1]),"/collections/"+(K=K.replace(/[`~!@#$%^&*()_|+\=?;:'",.<>\{\}\[\]\\\/]/g,""))+"/products/"+R}return G=O.indexOf("collections")+1,U=O.indexOf(boostPFSAppConfig.general.current_locale)>-1?"/"+boostPFSAppConfig.general.current_locale+"/collections/":"/collections/",O[2]!==void 0?U+O[G]+"/products/"+R:window.location.pathname+"/products/"+R}return O.indexOf(boostPFSAppConfig.general.current_locale)>-1?"/"+boostPFSAppConfig.general.current_locale+"/products/"+R:"/products/"+R},buildProductItemVendorUrl:function(p){return window.location.protocol+"//"+window.location.hostname+"/collections/vendors?q="+P.encodeURIParamValue(p)},removePageParamFromUrl:function(p){return g.a.queryParams.hasOwnProperty("page")&&(p=p.replace("&page="+g.a.queryParams.page,"").replace("?page="+g.a.queryParams.page+"&","?").replace("?page="+g.a.queryParams.page,"")),p},removeCollectionScopeParamFromUrl:function(p){return g.a.queryParams.hasOwnProperty("collection_scope")&&(p=p.replace("&collection_scope="+g.a.queryParams.collection_scope,"")),p},buildToolbarLink:function(p,m,d){var v=window.location.origin+window.location.pathname;switch(p){case"page":case"limit":case"sort":case"display":if(p=="page"&&d==1)break;v+="?"+p+"="+d}return v},isDefaultPaginationType:function(){return c.a.getSettingValue("general.paginationType")=="default"},isLoadMorePaginationType:V,isInfiniteLoadingPaginationType:x,isLoadPreviousPagePaginationType:function(){return(V()||x())&&$()&&c.a.getSettingValue("general.activeLoadPreviousPage")},isNoFilterResult:function(p,m){return p<=0&&!(m==="init"&&c.a.getSettingValue("general.productAndVariantAvailable")&&c.a.getSettingValue("general.availableAfterFiltering"))},compileShopifyProductVariables:function(p,m){return m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=(m=m.replace(/{{product.title}}/g,p.title)).replace(/{{product.vendor}}/g,p.vendor)).replace(/{{product.url}}/g,E.buildProductItemUrl(p))).replace(/{{product.available}}/g,p.available)).replace(/{{product.compare_at_price}}/g,E.formatMoney(p.compare_at_price_min))).replace(/{{product.compare_at_price_min}}/g,E.formatMoney(p.compare_at_price_min))).replace(/{{product.compare_at_price_max}}/g,E.formatMoney(p.compare_at_price_max))).replace(/{{product.description}}/g,p.body_html!==void 0&&p.body_html!=null?p.body_html:"")).replace(/{{product.handle}}/g,p.handle)).replace(/{{product.id}}/g,p.id)).replace(/{{product.price}}/g,E.formatMoney(p.price_min))).replace(/{{product.price_max}}/g,E.formatMoney(p.price_max))).replace(/{{product.price_min}}/g,E.formatMoney(p.price_min))).replace(/{{product.template_suffix}}/g,p.template_suffix!==void 0&&p.template_suffix!=null?p.template_suffix:"")).replace(/{{product.percent_sale_min}}/g,p.percent_sale_min>0?p.percent_sale_min:"")).replace(/{{product.type}}/g,p.product_type)).replace(/{{product.sku}}/g,p.skus!==void 0&&p.skus!=null&&p.skus.length>0?p.skus[0]:"")},compileShopifyProductMetafield:function(p,m){if(m.indexOf("product.metafields")!=-1){var d=m.match(/\{\{product.metafields(.*?)\}\}/g),v=0,O="",R="",U="",G="";if(d.length>0){v=d.length;for(var K=0;K"+boostPFSConfig.shop.money_format+"").text().replace(/{{[^}]*}}/g,"")},k=null,C=function(){return A.getWindowLocation().href.includes("webcache.googleusercontent.com")?A.getWindowLocation().search.indexOf("search?")>-1:window.location.pathname.indexOf("/search")>-1},S=function(p,m){m||(m=A.getWindowLocation().href),p=p.replace(/[\[\]]/g,"\\$&");var d=new RegExp("[?&]"+p+"(=([^]*)|&|#|$)").exec(m);return d?d[2]?decodeURIComponent(d[2].replace(/\+/g," ")):"":null},D=function(p,m,d,v){if(d!=null){for(var O=0;O/g,"");return m=m.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/'/g,"'").replace(/$/g,"$").replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\$/g,"$"),m}return""},A={escape:function(p,m){return m=m?"
":"\n",(""+p).replace(/&/g,"&").replace(/'/g,"'").replace(/"/g,""").replace(//g,">").replace(/\r\n/g,m).replace(/[\r\n]/g,m)},unescape:function(p){return(""+p).replace(/&/g,"&").replace(/'/g,"'").replace(/"/g,'"').replace(/</g,"<").replace(/>/g,">")},findIndexArray:D,getParam:S,getSearchTerm:function(){return S(g.a.searchTermKey)},getValueInObjectArray:function(p,m,d,v){d===void 0&&(d="key"),v===void 0&&(v="values");var O=D(p,m,d);return O>-1&&m[O].hasOwnProperty(v)?m[O][v]:""},getFilePath:function(p,m,d){m=m!==void 0?m:"png",d=d!==void 0?d:"";var v=g.a.fileUrl.split("?")[0];return v+=p+"."+m+(d?"?v="+d:"")},getNumberDecimals:function(p){var m=p.toString().split(".");return m.length>1?m[1].length:0},isMobile:function(){return k||(k=h()(window).width(),h()(window).on("resize",function(){k=h()(window).width()})),k<=c.a.getSettingValue("general.breakpointMobile")},isMobileDevice:function(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)},isTablet:function(){return k||(k=h()(window).width(),h()(window).on("resize",function(){k=h()(window).width()})),k<=c.a.getSettingValue("general.breakpointTablet")&&k>c.a.getSettingValue("general.breakpointMobile")},isiOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream},isSafari:function(){return/Safari/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)},isBackButton:function(){return window.performance&&window.performance.navigation&&window.performance.navigation.type==2},isCartPage:function(){return window.location.pathname.indexOf("/cart")>-1},isProductPage:function(){return window.location.pathname.indexOf("/products")>-1},isCollectionPage:function(){return window.location.pathname.indexOf("/collections")>-1&&window.location.pathname.indexOf("/products")==-1},isSearchPage:C,isVendorPage:function(){return window.location.pathname.indexOf("/collections/vendors")>-1},isTagPage:function(){return g.a.currentTags!==void 0&&g.a.currentTags!==null&&g.a.currentTags.length>0},isTypePage:function(){return window.location.pathname.indexOf("/collections/types")>-1},isGLHMobile:function(){return navigator&&navigator.userAgent&&navigator.userAgent.includes(atob("TGlnaHRob3VzZQ=="))&&A.isMobile()&&!A.isSearchPage()},mergeObject:function p(m,d){for(var v in d)try{m[v]=d[v].constructor==Object?p(m[v],d[v]):d[v]}catch(O){m[v]=d[v]}return m},optimizeImage:I,getFeaturedImage:function(p,m){m=m!==void 0?m:"large";var d=I(boostPFSConfig.general.no_image_url,m);return p.length>0&&(d=_(p[0])==="object"?I(p[0].src,m):I(p[0],m)),d},slugify:function(p){if(p==null||_(p)=="object")return"";if(typeof p!="string"){if(typeof p.toString!="function")return"";p=p.toString()}p=p.toLowerCase();for(var m="\xE0\xE1\xE4\xE2\xE3\xE8\xE9\xEB\xEA\u1EBD\xEC\xED\xEF\xEE\u0129\xF2\xF3\xF6\xF4\xF5\xF9\xFA\xFC\xFB\u0169\xF1\xE7\xB7/_,:;",d=0,v=m.length;d\{\}\[\]\\\/]/g,"-").replace(/\-\-+/g,"-").replace(/^-+/,"").replace(/-+$/,"")},capitalize:function(p,m,d){return d=d!==void 0&&d,(m=m!==void 0&&m)&&(p=p.toLowerCase()),d?p.charAt(0).toUpperCase()+p.slice(1):p.replace(/(?:^|\s)\S/g,function(v){return v.toUpperCase()})},textify:function(p,m){m=m!==void 0?m:"-";for(var d=p.split(m),v="",O=0;O]*>.*?<\/script>/gi,"")},truncateByWord:function(p,m,d){return d===void 0&&(d="..."),p=p.split(" ").length>m?p.split(" ").splice(0,m).join(" ")+d:p.split(" ").splice(0,m).join(" ")},removeDecimal:function(p,m){m=m!==void 0?m:c.a.getSettingValue("general.decimalDelimiter");var d=new RegExp("(\\"+m+"\\d+)+","gi");return p.replace(d,"")},formatMoney:function(p,m,d){m===void 0&&(m=g.a.moneyFormat),(m=="money_with_currency"||c.a.getSettingValue("general.moneyFormatWithCurrency"))&&(m=g.a.moneyFormatWithCurrency),d===void 0&&(d=!1),typeof p=="string"&&(p=p.replace(".",""));var v="",O=/\{\{\s*(\w+)\s*\}\}/,R=m||"${{amount}}";function U(K,Y){return K===void 0?Y:K}function G(K,Y,te,re){if(Y=U(Y,2),te=U(te,","),re=U(re,"."),isNaN(K)||K==null)return 0;var le=(K=parseFloat(K).toFixed(Y)).split("."),ye=le[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+te),de=le[1]?re+le[1]:"";return d==1?(ye+de).replace(/((\,00)|(\.00))$/g,""):ye+de}switch(R.match(O)[1]){case"amount":v=G(p,2);break;case"amount_no_decimals":v=G(p,0);break;case"amount_with_comma_separator":v=G(p,2,".",",");break;case"amount_no_decimals_with_comma_separator":v=G(p,0,".",",");break;case"amount_with_space_separator_no_comma":default:v=G(p,2)}return R=R.replace(O,v),c.a.getSettingValue("general.enable3rdCurrencySupport")?A.moneyWrapper(R):R},moneyWrapper:function(p){return'{{money}}'.replace(/{{money}}/g,L(p))},formatNumberWithSeparator:function(p,m,d,v,O){isNaN(p)&&(p=0),isNaN(m)&&(m=0),v||(v=d=="."?",":".");var R=(p=parseFloat(p).toFixed(m)).toString().split("."),U=R[0],G=R[1]?R[1]:"";return d&&(U=U.replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+d)),v&&G&&(G=O&&/0+/.test(G)?"":v+G),U+G},getCurrency:j,removeCurrencySymbol:function(p){p=h()("1&&A.isShopifyActiveCurrency()},isConvertCurrenciesOnFrontEnd:function(){var p=c.a.getSettingValue("currencyRoundingRules");return p&&_(p)=="object"},roundedPrice:function(p){p=parseFloat(p).toFixed(2);var m=boostPFSAppConfig.general.current_currency.toLowerCase().trim(),d=c.a.getSettingValue("currencyRoundingRules"),v=d&&m&&d.hasOwnProperty(m)?d[m]:0,O=A.getRoundingRange(!0);if(O){var R=parseFloat(v);p/=O,(R/=O)==1&&(R=0);var U=Math.floor(p);p=(p-U).toFixed(2)>R?U+1:U,p*=O,R==0&&(v=0),p+=parseFloat(v)}return p},getRoundingRange:function(p){p===void 0&&(p=!1);var m=boostPFSAppConfig.general.current_currency.toLowerCase().trim(),d=c.a.getSettingValue("currencyRoundingRules"),v=d&&m&&d.hasOwnProperty(m)?parseFloat(d[m]):0,O=!1;return v>0&&[.25,.5,.75,.9,.95,.99,1,25,50,75,90,95,99,100,250,500,750,900,950,999,1e3].indexOf(v)!=-1&&(O=.99,v>100?O=999:v>10?O=99:v>1&&(O=9),p&&(O=v>1?O+1:O+.01)),O},convertPriceBasedOnActiveCurrency:function(p,m){if(m===void 0&&(m=!0),!p||p==0)return p;if(A.isEnableShopifyMultipleCurrencies()){var d=p*Shopify.currency.rate;p=m?A.roundedPrice(d):d}return parseFloat(p)},convertPriceBasedOnPresentmentPrice:function(p){var m=c.a.getSettingValue("general.currencies");if(m!==void 0&&m.length>1){var d=c.a.getSettingValue("general.current_currency").toLowerCase().trim();["price_min","price_max","compare_at_price_min","compare_at_price_max"].forEach(function(v){var O=v+"_"+d;p[O]!==void 0&&(p[v]=p[O])})}},revertPriceToDefaultCurrency:function(p,m){if(!p||p==0)return p;if(A.isEnableShopifyMultipleCurrencies()){if(p=A.roundedPrice(p),m){var d=A.getRoundingRange();d&&(p-=d)}return(p/=Shopify.currency.rate).toFixed(8)}return p},reBuildUrlBaseOnLocale:function(p){p=p.replace("https://","").replace("http://","");var m=c.a.getSettingValue("general.current_locale"),d=c.a.getSettingValue("general.published_locales"),v=Object.keys(d);if(v.indexOf(m)<0||d[m]==1)return p;var O=p.split("/");return O.length>1&&v.length&&m.length&&(v.indexOf(O[1])>-1?O[1]=m:O.splice(1,0,m)),O.join("/")},getWindowLocation:function(){for(var p=window.location.href.replace(/%3C/g,"<").replace(/%3E/g,">"),m=[],d=0;d1&&(O=R.split("?")[1]).length>0&&(O="?"+O),{pathname:window.location.pathname,href:v,search:O}},setWindowLocation:function(p){window.location.href=p},isBadUrl:function(p){try{p||(p=A.getWindowLocation().search);var m=decodeURIComponent(p).split("&"),d=!1;if(m.length>0)for(var v=0;v/g)||[]).length,G=(O.match(/alert\(/g)||[]).length,K=(O.match(/execCommand/g)||[]).length;if(R>0&&U>0||R>1||U>1||G||K){d=!0;break}}return d}catch(Y){return!0}},InstantSearch:f,isFullWidthMobile:f.isFullWidthMobile,isStyle2:f.isStyle2,FilterTree:P,checkExistFilterOptionParam:P.checkExistFilterOptionParam,encodeURIParamValue:P.encodeURIParamValue,FilterResult:w,buildProductItemUrl:w.buildProductItemUrl,buildProductItemVendorUrl:w.buildProductItemVendorUrl,removePageParamFromUrl:w.removePageParamFromUrl,removeCollectionScopeParamFromUrl:w.removeCollectionScopeParamFromUrl,buildToolbarLink:w.buildToolbarLink,isDefaultPaginationType:w.isDefaultPaginationType,isLoadMorePaginationType:w.isLoadMorePaginationType,isInfiniteLoadingPaginationType:w.isInfiniteLoadingPaginationType,isLoadPreviousPagePaginationType:w.isLoadPreviousPagePaginationType,getSortingList:w.getSortingList,getDefaultSorting:w.getDefaultSorting,getProductMetafield:w.getProductMetafield,isNoFilterResult:w.isNoFilterResult,compileShopifyProductVariables:w.compileShopifyProductVariables,compileShopifyProductMetafield:w.compileShopifyProductMetafield},E=z.a=A},112:function(J,z,l){"use strict";l(14),l(15),l(16),l(26),l(23),l(10),l(17),l(18),l(11),l(21),l(13),l(22),l(20),l(24),l(12);var N=l(2),h=l.n(N),c=l(9),g=l(4),f=l(113),P=l(80),H=l(114),b=l(115),$=l(19),V=l(116),x=l(0);function w(S){return(w=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(D){return typeof D}:function(D){return D&&typeof Symbol=="function"&&D.constructor===Symbol&&D!==Symbol.prototype?"symbol":typeof D})(S)}function _(S,D){for(var L=0;L{{dymContent}}
\n '.trim();default:return'\n "+p+"
").text();for(var m=j().split(" "),d=0;d\n
\n '.trim()}}},{key:"compileTemplate",value:function(){if(!(this.status=="active"&&this.isShow||this._isShowDYM()))return"";var p;switch(this.type){case $.a.ResultType.SUGGESTIONS:p=x.a.getSettingValue("label.suggestion.instantSearchSuggestionsLabel");break;case $.a.ResultType.COLLECTIONS:p=x.a.getSettingValue("label.suggestion.instantSearchCollectionsLabel");break;case $.a.ResultType.PRODUCTS:p=x.a.getSettingValue("label.suggestion.instantSearchProductsLabel");break;case $.a.ResultType.PAGES:p=x.a.getSettingValue("label.suggestion.instantSearchPagesLabel");break;case $.a.ResultType.NO_RESULT_SUGGESTIONS:p=x.a.getSettingValue("search.suggestionNoResult.search_terms.label");break;case $.a.ResultType.NO_RESULT_PRODUCTS:p=x.a.getSettingValue("search.suggestionNoResult.products.label");break;case $.a.ResultType.RECENT_SEARCHES:p=x.a.getSettingValue("search.searchBoxOnclick.recentSearch.label");break;case $.a.ResultType.DEFAULT_SUGGESTIONS:p=x.a.getSettingValue("search.searchBoxOnclick.searchTermSuggestion.label");break;case $.a.ResultType.DEFAULT_PRODUCTS:p=x.a.getSettingValue("search.searchBoxOnclick.productSuggestion.label");break;default:p=this.label}return p||(p=this.label),this.getTemplate().replace(/{{type}}/g,this.type).replace(/{{label}}/g,p).replace(/{{class.searchSuggestionHeader}}/g,g.a.searchSuggestionHeader).replace(/{{class.searchSuggestionGroup}}/g,g.a.searchSuggestionGroup).replace(/{{resultItems}}/g,"")}},{key:"render",value:function(){var p=this;this.$element=h()(this.compileTemplate()),this.type&&this.type===$.a.ResultType.PRODUCTS&&(this.blockDym.render(),this.blockDym.bindEvents(),this.blockDym.$element&&(this.$element=h()(this.compileTemplate()),this.$element.find(" ul").append(this.blockDym.$element))),this.children.forEach(function(m){m.$element&&p.$element.find(" ul").append(m.$element)})}},{key:"_isShowDYM",value:function(){return this.isShowDYM&&this.type==$.a.ResultType.PRODUCTS}},{key:"setData",value:function(p,m){this.data=p,this.isAllEmpty=m,this.children.forEach(function(d,v){p&&p.length>v?d.setData(p[v]):d.setData(null)}),this.blockDym&&(this.blockDym.setData(this.parent.data),this.isShowDYM=this.blockDym.isShow),this.isShow=p&&p.length>0}}])&&_(L.prototype,A),E&&_(L,E),D}(c.a);z.a=C},113:function(J,z,l){"use strict";l(14),l(15),l(16),l(10),l(17),l(18),l(11),l(21),l(13),l(22),l(20),l(12);var N=l(2),h=l.n(N),c=l(1),g=l(3),f=l(4),P=l(40),H=l(57),b=l(19);function $(j){return($=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(k){return typeof k}:function(k){return k&&typeof Symbol=="function"&&k.constructor===Symbol&&k!==Symbol.prototype?"symbol":typeof k})(j)}function V(j,k){for(var C=0;C- \n
- {{label}} \n {{resultItems}}\n
{{content}}
\n '.trim();default:return'\n{{dymContent}}
\n '.trim()}}},{key:"compileTemplate",value:function(){var A=this;if(this.isShow){var E="";this.dymList!=""&&this.dymList.length>0&&this.dymList.forEach(function(U,G){var K="/search?"+H.a.searchTermKey+"="+f.a.encodeURIParamValue(U);E+=A.getTemplate(C.tempType.LINK).replace(/{{url}}/g,K).replace(/{{content}}/g,U),G\n
\n '.trim()}},{key:"compileTemplate",value:function(){return this.getTemplate().replace(/{{class.searchSuggestionLoading}}/g,g.a.searchSuggestionLoading)}},{key:"isRender",value:function(){return f.a.getSettingValue("search.showSuggestionLoading")}},{key:"render",value:function(){this.$element=h()(this.compileTemplate())}}])&&H(I.prototype,j),k&&H(I,k),_}(c.a);z.a=x},119:function(J,z,l){"use strict";l(14),l(15),l(16),l(10),l(17),l(18),l(11),l(21),l(13),l(22),l(53),l(20),l(12);var N=l(2),h=l.n(N),c=l(4),g=l(8),f=l(1),P=l(3),H=l(19),b=l(64);function $(j){return($=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(k){return typeof k}:function(k){return k&&typeof Symbol=="function"&&k.constructor===Symbol&&k!==Symbol.prototype?"symbol":typeof k})(j)}function V(j,k){for(var C=0;C- \n
- \n \n \n
- \n \n \n
- \n \n \n
{{content}}
\n '.trim()}},{key:"getNoResultSearchTemplate",value:function(){return'\n \n '.trim()}},{key:"render",value:function(){this._catchError(),this.totalProduct>0&&(this.settings.loadProductFromLiquid?this.buildProductListDataFromLiquid():this.buildProductList())}},{key:"bindEvents",value:function(){var t=b.a.isSearchPage()||b.a.isCollectionPage(),n=b.a.isiOS()&&c.a.getSettingValue("general.paginationType")=="default";t&&!n&&this.settings.enableKeepScrollbackPosition&&this._bindKeepScrollbackPositionEvent()}},{key:"setData",value:function(t){var n=this;if(this.data=t,this.totalProduct=this.parent.totalProduct,this.prepareProductData(),this.eventType=this.parent.eventType,this.eventInfo=this.parent.eventInfo,this.children=[],this.productItems=[],this.ajaxPage=0,this.totalProduct>0){var s=this._getProductItemClass();t.forEach(function(u,T){var M=new s;n.addComponent(M),M.setData(u,T),n.productItems.push(M)})}}},{key:"_getProductItemClass",value:function(){switch(f.a.queryParams.display){case e.Enum.itemStyle.LIST:return K;case e.Enum.itemStyle.COLLAGE:return de;default:return d}}},{key:"buildProductListDataFromLiquid",value:function(){b.a.isDefaultPaginationType()||this.eventType!="page"||h()(window).off("scroll"),this.settings.loadProductFromLiquidType==e.Enum.loadProductType.SYNC?this._getProductListHtmlBySync():this._getProductListHtmlByAjax()}},{key:"prepareProductData",value:function(){var t=this,n=this.data;return Array.isArray(n)?(n.forEach(function(s){var u=[];s.options_with_values.forEach(function(q){u.push(q.name)}),s.options=u;var T=!0;if(s.variants&&s.variants.length>0){var M=s.variants[0];M.hasOwnProperty("fulfillment_service")&&M.fulfillment_service=="gift_card"&&(T=!1)}b.a.isEnableShopifyMultipleCurrencies()&&(b.a.isConvertCurrenciesOnFrontEnd()?(s.price_min=b.a.convertPriceBasedOnActiveCurrency(s.price_min,T),s.price_max=b.a.convertPriceBasedOnActiveCurrency(s.price_max,T),s.compare_at_price_min=b.a.convertPriceBasedOnActiveCurrency(s.compare_at_price_min,T),s.compare_at_price_max=b.a.convertPriceBasedOnActiveCurrency(s.compare_at_price_max,T)):b.a.convertPriceBasedOnPresentmentPrice(s)),s.variants.forEach(function(q){var Z=[],Q=q.merged_options;if(Array.isArray(Q)){for(var ee=0;ee