PageSourceSearch

https://oralefoods.com/cdn/shop/t/6/assets/theme.js?v=60479426504909131751544469251

js oralefoods.com collected 2026-10-09 21:26:37 UTC 104,682 bytes, 18 lines download raw bytes

1var ImageZoom,Product,extend=function(child,parent){for(var key in parent)hasProp.call(parent,key)&&(child[key]=parent[key]);function ctor(){this.constructor=child}return ctor.prototype=parent.prototype,child.prototype=new ctor,child.__super__=parent.prototype,child},hasProp={}.hasOwnProperty,slice=[].slice,bind=function(fn,me){return function(){return fn.apply(me,arguments)}};window.BlogView=(function(superClass){extend(BlogView2,superClass);function BlogView2(){return BlogView2.__super__.constructor.apply(this,arguments)}return BlogView2.prototype.initialize=function(){return this.sectionBinding(),this.render()},BlogView2.prototype.render=function(){if(this.grid=this.$("[data-blog]"),this.grid.length)return this.initializeMasonryGrid()},BlogView2.prototype.sectionBinding=function(){return this.$el.on("shopify:section:load",(function(_this){return function(){return _this.delegateEvents(),_this.render()}})(this)),this.$el.on("shopify:section:unload",(function(_this){return function(){return _this.undelegateEvents()}})(this))},BlogView2.prototype.initializeMasonryGrid=function(){return this.grid.masonry({itemSelector:"[data-article-item]",columnWidth:".article-grid-sizer",gutter:".article-gutter-sizer",percentPosition:!0}),this.grid.imagesLoaded().progress((function(_this){return function(instance,image){return _this.grid.data("masonry").layout()}})(this))},BlogView2})(Backbone.View),window.ProductListView=(function(superClass){extend(ProductListView2,superClass);function ProductListView2(){return ProductListView2.__super__.constructor.apply(this,arguments)}return ProductListView2.prototype.events={"preload-images":"preloadImages"},ProductListView2.prototype.initialize=function(){return this.preloadImages()},ProductListView2.prototype.preloadImages=function(e,imageWrap){var j,len,ref,results;for(ref=this.$(".product-item-image"),results=[],j=0,len=ref.length;j<len;j++)imageWrap=ref[j],results.push(this.showImage(imageWrap));return results},ProductListView2.prototype.showImage=function(imageWrap){var image;return imageWrap=$(imageWrap),image=imageWrap.find("img"),imageWrap.imagesLoaded((function(_this){return function(){if(image.height()<100)return imageWrap.find(".product-details-overlay").addClass("landscape")}})(this))},ProductListView2})(Backbone.View),window.CollectionView=(function(superClass){extend(CollectionView2,superClass);function CollectionView2(){return CollectionView2.__super__.constructor.apply(this,arguments)}return CollectionView2.prototype.events={"click .click-to-load-button":"loadNewProducts","change .collection-sort-filter select":"updateSortFilter","change .collection-tag-filter select":"updateTagFilter"},CollectionView2.prototype.initialize=function(){return this.productListView=null,this.$productList=null,this.setQueryParams(),this.sectionBinding(),this.render()},CollectionView2.prototype.render=function(){if(this.productListView=new ProductListView({el:this.$(".collection-content")}),this.$productList=this.$(".product-list"),this.$(".collection-tag-filter").length&&new SelectView({el:this.$(".collection-tag-filter select")}),this.$(".collection-sort-filter").length&&new SelectView({el:this.$(".collection-sort-filter select")}),this.$("#content").hasClass("has-pagination")&&(this.$("#content").hasClass("click-to-load")||this.$("#content").hasClass("infinite-scroll")))return this.initializeInfiniteScroll()},CollectionView2.prototype.remove=function(){return this.$productList.infinitescroll("destroy")},CollectionView2.prototype.sectionBinding=function(){return this.$el.on("shopify:section:load",(function(_this){return function(){return _this.delegateEvents(),_this.render()}})(this)),this.$el.on("shopify:section:unload",(function(_this){return function(){return _this.remove(),_this.$productList=null,_this.productListView.remove(),_this.undelegateEvents()}})(this))},CollectionView2.prototype.initializeInfiniteScroll=function(){var behavior;return this.clickToLoad=this.$(".click-to-load-button"),this.section=JSON.parse($("[data-section-json]",this.$el).text()),this.paginateMethod=this.section.products_pagination_method,this.currentProductsCount=this.$(".product-item").length,this.paginateMethod==="click-to-load"?behavior="twitter":behavior="",this.$productList.infinitescroll({behavior:behavior,navSelector:"#pagination",nextSelector:"#pag-next a",itemSelector:".product-item",loading:{finishedMsg:"",img:"",msg:null,msgText:"",selector:null,speed:"fast",start:void 0,bufferPx:200}},(function(_this){return function(newProducts){return _this.onProductsLoad(newProducts)}})(this))},CollectionView2.prototype.onProductsLoad=function(newProducts){var ref;return this.$productList.trigger("preload-images",[newProducts]),Theme.currencySwitcher&&$(".currency-switcher select").trigger("reset-currency"),this.currentProductsCount=this.currentProductsCount+$(newProducts).length,this.currentProductsCount===parseInt(this.$productList.data("product-count"))&&(this.clickToLoad.hide(),this.$(".collection-content").addClass("no-pagination")),(ref=Shopify.PaymentButton)!=null&&ref.init(),$(".product-item",this.$productList).each(function(){return rimg.shopify.watch(this)})},CollectionView2.prototype.loadNewProducts=function(e){return this.$productList.infinitescroll("retrieve")},CollectionView2.prototype.setQueryParams=function(){var aCouples,aKeyValue,i,j,ref,results;if(Shopify.queryParams={},location.search.length){for(aKeyValue=void 0,aCouples=location.search.substr(1).split("&"),results=[],i=j=0,ref=aCouples.length-1;0<=ref?j<=ref:j>=ref;i=0<=ref?++j:--j)aKeyValue=aCouples[i].split("="),aKeyValue.length>1&&aKeyValue[0]!=="page"?results.push(Shopify.queryParams[decodeURIComponent(aKeyValue[0])]=decodeURIComponent(aKeyValue[1])):results.push(void 0);return results}},CollectionView2.prototype.updateSortFilter=function(e){var Sorting,currentSearch,index,j,len,part,search,searchParts;if(Sorting={},Sorting.sort_by=this.$(".collection-sort-filter select").val(),$(e.target).closest(".collection-sorting").hasClass("vendor-collection")){for(currentSearch=location.search,searchParts=currentSearch.split("&"),index=j=0,len=searchParts.length;j<len;index=++j)part=searchParts[index],part.indexOf("sort_by")!==-1&&searchParts.splice(index,1);return search=searchParts.join("&"),location.search=search+"&"+jQuery.param(Sorting)}else return location.search=jQuery.param(Sorting)},CollectionView2.prototype.updateTagFilter=function(e){var collection,tag;
1return collection=$(e.target).data("collection"),tag=$(e.target).val(),tag==="all"?window.location.href="/collections/"+collection+"?"+$.param(Shopify.queryParams):window.location.href="/collections/"+collection+"/"+tag+"?"+$.param(Shopify.queryParams)},CollectionView2})(Backbone.View),window.CurrencyView=(function(superClass){extend(CurrencyView2,superClass);function CurrencyView2(){return CurrencyView2.__super__.constructor.apply(this,arguments)}return CurrencyView2.prototype.events={"change [name=currencies]":"switchCurrency","switch-currency":"switchCurrency","reset-currency":"switchCurrency"},CurrencyView2.prototype.initialize=function(){return this.sectionBinding(),this.render()},CurrencyView2.prototype.sectionBinding=function(){return this.$el.on("shopify:section:load",(function(_this){return function(){return _this.delegateEvents(),_this.render()}})(this)),this.$el.on("shopify:section:unload",(function(_this){return function(){return _this.undelegateEvents()}})(this))},CurrencyView2.prototype.render=function(){var doubleMoney,j,l,len,len1,money,newCurrency,ref,ref1;for(this.$currencySwitcher=this.$("[name=currencies]"),Currency.format=Theme.currencySwitcherFormat,Currency.money_with_currency_format={},Currency.money_with_currency_format[Theme.currency]=Theme.moneyFormatCurrency,Currency.money_format={},Currency.money_format[Theme.currency]=Theme.moneyFormat,newCurrency=Currency.cookie.read(),newCurrency&&this.$currencySwitcher.find("option[value="+newCurrency+"]")?Currency.currentCurrency=newCurrency:Theme.defaultCurrency?(Currency.currentCurrency=Theme.defaultCurrency,Currency.cookie.write(Theme.defaultCurrency)):(Currency.currentCurrency=Theme.currency,Currency.cookie.write(Theme.currency)),this.$currencySwitcher.val(Currency.currentCurrency),ref=this.$("span.money span.money"),j=0,len=ref.length;j<len;j++)doubleMoney=ref[j],$(doubleMoney).parents("span.money").removeClass("money");for(ref1=this.$("span.money"),l=0,len1=ref1.length;l<len1;l++)money=ref1[l],$(money).attr("data-currency-"+Theme.currency,$(money).html());return this.switchCurrency()},CurrencyView2.prototype.switchCurrency=function(e){var $money,$switcher,j,len,money,newCurrency,ref;for($switcher=this.$currencySwitcher,newCurrency=$switcher.val(),e!==void 0&&($switcher=$(e.currentTarget),$switcher!==void 0&&($switcher!=null?$switcher.attr("name"):void 0)==="currencies"&&(this.$currencySwitcher.val($switcher.val()),newCurrency=$switcher.val())),(newCurrency===null||newCurrency==="")&&(newCurrency=Theme.currency),ref=$("span.money"),j=0,len=ref.length;j<len;j++)money=ref[j],$money=$(money),$(money).attr("data-currency-"+Theme.currency)||$(money).attr("data-currency-"+Theme.currency,$(money).html()),$money.html($money.attr("data-currency-"+Theme.currency)),$money.attr("data-currency",Theme.currency);return Currency.convertAll(Theme.currency,newCurrency),Currency.currentCurrency=newCurrency,Currency.cookie.write(newCurrency),this.$(".selected-currency").text(Currency.currentCurrency)},CurrencyView2})(Backbone.View),window.GiftCardView=(function(superClass){extend(GiftCardView2,superClass);function GiftCardView2(){return GiftCardView2.__super__.constructor.apply(this,arguments)}return GiftCardView2.prototype.initialize=function(){return this.addQrCode()},GiftCardView2.prototype.addQrCode=function(){var qrWrapper;return qrWrapper=$("[data-qr-code]"),new QRCode(qrWrapper[0],{text:qrWrapper.data("qr-code"),width:120,height:120})},GiftCardView2})(Backbone.View),window.NavigationView=(function(superClass){extend(NavigationView2,superClass);function NavigationView2(){return NavigationView2.__super__.constructor.apply(this,arguments)}return NavigationView2.prototype.events={"click .navigation-desktop .dropdown > a":"toggleMenu","click .navigation-mobile .dropdown > a":"toggleMenu","click .mobile-nav-item.navigate > a":"toggleMobileNav","click .mobile-nav-item.browse > a":"toggleMobileSearch","click .mobile-nav-item > a":"toggleMobileNavItemsFadeStatus"},NavigationView2.prototype.initialize=function(){return this.body=$(document.body),this.desktopNav=this.$("[data-desktop-nav]")},NavigationView2.prototype.toggleMenu=function(e){var a,dropdown,handle,megaDropdown,megaMenuHeight;if(a=this.$(e.currentTarget),dropdown=a.parent(".dropdown"),handle=dropdown.data("handle"),megaDropdown=a.parent(".nav-item-meganav"),this.$megaMenus=this.$(".navigation-desktop-mega"),this.$megaMenu=this.$('.navigation-desktop-mega[data-parent="'+handle+'"]'),megaMenuHeight=this.$megaMenu.outerHeight(),!(dropdown.hasClass("active")||megaDropdown.hasClass("active")))return e.preventDefault(),dropdown.toggleClass("active"),dropdown.siblings(".dropdown").removeClass("active"),dropdown.find(".dropdown-nav .dropdown").removeClass("active"),this.$megaMenus.removeClass("active").css("height",""),megaDropdown.hasClass("active")?this.$megaMenu.toggleClass("active").css("height",megaMenuHeight):this.$megaMenu.removeClass("active").css("height",""),$(window).resize((function(_this){return function(){if(document.documentElement.offsetWidth<768&&megaDropdown.hasClass("active"))return _this.$megaMenus.removeClass("active"),dropdown.toggleClass("active")}})(this)).trigger("resize"),this.adjustSimpleNavPosition()},NavigationView2.prototype.adjustSimpleNavPosition=function(){var item,itemOffset,j,len,navWidth,ref,results;for(navWidth=this.desktopNav.width(),ref=this.$(".navigation-desktop > .dropdown"),results=[],j=0,len=ref.length;j<len;j++)item=ref[j],this.$item=$(item),this.$item.hasClass("nav-item-meganav")?results.push(void 0):(itemOffset=this.$item.offset(),this.$item.find(".second-tier").length&&itemOffset.left+218>navWidth&&$(window).width()<navWidth+436?this.$item.find(".second-tier").addClass("adjust-right"):this.$item.find(".second-tier").length&&this.$item.find(".second-tier").removeClass("adjust-right"),this.$item.find(".third-tier").length&&itemOffset.left+436>navWidth&&$(window).width()<navWidth+872?results.push(this.$item.find(".third-tier").addClass("adjust-right")):this.$item.find(".third-tier").length?results.push(this.$item.find(".third-tier").removeClass("adjust-right")):results.push(void 0));return results},NavigationView2.prototype.toggleMobileNav=function(e){return this.$(".navigation-mobile-list").toggleClass("active"),this.$(".mobile-browse-container").removeClass("active")},NavigationView2.prototype.toggleMobileSearch=function(e){return this.$(".mobile-browse-container").toggleClass("active"),this.$(".navigation-mobile-list").removeClass("active")},NavigationView2.prototype.toggleMobileNavItemsFadeStatus=function(e){var navItems,target;return navItems=this.$(".mobile-nav-item"),target=$(e.target).closest(navItems),target.hasClass("active")?(navItems.removeClass("fade"),target.removeClass("active")):(navItems.not(target).addClass("fade"),target.addClass("active").removeClass("fade"))},NavigationView2})(Backbone.View),window.HeaderView=(function(superClass){extend(HeaderView2,superClass);function HeaderView2(){return HeaderView2.__super__.constructor.apply(this,arguments)}return HeaderView2.prototype.events={"click .search-toggle-button":"toggleSearch","change .shop-by-category, .shop-by-vendor":"fireSearchSelect"},HeaderView2.prototype.initialize=function(){return this.navigation=new NavigationView({el:this.$el}),$(document.body).on("click",(function(_this){return function(e){if(!_this.$(e.target).closest(".search-toggle-button").length)return _this.$(".search-toggle-button").removeClass("open")}})(this))},HeaderView2.prototype.toggleSearch=function(e){return this.$(".search-toggle-button").hasClass("open")&&this.$(e.target).hasClass("search-browse-parent-outline")?this.$(".search-toggle-button").removeClass("open"):(this.$(".search-browse-container").css({top:$(".search-browse-parent-outline").height()}),this.$(".search-toggle-button").addClass("open"))},HeaderView2.prototype.fireSearchSelect=function(e){var target;if(target=this.$(e.target),target.val().length)return window.location=target.val()},HeaderView2.prototype.prepareRemove=function(){return this.navigation.remove()},HeaderView2})(Backbone.View),window.SlideshowView=(function(superClass){extend(SlideshowView2,superClass);function SlideshowView2(){return SlideshowView2.__super__.constructor.apply(this,arguments)}return SlideshowView2.prototype.initialize=function(){return this.flickity=null,this._val
1idate()},SlideshowView2.prototype.update=function($el){if(this.$el=$el,this.flickity==null)return this._validate()},SlideshowView2.prototype.remove=function(){this.$slideshow.flickity("destroy")},SlideshowView2.prototype.onBlockSelect=function(event){var $slideIndex,$slides;if($slides=$("[data-slideshow-slide]",this.$el),$slideIndex=$slides.index(event.target),this.$slideshow)return this.$slideshow.flickity("select",$slideIndex,!1,!1),this.$slideshow.flickity("pausePlayer")},SlideshowView2.prototype.onBlockDeselect=function(event){return this.$slideshow.flickity("unpausePlayer")},SlideshowView2.prototype._validate=function(){var autoplay,slideCount;return this.$slideshow=$("[data-slideshow]",this.$el),this.$slideshowContents=$("[data-slide-contents]",this.$el),slideCount=this.$slideshow.data("slideshow-slides"),autoplay=this.$slideshow.data("autoplay"),this._setupSlideshow(slideCount,autoplay)},SlideshowView2.prototype._setupSlideshow=function(slideCount,autoplay){var originalSelect,slideshowNavigation;return slideshowNavigation=!0,slideCount===1&&(slideshowNavigation=!1),Flickity.prototype.setGallerySize=function(){var height;if(this.options.setGallerySize)return height=this.maxCellHeight,this.options.adaptiveHeight&&this.selectedCell&&(height=this.selectedCell.size.outerHeight),this.viewport.style.height=height+"px"},originalSelect=Flickity.prototype.select,Flickity.prototype.select=function(){if(originalSelect.apply(this,arguments),this.options.adaptiveHeight)return this.setGallerySize()},this.$slideshow.flickity({imagesLoaded:!0,autoPlay:autoplay,pageDots:!1,prevNextButtons:slideshowNavigation,contain:!0,cellSelector:".slide",wrapAround:!0,resize:!0,adaptiveHeight:!0}),this.flickity=this.$slideshow.data("flickity"),this.$viewPort=this.$slideshow.find(".flickity-viewport"),this.$slide=this.$slideshow.find(".slide"),this.$slideshow.on("cellSelect",(function(_this){return function(){var index;return index=_this.flickity.selectedIndex,_this.$slideshowContents.removeClass("slide-contents-visible"),_this.$slideshowContents.filter('[data-slide-index="'+index+'"]').addClass("slide-contents-visible"),$(_this.flickity.selectedElement).trigger("theme:rimg:watch")}})(this))},SlideshowView2})(Backbone.View),(function(root,factory){typeof define=="function"&&define.amd?define([],factory):typeof exports=="object"?module.exports=factory():factory()})(this,function(){var domNode="",maxTweets=20,parseLinks=!0,queue=[],inProgress=!1,printTime=!0,printUser=!0,formatterFunction=null,supportsClassName=!0,showRts=!0,customCallbackFunction=null,showInteractionLinks=!0,showImages=!1,useEmoji=!1,targetBlank=!0,lang="en",permalinks=!0,dataOnly=!1,script=null,scriptAdded=!1;function handleTweets(tweets){if(customCallbackFunction===null){for(var x=tweets.length,n=0,element=document.getElementById(domNode),html="<ul>";n<x;)html+="<li>"+tweets[n]+"</li>",n++;html+="</ul>",element.innerHTML=html}else customCallbackFunction(tweets)}function strip(data){return data.replace(/<b[^>]*>(.*?)<\/b>/gi,function(a,s){return s}).replace(/class="(?!(tco-hidden|tco-display|tco-ellipsis))+.*?"|data-query-source=".*?"|dir=".*?"|rel=".*?"/gi,"")}function targetLinksToNewWindow(el){for(var links=el.getElementsByTagName("a"),i=links.length-1;i>=0;i--)links[i].setAttribute("target","_blank")}function getElementsByClassName(node,classname){for(var a=[],regex=new RegExp("(^| )"+classname+"( |$)"),elems=node.getElementsByTagName("*"),i=0,j=elems.length;i<j;i++)regex.test(elems[i].className)&&a.push(elems[i]);return a}function extractImageUrl(image_data){if(image_data!==void 0&&image_data.innerHTML.indexOf("data-image")>=0){var data_src=image_data.innerHTML.match(/data-image=\"([A-z0-9]+:\/\/[A-z0-9]+\.[A-z0-9]+\.[A-z0-9]+\/[A-z0-9]+\/[A-z0-9\-]+)/i)[1];return decodeURIComponent(data_src)+".jpg"}}var twitterFetcher2={fetch:function(config){if(config.maxTweets===void 0&&(config.maxTweets=20),config.enableLinks===void 0&&(config.enableLinks=!0),config.showUser===void 0&&(config.showUser=!0),config.showTime===void 0&&(config.showTime=!0),config.dateFunction===void 0&&(config.dateFunction="default"),config.showRetweet===void 0&&(config.showRetweet=!0),config.customCallback===void 0&&(config.customCallback=null),config.showInteraction===void 0&&(config.showInteraction=!0),config.showImages===void 0&&(config.showImages=!1),config.useEmoji===void 0&&(config.useEmoji=!1),config.linksInNewWindow===void 0&&(config.linksInNewWindow=!0),config.showPermalinks===void 0&&(config.showPermalinks=!0),config.dataOnly===void 0&&(config.dataOnly=!1),inProgress)queue.push(config);else{inProgress=!0,domNode=config.domId,maxTweets=config.maxTweets,parseLinks=config.enableLinks,printUser=config.showUser,printTime=config.showTime,showRts=config.showRetweet,formatterFunction=config.dateFunction,customCallbackFunction=config.customCallback,showInteractionLinks=config.showInteraction,showImages=config.showImages,useEmoji=config.useEmoji,targetBlank=config.linksInNewWindow,permalinks=config.showPermalinks,dataOnly=config.dataOnly;var head=document.getElementsByTagName("head")[0];script!==null&&head.removeChild(script),script=document.createElement("script"),script.type="text/javascript",config.list!==void 0?script.src="https://syndication.twitter.com/timeline/list?callback=__twttrf.callback&dnt=false&list_slug="+config.list.listSlug+"&screen_name="+config.list.screenName+"&suppress_response_codes=true&lang="+(config.lang||lang)+"&rnd="+Math.random():config.profile!==void 0?script.src="https://syndication.twitter.com/timeline/profile?callback=__twttrf.callback&dnt=false&screen_name="+config.profile.screenName+"&suppress_response_codes=true&lang="+(config.lang||lang)+"&rnd="+Math.random():config.likes!==void 0?script.src="https://syndication.twitter.com/timeline/likes?callback=__twttrf.callback&dnt=false&screen_name="+config.likes.screenName+"&suppress_response_codes=true&lang="+(config.lang||lang)+"&rnd="+Math.random():script.src="https://cdn.syndication.twimg.com/widgets/timelines/"+config.id+"?&lang="+(config.lang||lang)+"&callback=__twttrf.callback&suppress_response_codes=true&rnd="+Math.random(),head.appendChild(script)}},callback:function(data){if(data===void 0||data.body===void 0){inProgress=!1,queue.length>0&&(twitterFetcher2.fetch(queue[0]),queue.splice(0,1));return}useEmoji||(data.body=data.body.replace(/(<img[^c]*class="Emoji[^>]*>)|(<img[^c]*class="u-block[^>
1]*>)/g,"")),showImages||(data.body=data.body.replace(/(<img[^c]*class="NaturalImage-image[^>]*>|(<img[^c]*class="CroppedImage-image[^>]*>))/g,"")),printUser||(data.body=data.body.replace(/(<img[^c]*class="Avatar"[^>]*>)/g,""));var div=document.createElement("div");div.innerHTML=data.body,typeof div.getElementsByClassName=="undefined"&&(supportsClassName=!1);function swapDataSrc(element){var avatarImg=element.getElementsByTagName("img")[0];return avatarImg&&avatarImg.length&&(avatarImg.src=avatarImg.getAttribute("data-src-2x")),element}var tweets=[],authors=[],times=[],images=[],rts=[],tids=[],permalinksURL=[],x=0;if(supportsClassName)for(var tmp=div.getElementsByClassName("timeline-Tweet");x<tmp.length;)tmp[x].getElementsByClassName("timeline-Tweet-retweetCredit").length>0?rts.push(!0):rts.push(!1),(!rts[x]||rts[x]&&showRts)&&(tweets.push(tmp[x].getElementsByClassName("timeline-Tweet-text")[0]),tids.push(tmp[x].getAttribute("data-tweet-id")),printUser&&authors.push(swapDataSrc(tmp[x].getElementsByClassName("timeline-Tweet-author")[0])),times.push(tmp[x].getElementsByClassName("dt-updated")[0]),permalinksURL.push(tmp[x].getElementsByClassName("timeline-Tweet-timestamp")[0]),tmp[x].getElementsByClassName("timeline-Tweet-media")[0]!==void 0?images.push(tmp[x].getElementsByClassName("timeline-Tweet-media")[0]):images.push(void 0)),x++;else for(var tmp=getElementsByClassName(div,"timeline-Tweet");x<tmp.length;)getElementsByClassName(tmp[x],"timeline-Tweet-retweetCredit").length>0?rts.push(!0):rts.push(!1),(!rts[x]||rts[x]&&showRts)&&(tweets.push(getElementsByClassName(tmp[x],"timeline-Tweet-text")[0]),tids.push(tmp[x].getAttribute("data-tweet-id")),printUser&&authors.push(swapDataSrc(getElementsByClassName(tmp[x],"timeline-Tweet-author")[0])),times.push(getElementsByClassName(tmp[x],"dt-updated")[0]),permalinksURL.push(getElementsByClassName(tmp[x],"timeline-Tweet-timestamp")[0]),getElementsByClassName(tmp[x],"timeline-Tweet-media")[0]!==void 0?images.push(getElementsByClassName(tmp[x],"timeline-Tweet-media")[0]):images.push(void 0)),x++;tweets.length>maxTweets&&(tweets.splice(maxTweets,tweets.length-maxTweets),authors.splice(maxTweets,authors.length-maxTweets),times.splice(maxTweets,times.length-maxTweets),rts.splice(maxTweets,rts.length-maxTweets),images.splice(maxTweets,images.length-maxTweets),permalinksURL.splice(maxTweets,permalinksURL.length-maxTweets));var arrayTweets=[],x=tweets.length,n=0;if(dataOnly)for(;n<x;)arrayTweets.push({tweet:tweets[n].innerHTML,author:authors[n]?authors[n].innerHTML:"Unknown Author",author_data:{profile_url:authors[n]?authors[n].querySelector('[data-scribe="element:user_link"]').href:null,profile_image:authors[n]?authors[n].querySelector('[data-scribe="element:avatar"]').getAttribute("data-src-1x"):null,profile_image_2x:authors[n]?authors[n].querySelector('[data-scribe="element:avatar"]').getAttribute("data-src-2x"):null,screen_name:authors[n]?authors[n].querySelector('[data-scribe="element:screen_name"]').title:null,name:authors[n]?authors[n].querySelector('[data-scribe="element:name"]').title:null},time:times[n].textContent,timestamp:times[n].getAttribute("datetime").replace("+0000","Z").replace(/([\+\-])(\d\d)(\d\d)/,"$1$2:$3"),image:extractImageUrl(images[n]),rt:rts[n],tid:tids[n],permalinkURL:permalinksURL[n]===void 0?"":permalinksURL[n].href}),n++;else for(;n<x;){if(typeof formatterFunction!="string"){var datetimeText=times[n].getAttribute("datetime"),newDate=new Date(times[n].getAttribute("datetime").replace(/-/g,"/").replace("T"," ").split("+")[0]),dateString=formatterFunction(newDate,datetimeText);if(times[n].setAttribute("aria-label",dateString),tweets[n].textContent)if(supportsClassName)times[n].textContent=dateString;else{var h=document.createElement("p"),t=document.createTextNode(dateString);h.appendChild(t),h.setAttribute("aria-label",dateString),times[n]=h}else times[n].textContent=dateString}var op="";parseLinks?(targetBlank&&(targetLinksToNewWindow(tweets[n]),printUser&&targetLinksToNewWindow(authors[n])),printUser&&(op+='<div class="user">'+strip(authors[n].innerHTML)+"</div>"),op+='<p class="tweet">'+strip(tweets[n].innerHTML)+"</p>",printTime&&(permalinks?op+='<p class="timePosted"><a href="'+permalinksURL[n]+'">'+times[n].getAttribute("aria-label")+"</a></p>":op+='<p class="timePosted">'+times[n].getAttribute("aria-label")+"</p>")):(tweets[n].textContent,printUser&&(op+='<p class="user">'+authors[n].textContent+"</p>"),op+='<p class="tweet">'+tweets[n].textContent+"</p>",printTime&&(op+='<p class="timePosted">'+times[n].textContent+"</p>")),showInteractionLinks&&(op+='<p class="interact"><a href="https://twitter.com/intent/tweet?in_reply_to='+tids[n]+'" class="twitter_reply_icon"'+(targetBlank?' target="_blank">':">")+'Reply</a><a href="https://twitter.com/intent/retweet?tweet_id='+tids[n]+'" class="twitter_retweet_icon"'+(targetBlank?' target="_blank">':">")+'Retweet</a><a href="https://twitter.com/intent/favorite?tweet_id='+tids[n]+'" class="twitter_fav_icon"'+(targetBlank?' target="_blank">':">")+"Favorite</a></p>"),showImages&&images[n]!==void 0&&extractImageUrl(images[n])!==void 0&&(op+='<div class="media"><img src="'+extractImageUrl(images[n])+'" alt="Image from tweet" /></div>'),(showImages||!showImages&&tweets[n].textContent.length)&&arrayTweets.push(op),n++}handleTweets(arrayTweets),inProgress=!1,queue.length>0&&(twitterFetcher2.fetch(queue[0]),queue.splice(0,1))}};return window.__twttrf=twitterFetcher2,window.twitterFetcher=twitterFetcher2,twitterFetcher2}),window.TwitterView=(function(superClass){extend(TwitterView2,superClass);function TwitterView2(){return TwitterView2.__super__.constructor.apply(this,arguments)}return TwitterView2.prototype.initialize=function(){return this.initializedClass="twitter-initialized",this._val
1idate()},TwitterView2.prototype._validate=function(){var isInitialized,showRetweets,username;return this.$tweetContainer=this.$("[data-twitter-tweets]",this.$el),username=$("[data-twitter-username]",this.$el).attr("data-twitter-username"),showRetweets=$("[data-twitter-show-retweets]",this.$el).length,isInitialized=this.$el.hasClass(this.initializedClass),this._fetchTweets(username,showRetweets,isInitialized)},TwitterView2.prototype._fetchTweets=function(username,showRetweets,isInitialized){var config;if(!username.length)return this._hasError(!1);if(!isInitialized)return config={profile:{screenName:username},maxTweets:3,enableLinks:!0,showUser:!0,showTime:!0,showRetweet:showRetweets,customCallback:(function(_this){return function(tweets){return _this._renderTweets(tweets)}})(this),showInteraction:!1,useEmoji:!0},twitterFetcher.fetch(config)},TwitterView2.prototype._renderTweets=function(tweets){var j,len,results,tweet,tweetWrapper;if(tweetWrapper=$("[data-tweet]"),tweets.length){for(results=[],j=0,len=tweets.length;j<len;j++)tweet=tweets[j],tweetWrapper.append("<div class='twitter-tweet'>"+tweet+"</div>"),tweetWrapper.find(".user").remove(),results.push(tweetWrapper.find(".timePosted").addClass("accent-text").appendTo());return results}else return this.$tweetContainer.remove(),console.log("No tweets to display. Most probable cause is an incorrectly entered username.")},TwitterView2.prototype._hasError=function(response){if(this.$el.toggleClass(this.initializedClass,!1),this.$tweetContainer.html(),response)return console.log("Twitter error: "+response.meta.error_message)},TwitterView2.prototype.update=function(){return this._validate()},TwitterView2})(Backbone.View),window.InstagramView=(function(superClass){extend(InstagramView2,superClass);function InstagramView2(){return InstagramView2.__super__.constructor.apply(this,arguments)}return InstagramView2.prototype.initialize=function(){return this.initializedClass="instagram-initialized",this._validate()},InstagramView2.prototype._validate=function(){var accessToken,isInitialized,photoCount;return this.$photoContainer=this.$("[data-instagram-photos]",this.$el),this.accessTokenError=this.$el.find("[data-instagram-error]").attr("data-instagram-error"),accessToken=$("[data-instagram-token]",this.$el).attr("data-instagram-token"),photoCount=$("[data-instagram-photo-count]",this.$el).attr("data-instagram-photo-count"),isInitialized=this.$el.hasClass(this.initializedClass),this._getPhotos(accessToken,photoCount,isInitialized)},InstagramView2.prototype._getPhotos=function(accessToken,photoCount,isInitialized){var url;if(!accessToken.length)return this._hasError(!1);if(!isInitialized)return url="https://api.instagram.com/v1/users/self/media/recent?access_token="+accessToken+"&count="+photoCount+"&callback=",$.ajax({type:"GET",dataType:"jsonp",url:url,success:(function(_this){return function(response){var j,len,photo,ref,ref1,ref2,ref3,ref4,results;if(response.meta.code===200){for(_this.$photoContainer.empty(),ref=response.data,results=[],j=0,len=ref.length;j<len;j++)photo=ref[j],photo!=null&&(ref1=photo.images)!=null&&(ref2=ref1.standard_resolution)!=null&&ref2.url?results.push(_this.$photoContainer.append('<a\n  class="instagram-photo"\n  href="'+photo.link+'"\n  target="_blank"\n  style="background-image: url(\''+(photo!=null&&(ref3=photo.images)!=null&&(ref4=ref3.standard_resolution)!=null?ref4.url:void 0)+"')\"\n>\n</a>")):results.push(void 0);return results}else return _this._hasError(response)}})(this),error:(function(_this){return function(response){return _this._hasError(response)}})(this)})},InstagramView2.prototype._hasError=function(response){if(this.$el.removeClass(this.initializedClass),this.$photoContainer.append('<div class="instagram-error" data-instagram-error>'+this.accessTokenError+"</div>"),this.$errorContainer=this.$photoContainer.find("[data-instagram-errror]"),response)return console.log("Instagram error: "+response.meta.error_message)},InstagramView2.prototype.update=function(){return this._validate()},InstagramView2})(Backbone.View),window.SocialWidgetsView=(function(superClass){extend(SocialWidgetsView2,superClass);function SocialWidgetsView2(){return SocialWidgetsView2.__super__.constructor.apply(this,arguments)}return SocialWidgetsView2.prototype.initialize=function(){if($("[data-instagram]",this.$el).length&&(this.instagram=new InstagramView({el:this.$el})),$("[data-twitter]",this.$el).length)return this.twitter=new TwitterView({el:this.$el})},SocialWidgetsView2.prototype.update=function($el){if(this.instagram!=null&&(this.instagram.setElement($el),this.instagram.update(
1)),this.twitter!=null)return this.twitter.setElement($el),this.twitter.update()},SocialWidgetsView2.prototype.remove=function(){var ref,ref1;return(ref=this.instagram)!=null&&ref.remove(),(ref1=this.twitter)!=null?ref1.remove():void 0},SocialWidgetsView2})(Backbone.View),window.HomeView=(function(superClass){extend(HomeView2,superClass);function HomeView2(){return HomeView2.__super__.constructor.apply(this,arguments)}return HomeView2.prototype.initialize=function(){return this.sectionBinding()},HomeView2.prototype.sectionBinding=function(){return this.sections=new ThemeEditor,this.sections.register("home-slideshow",this.slideshow(this.sections)),this.sections.register("featured-products",this.featuredProduct(this.sections)),this.sections.register("home-social-widgets",this.socialWidgets(this.sections))},HomeView2.prototype.slideshow=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new SlideshowView({el:instance.$container})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),this.instances[instance.sectionId]==null)return this.init(instance)},onSectionSelect:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null?ref.update(instance.$container):void 0},onSectionDeselect:function(event){return this.onSectionSelect(event)},onBlockSelect:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null?ref.onBlockSelect(event):void 0},onBlockDeselect:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null?ref.onBlockDeselect(event):void 0},onSectionUnload:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null&&ref.remove(),delete this.instances[instance.sectionId]}}},HomeView2.prototype.featuredProduct=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new ProductListView({el:instance.$container})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),this.instances[instance.sectionId]==null)return this.init(instance)},onSectionSelect:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null?ref.setElement(instance.$container):void 0},onSectionUnload:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null&&ref.remove(),delete this.instances[instance.sectionId]}}},HomeView2.prototype.socialWidgets=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new SocialWidgetsView({el:instance.$container})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),this.instances[instance.sectionId]==null)return this.init(instance)},onSectionDeselect:function(event){var instance,ref,ref1;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null&&ref.setElement(instance.$container),(ref1=this.instances[instance.sectionId])!=null?ref1.update(instance.$container):void 0},onSectionUnload:function(event){var instance,ref;return instance=sections.getInstance(event),(ref=this.instances[instance.sectionId])!=null&&ref.remove(),delete this.instances[instance.sectionId]}}},HomeView2})(Backbone.View),window.PasswordView=(function(superClass){extend(PasswordView2,superClass);function PasswordView2(){return PasswordView2.__super__.constructor.apply(this,arguments)}return PasswordView2.prototype.events={"click [data-close-modal]":"closeModal","click .admin-login-modal":"openModal"},PasswordView2.prototype.initialize=function(){return this.modalWrapper=$(".password-page-modal-wrapper"),this.modalContent=this.modalWrapper.find(".password-page-modal"),this.openByDefault=this.modalWrapper.find("[data-open-modal]").length,this.openByDefault&&this.openModal(),$(window).resize((function(_this){return function(){return _this.positionModal()}})(this))},PasswordView2.prototype.closeModal=function(){if(this.modalWrapper.hasClass("visible"))return this.modalWrapper.removeClass("visible"),this.$el.removeClass("scroll-locked")},PasswordView2.prototype.openModal=function(){return this.$el.addClass("scroll-locked"),this.positionModal(),this.modalWrapper.addClass("visible")},PasswordView2.prototype.positionModal=function(){return this.modalContent.css({marginTop:-(this.modalContent.outerHeight()/2),marginLeft:-(this.modalContent.outerWidth()/2)})},PasswordView2})(Backbone.View),window.LinkedOptions=(function(){function LinkedOptions2(options){this.options=options,this._init()}return LinkedOptions2.prototype._init=function(){return this._mapVariants(this.options.productJSON)},LinkedOptions2.prototype._getCurrent=function(optionIndex){var key,option1,option2,selector;if(this.options.type==="select")switch(optionIndex){case 0:key="root",selector=this.options.$selector.eq(0);break;case 1:key=this.options.$selector.eq(0).val(),selector=this.options.$selector.eq(1);break;case 2:key=this.options.$selector.eq(0).val()+" / "+this.options.$selector.eq(1).val(),selector=this.options.$selector.eq(2)}if(this.options.type==="radio")switch(optionIndex){case 0:key="root",selector=this.options.$selector.filter("[data-option-index=0]").filter(":checked");break;case 1:key=this.options.$selector.filter("[data-option-index=0]").filter(":checked").val(),selector=this.options.$selector.filter("[data-option-index=1]").filter(":checked");break;case 2:option1=this.options.$selector.filter("[data-option-index=0]").filter(":checked").val(),option2=this.options.$selector.filter("[data-option-index=1]").filter(":checked").val(),key=option1+" / "+option2,selector=this.options.$selector.filter("[data-option-index=2]").filter(":checked")}return{key:key,selector:selector}},LinkedOptions2.prototype._updateOptions=function(optionIndex,optionsMap){var $nextOption,$option,$selector,$selectorOptions,availableOptions,initialValue,j,key,l,len,len1,nextSelector,option,ref,selector,updateSelected;if(nextSelector=optionIndex+1,updateSelected=!1,ref=this._getCurrent(optionIndex),key=ref.key,selector=ref.selector,availableOptions=optionsMap[key]||[],this.options.type==="select"){for($selector=this.options.$productForm.find(selector),initialValue=$selector.val(),$selectorOptions=$selector.find("option"),j=0,len=$selectorOptions.length;j<len;j++)option=$selectorOptions[j],$option=$(option),availableOptions.indexOf(option.value)===-1?(option.selected&&(updateSelected=!0),$option.prop("disabled",!0).prop("selected",!1)):$option.prop("disabled",!1);availableOptions.indexOf(initialValue)!==-1&&$selector.val(initialValue),updateSelected&&$selectorOptions.filter(":not(:disabled)").eq(0).prop("selected",!0)}if(this.options.type==="radio"){for($selector=this.options.$selector.filter("[data-option-index="+optionIndex+"]"),l=0,len1=$selector.length;l<len1;l++)option=$selector[l],$option=$(option),availableOptions.indexOf(option.value)===-1?(option.checked&&(updateSelected=!0),$option.prop("disabled",!0).prop("checked",!1)):$option.prop("disabled",!1);updateSelected&&$selector.filter(":not(:disabled)").eq(0).attr("checked",!0).trigger("click")}if($selector.trigger("change"),$nextOption=this.options.$selector.filter("[data-option-index="+nextSelector+"]"),$nextOption.length!==0)return this._updateOptions(nextSelector,optionsMap)},LinkedOptions2.prototype._mapVariants=function(product){var j,key,len,optionsMap,ref,variant;
1for(optionsMap=[],optionsMap.root=[],ref=product.variants,j=0,len=ref.length;j<len;j++)variant=ref[j],variant.available&&(optionsMap.root.push(variant.option1),optionsMap.root=window.ThemeUtils.unique(optionsMap.root),product.options.length>1&&(key=variant.option1,optionsMap[key]=optionsMap[key]||[],optionsMap[key].push(variant.option2),optionsMap[key]=window.ThemeUtils.unique(optionsMap[key])),product.options.length>2&&(key=variant.option1+" / "+variant.option2,optionsMap[key]=optionsMap[key]||[],optionsMap[key].push(variant.option3),optionsMap[key]=window.ThemeUtils.unique(optionsMap[key])));return this._updateOptions(0,optionsMap),this.options.$selector.on("change",(function(_this){return function(event){var index,nextSelector;return index=parseInt($(event.currentTarget).attr("data-option-index"),10),nextSelector=index+1,_this._updateOptions(nextSelector,optionsMap)}})(this))},LinkedOptions2.prototype.prepareRemove=function(){return this.options.$selector.off("change")},LinkedOptions2})(),window.ThemeUtils={extend:function(){var dest,j,k,len,obj,objs,v;for(dest=arguments[0],objs=2<=arguments.length?slice.call(arguments,1):[],j=0,len=objs.length;j<len;j++){obj=objs[j];for(k in obj)v=obj[k],dest[k]=v}return dest},windowWidth:function(){return window.innerWidth||this.window.width()},throttle:function(func,limit){var inThrottle;return inThrottle=!1,function(){var args,context;if(args=arguments,context=this,!inThrottle)return func.apply(context,args),inThrottle=!0,setTimeout(function(){return inThrottle=!1},limit)}},debounce:function(func,wait,immediate){var timeout;return timeout=null,function(){var args,callNow,context,later;context=this,args=arguments,later=function(){timeout=null,immediate||func.apply(context,args)},callNow=immediate&&!timeout,clearTimeout(timeout),timeout=setTimeout(later,wait),callNow&&func.apply(context,args)}},inViewport:function(el){var bounds,rect;return typeof jQuery=="function"&&el instanceof jQuery&&(el=el[0]),rect=el.getBoundingClientRect(),bounds={top:rect.top>=0,bottom:rect.bottom<=(window.innerHeight||document.documentElement.clientHeight)},bounds.top&&bounds.bottom},unique:function(array){var j,key,output,ref,results,value;for(output={},key=j=0,ref=array.length;0<=ref?j<ref:j>ref;key=0<=ref?++j:--j)output[array[key]]=array[key];results=[];for(key in output)value=output[key],results.push(value);return results}},window.VariantHelper=(function(){function VariantHelper2(options){var defaultOptions,isShopify;defaultOptions={$addToCartButton:null,$priceFields:null,$productForm:null,$productThumbnails:null,$selector:null,type:"select",productJSON:null,productSettings:null},this.options=window.ThemeUtils.extend(defaultOptions,options),this.$body=$(document.body),this.linkedOptions=null,this.enableHistory=!1,this.$masterSelect=this.options.$productForm.find(".product-select"),isShopify=window.Shopify&&window.Shopify.preview_host,window.history&&window.history.replaceState&&this.options.productSettings.enableHistory&&!isShopify&&(this.enableHistory=!0),this._init(),this._bindEvents()}return VariantHelper2.prototype._init=function(){var j,len,ref,select;if(this.options.type==="select")for(ref=this.options.$selector,j=0,len=ref.length;j<len;j++)select=ref[j],this._setSelectLabel(null,$(select));return this.options.productSettings.linkedOptions&&(this.linkedOptions=new LinkedOptions(this.options)),this._updateCurrency()},VariantHelper2.prototype._bindEvents=function(){return this.options.$selector.on("change",(function(_this){return function(event){return _this._variantChange(event)}})(this))},VariantHelper2.prototype._setSelectLabel=function(event,$target){var selectedOption;return event==null&&(event=null),$target==null&&($target=!1),$target||($target=$(event.currentTarget)),selectedOption=$target.find("option:selected").val(),$target.prev("[data-select-text]").find("[data-selected-option]").text(selectedOption)},VariantHelper2.prototype._getCurrentOptions=function(){var $inputs,productOptions;return productOptions=[],$inputs=this.options.$selector,this.options.type==="radio"&&($inputs=$inputs.filter(":checked")),$input
1s.each(function(index,element){return productOptions.push($(element).val())}),productOptions},VariantHelper2.prototype._getVariantFromOptions=function(productOptions){var foundVariant,isMatch,j,len,ref,variant;if(this.options.productJSON.variants!=null){for(foundVariant=null,ref=this.options.productJSON.variants,j=0,len=ref.length;j<len;j++)variant=ref[j],isMatch=productOptions.every(function(value,index){return variant.options[index]===value}),isMatch&&(foundVariant=variant);return foundVariant}},VariantHelper2.prototype._updateMasterSelect=function(variant){var ref;if(variant!=null)return(ref=this.$masterSelect.find("[data-variant-id="+variant.id+"]"))!=null&&ref.prop("selected",!0),this.$masterSelect.trigger("change")},VariantHelper2.prototype._updatePrice=function(variant){var $addToCartButton,$moneyEl,$priceFields,attribute,j,l,len,len1,priceField,productSettings,ref,variantComparePrice,variantPrice;if($addToCartButton=this.options.$addToCartButton,$priceFields=this.options.$priceFields,productSettings=this.options.productSettings,variant!=null){for(variantPrice=Shopify.formatMoney(variant.price,Theme.moneyFormat),variantComparePrice=Shopify.formatMoney(variant.compare_at_price,Theme.moneyFormat),j=0,len=$priceFields.length;j<len;j++)for(priceField=$priceFields[j],$moneyEl=$(priceField).children(".money"),ref=$moneyEl[0].attributes,l=0,len1=ref.length;l<len1;l++)attribute=ref[l],attribute.name.indexOf("data-")>-1&&$moneyEl.attr(attribute.name,"");variant.available?$addToCartButton.val(productSettings.addToCartText).removeClass("disabled").removeAttr("disabled"):$addToCartButton.val(productSettings.soldOutText).addClass("disabled").attr("disabled","disabled"),variant.compare_at_price>variant.price?($priceFields.find(".money:first-child").html(variantPrice).attr("data-currency-"+Theme.currency,variantPrice).attr("data-currency",Theme.currency),$priceFields.find(".product-price-compare").html(variantComparePrice).attr("data-currency-"+Theme.currency,variantComparePrice).attr("data-currency",Theme.currency).removeClass("hidden")):($priceFields.find(".money").html(variantPrice).attr("data-currency-"+Theme.currency,variantPrice).attr("data-currency",Theme.currency),$priceFields.find(".product-price-compare").html("").attr("data-currency-"+Theme.currency,variantComparePrice).attr("data-currency",Theme.currency).addClass("hidden"))}else $addToCartButton.val(productSettings.unavailableText).addClass("disabled").attr("disabled","disabled");return this._updateCurrency()},VariantHelper2.prototype._updateImages=function(variant){var imageId,ref,ref1;if(imageId=variant!=null&&(ref=variant.featured_image)!=null?ref.id:void 0,imageId!=null)return(ref1=this.options.$productThumbnails)!=null?ref1.filter("[data-image-id='"+imageId+"']").trigger("click"):void 0},VariantHelper2.prototype._updateHistory=function(variant){var newUrl,variantUrl;if(this.enableHistory&&variant!=null)return newUrl=[window.location.protocol,"//",window.location.host,window.location.pathname,"?variant=",variant.id],variantUrl=newUrl.join(""),window.history.replaceState({path:variantUrl},"",variantUrl)},VariantHelper2.prototype._variantChange=function(event){var productOptions,variant;return this.options.type==="select"&&this._setSelectLabel(event),productOptions=this._getCurrentOptions(),variant=this._getVariantFromOptions(productOptions),this._updateMasterSelect(variant),this._updatePrice(variant),this._updateImages(variant),this._updateHistory(variant)},VariantHelper2.prototype._updateCurrency=function(){if(Theme.currencySwitcher)return $(".currency-switcher").trigger("reset-currency")},VariantHelper2.prototype.prepareRemove=function(){var ref;return this.options.$selector.off("change"),(ref=this.linkedOptions)!=null?ref.prepareRemove():void 0},VariantHelper2})(),ImageZoom=(function(){function ImageZoom2(el){this.unload=bind(this.unload,this),this._positionZoom=bind(this._positionZoom,this),this._resetZoom=bind(this._resetZoom,this),this._toggleZoom=bind(this._toggleZoom,this),this._layoutHandler=bind(this._layoutHandler,this),this._unbindLayoutEvent=bind(this._unbindLayoutEvent,this),this._bindLayoutEvent=bind(this._bindLayoutEvent,this),this._unbindEvents=bind(this._unbindEvents,this),this._bindEvents=bind(this._bindEvents,this),this.disableZoom=bind(this.disableZoom,this),this.enableZoom=bind(this.enableZoom,this),this.el=el,this.$el=$(el),this.$img=$(this.$el.children("img")),this.framerate=60,this.scale=1,this.zoomable=!1,this.zoomed=!1,this.requestAnimationFrameId=null,this.layoutHandler=this._layoutHandler.bind(this),this.resetZoom=this._resetZoom.bind(this),this._bindLayoutEvent()}return ImageZoom2.prototype.enableZoom=function(){return this.$el.addClass("product-image-zoomable"),this._bindEvents()},ImageZoom2.prototype.disableZoom=function(){return this.$el.removeClass("product-image-zoomable"),this._unbindEvents(),this._resetZoom()},ImageZoom2.prototype._bindEvents=function(){return this.$el.on("click.product-zoom",(function(_this){return function(event){return _this._toggleZoom(event.clientX,event.clientY)}})(this)),$(window).on("resize.product-zoom",this.resetZoom)},ImageZoom2.prototype._unbindEvents=function(){return this.$el.off("click.product-zoom"),$(window).off("resize.product-zoom",this.resetZoom)},ImageZoom2.prototype._bindLayoutEvent=function(){return this.requestAnimationFrameId=window.requestAnimationFrame(this.layoutHandler)},ImageZoom2.prototype._unbindLayoutEvent=function(){return window.cancelAnimationFrame(this.requestAnimationFrameId)},ImageZoom2.prototype._layoutHandler=function(){var scale,zoomable;
1if(scale=this.$img[0].naturalWidth/this.$el[0].getBoundingClientRect().width,zoomable=scale>=1.25,console.log(this.$img,scale,zoomable),zoomable===this.zoomable){this.requestAnimationFrameId=window.requestAnimationFrame(this.layoutHandler);return}else this.scale=scale,this.zoomable=zoomable;return this.zoomable?this.enableZoom():this.disableZoom(),this.requestAnimationFrameId=window.requestAnimationFrame(this.layoutHandler)},ImageZoom2.prototype._toggleZoom=function(clientX,clientY){return this.zoomed?this._resetZoom():(this.$el.on("mousemove.product-zoom",ThemeUtils.throttle((function(_this){return function(event){return _this._positionZoom(event.clientX,event.clientY)}})(this),1e3/this.framerate)),this.$el.on("mouseout.product-zoom",(function(_this){return function(){return _this._resetZoom()}})(this)),this.$el.addClass("product-image-zoomed"),this.$img.css("transform","scale("+this.scale+")"),this._positionZoom(clientX,clientY),this.zoomed=!0)},ImageZoom2.prototype._resetZoom=function(){return this.$el.off("mousemove.product-zoom"),this.$el.off("mouseout.product-zoom"),this.$el.removeClass("product-image-zoomed"),this.$img.css("transform",""),this.zoomed=!1},ImageZoom2.prototype._positionZoom=function(clientX,clientY){var centerX,centerY,figHalfHeight,figHalfWidth,figRect,heightDiff,imgRect,translateX,translateY,widthDiff;return figRect=this.$el[0].getBoundingClientRect(),imgRect=this.$img[0].getBoundingClientRect(),figHalfWidth=figRect.width/2,figHalfHeight=figRect.height/2,centerX=figRect.left+figHalfWidth,centerY=figRect.top+figHalfHeight,widthDiff=imgRect.width/2-figHalfWidth,heightDiff=imgRect.height/2-figHalfHeight,translateX=(centerX-clientX)/figHalfWidth*widthDiff/this.scale,translateY=(centerY-clientY)/figHalfHeight*heightDiff/this.scale,this.$img.css("transform","scale("+this.scale+") translate("+translateX+"px, "+translateY+"px)")},ImageZoom2.prototype.unload=function(){return this._unbindLayoutEvent(),this.disableZoom()},ImageZoom2})(),Product=(function(){function Product2(options){var e,j,len,ref,select;this.el=options.el,this.data=options.data,this.product=this.data.product;try{for(this.enableZoom=this.data.enable_zoom,this.enableRelatedProducts=this.data.enable_related_products,this.minimumPriceArea=$(".product-price-minimum",this.el),this.addingToCart=!1,this.productArea=$(".product-page",this.el),this.$productThumbnails=$(".product-image-thumbnails img",this.productArea),this.$productForm=$(".product-form",this.productArea).eq(0),this.$priceArea=$(".product-price",this.$productForm),this.$addToCartButton=$(".product-add input",this.$productForm),this.$variantDropdowns=$("[data-option-select]",this.$productForm),this.options=this.product.options,this.variants=this.product.variants,this.images=this.product.images,$(".product-form",this.el).length&&this.setupVariants(),this.enableRelatedProducts&&(this.relatedView=new ProductListView({el:$(".related-products",this.el)})),this.enableZoom&&(this.zoomView=new ImageZoom(this.el.querySelector(".product-main-image"))),ref=$("select",this.el),j=0,len=ref.length;j<len;j++)select=ref[j],new SelectView({el:select});Shopify.onError=(function(_this){return function(XMLHttpRequest){return _this.handleErrors(XMLHttpRequest)}})(this),this.$productThumbnails.on("click",(function(_this){return function(event){return _this.switchProductImage(event)}})(this)),this.$addToCartButton.on("click",(function(_this){return function(event){return _this.addToCart(event)}})(this)),this.images=JSON.parse($("[data-images]",this.el).text())}catch(error1){e=error1,console.error(e)}}return Product2.prototype.setupVariants=function(){var dropdownSettings;if(this.$variantDropdowns.length)return dropdownSettings={$addToCartButton:this.$addToCartButton,$priceFields:this.$priceArea,$productForm:this.$productForm,$productThumbnails:this.$productThumbnails,$selector:this.$variantDropdowns,productSettings:this.data,productJSON:this.product,type:"select"},this.variantHelpers=new VariantHelper(dropdownSettings)},Product2.prototype.switchProductImage=function(e){var $image,$nextImage,imageId;return this.enableZoom&&this.zoomView.unload(),imageId=$(e.target,this.el).data("image-id"),$nextImage=$(this.images[imageId]),$nextImage.css("display","none"),$image=$("[data-product-main-image]",this.el),$nextImage.one("load",(function(_this){return function(){if($(".product-main-image").children().not($nextImage).remove(),$nextImage.css("display",""),_this.enableZoom)return _this.zoomView=new ImageZoom(_this.el.querySelector(".product-main-image"))}})(this)),$image.after($nextImage),$nextImage.trigger("theme:rimg:watch")},Product2.prototype.addToCart=function(e){var button;if(!this.data.enable_cart_redirection){if(e.preventDefault(),$(".product-message-wrapper",this.el).remove(),this.addingToCart===!0||this.$productForm.serialize()==="")return!1;if(button=$(".product-add .action-btn",this.el),!button.hasClass("disabled"))return this.addingToCart=!0,$.ajax({type:"POST",url:"/cart/add.js",data:this.$productForm.serialize(),dataType:"json",success:(function(_this){return function(item){var message;return message=Theme.addToCartSuccess.replace("{{ product }}",""+_this.product.title).replace("{{ cart_link }}","<a href='/cart'>cart</a>").replace("{{ continue_link }}","<a href='/collections/all'>Continue Shopping</a>").replace("{{ checkout_link }}","<a href='/checkout'>check out</a>"),setTimeout(function(){return $(".product-add-to-cart",_this.el).append('<li class="product-message-wrapper"><p class="product-message">'+message+"</p></li>").addClass("success-message").removeClass("error-message"),_this.addingToCart=!1,_this.updateCart()},500)}})(this),error:(function(_this){return function(error){return _this.handleErrors(error)}})(this)})}},Product2.prototype.updateCart=function(){return Shopify.getCart((function(_this){return function(cart){var cartCount,cartTotal;return cart.item_count===1?cartCount="1 item".replace("1",""+cart.item_count):cartCount="0 items".replace("0",""+cart.item_count),$(".cart-item-count-wrap").text(cartCount),cartTotal=Shopify.formatMoney(cart.total_price,Theme.moneyFormat),$(".cart-amount-wrap").attr("data-currency-"+Currency.currentCurrency,"").attr("data-currency-"+Theme.currency,cartTotal).attr("data-currency",Theme.currency).text(cartTotal),$(".currency-switcher").trigger("reset-currency")}})(this))},Product2.prototype.handleErrors=function(error){return setTimeout((function(_this){return function(){return $(".product-add-to-cart",_this.el).append('<li class="product-message-wrapper">\n    <p class="product-message">\n        '+error.responseJSON.description+"\n    </p>\n</li>").addClass("error-message").removeClass("success-message"),_this.addingToCart=!1}})(this),1e3)},Product2.prototype.onSectionUnload=function(){var ref,ref1;return(ref=this.zoomView)!=null&&ref.unload(),(ref1=this.relatedView)!=null?ref1.remove():void 0},Product2})(),window.QuickShopView=(function(superClass){extend(QuickShopView2,superClass);function QuickShopView2(){return QuickShopView2.__super__.constructor.apply(this,arguments)}return QuickShopView2.prototype.events={"click .product-item-quick-shop .available":"openQuickShop","click .quick-shop-modal":"closeQuickShop","click .quick-shop-add":"addToCart","click .quick-shop-close":"closeQuickShop","click .quick-shop-close-x":"closeQuickShopWithX","touchstart .quick-shop-modal":"closeQuickShop","touchstart .quick-shop-close":"closeQuickShop","touchstart .quick-shop-close-x":"closeQuickShopWithX"},QuickShopView2.prototype.initialize=function(){return this.quickShopModal=$(".quick-shop-modal"),this.quickShopConfirmation=this.$(".quick-shop-confirmation"),this.minimumPriceArea=this.$(".quick-shop-price-minimum"),this.addingToCart=!1},QuickShopView2.prototype.openQuickShop=function(e){var j,len,ref,select,target;for(e.preventDefault(),target=$(e.currentTarget),this.product=target.data("product-json"),this.enableCartRedirection=target[0].hasAttribute("data-quickshop-enable-cart-redirection"),this.itemId=target.data("quickshop-id"),this.quickShopContent=$("#quick-shop-"+this.itemId),this.setupVariants(this.quickShopContent),ref=this.$("select"),j=0,len=ref.length;j<len;j++)select=ref[j],new SelectView({el:select});return this.quickShopModal.addClass("visible").append(this.quickShopContent),setTimeout((function(_this){return function(){return _this.quickShopModal.addClass("active"),_this.quickShopContent.addClass("active"),$(document.body).addClass("quick-shop-open")}})(this),20),this.positionQuickShop(this.quickShopContent),Shopify.onError=(function(_this){return function(XMLHttpRequest){return _this.handleErrors(XMLHttpRequest)}})(this)},QuickShopView2.prototype.closeQuickShopWithX=function(e,confirm,hasError){var $gridItem;if($gridItem=$("[data-product-item-id='"+this.itemId+"']"),e.currentTarget)return this.quickShopModal.removeClass("visible"),this.quickShopModal.removeClass("active"),$gridItem.append(this.quickShopContent),this.quickShopConfirmation.removeClass("active"),this.quickShopContent.removeClass("active"),$(document.body).removeClass("quick-shop-open"),this.addingToCart=!1},QuickShopView2.prototype.closeQuickShop=function(e,confirm,hasError){var $gridItem;if($gridItem=$("[data-product-item-id='"+this.itemId+"']"),e&&(this.$(e.target).closest(".quick-shop-container").length||this.$(e.target).closest(".product-item-quick-shop").length||this.quickShopModal.removeClass("active").one("transitionend",(function(_this){return function(){if(_this.quickShopModal.removeClass("visible"),$gridItem.append(_this.quickShopContent),_this.quickShopConfirmation.removeClass("active"),_this.quickShopContent.removeClass("active"),$(document.body).removeClass("quick-shop-open"),_this.addingToCart=!1,hasError==="remove error")return _this.$(".quick-shop-message").remove()}})(this))),confirm)return this.quickShopContent.removeClass("active").one("transitionend",(function(_this){return function(){return _this.quickShopContent.off("transitionend"),_this.quickShopConfirmation.addClass("active")}})(this))},QuickShopView2.prototype.setupVariants=function(quickShopContent){var $addToCartButton,$priceArea,$productJSON,$productSettings,$quickShopForm,$variantDropdowns,dropdownSettings;if(this.quickShopContent=quickShopContent,$quickShopForm=$(".quickshop-form",this.quickShopContent),this.quickshopformID=parseInt($quickShopForm.attr("data-quickshop-form"),10),this.productSelect="#product-select-"+this.quickshopformID,$priceArea=$(".quick-shop-price-container",this.quickShopContent),$addToCartButton=$(".quick-shop-add",this.quickShopContent),$productJSON=$("[data-quickshop-json-"+this.quickshopformID+"]",this.quickShopContent),$productSettings=$("[data-quickshop-settings-"+this.quickshopformID+"]",this.quickShopContent),this.productJSON=JSON.parse($productJSON.text()),this.productSettings=JSON.parse($productSettings.text()),$variantDropdowns=$("[data-option-select="+this.quickshopformID+"]",this.quickShopContent),this.options=this.productJSON.options,this.variants=this.productJSON.variants,!!$variantDropdowns.length)return dropdownSettings={$addToCartButton:$addToCartButton,$priceFields:$priceArea,$productForm:$quickShopForm,$selector:$variantDropdowns,formID:this.quickshopformID,productSettings:this.productSettings,productJSON:this.productJSON,type:"select"},this.variantHelpers=new VariantHelper(dropdownSettings)},QuickShopView2.prototype.switchCurrency=function(minimum,compare){var attribute,j,len,minimumPriceArea,ref;for(minimumPriceArea=this.$(".quick-shop-price-minimum"),ref=minimumPriceArea[0].attributes,j=0,len=ref.length;j<len;j++)attribute=ref[j],attribute.name.indexOf("data-")>-1&&minimumPriceArea.attr(attribute.name,"");return minimumPriceArea.attr("data-currency-"+Currency.currentCurrency,"").attr("data-currency-"+Theme.currency,Shopify.formatMoney(minimum,Theme.moneyFormat)).attr("data-currency",Theme.currency),this.$(".quick-shop-price-compare").attr("data-currency-"+Theme.currency,Shopify.formatMoney(compare,Theme.moneyFormat)).attr("data-currency",Theme.currency),$(".currency-switcher").trigger("reset-currency")},QuickShopView2.prototype.addToCart=function(e){var $form,button,formData;if(!this.enableCartRedirection){if(this.addingToCart===!0||($form=$("#product-form-"+this.quickshopformID),formData=$form.serialize(),formData===""))return!1;if(e.preventDefault(),button=$form.find(".quick-shop-add"),!button.children().hasClass("disabled"))return this.addingToCart=!0,Shopify.addItemFromForm("product-form-"+this.quickshopformID,(function(_this){return function(item){return _this.updateCart(item),_this.closeQuickShop(null,!0)}})(this))}},QuickShopView2.prototype.updateCart=function(item){return Shopify.getCart((function(_this){return function(cart){var cartCount,newFormattedAmount;if(cart.item_count===1?cartCount="1 item".replace("1",""+cart.item_count):cartCount="0 items".replace("0",""+cart.item_count),newFormattedAmount=Shopify.formatMoney(cart.total_price,Theme.moneyFormat),_this.$(".cart-item-count-wrap").text(cartCount),_this.$(".cart-amount-wrap").attr("data-currency-"+Currency.currentCurrency,"").attr("data-currency-"+Theme.currency,newFormattedAmount).attr("data-currency",Theme.currency).html(newFormattedAmount),Theme.currencySwitcher)return $(".currency-switcher").trigger("reset-currency")}})(this))},QuickShopView2.prototype.positionQuickShop=function(quickShop){var quickShopConfirmationHeight,quickShopHeight;return quickShopHeight=quickShop.outerHeight(),quickShop.css({marginTop:quickShopHeight/-2}),quickShopConfirmationHeight=this.quickShopConfirmation.outerHeight(),this.quickShopConfirmation.css({marginTop:quickShopConfirmationHeight/-2})},QuickShopView2.prototype.handleErrors=function(error){return this.quickShopContent.append('<div class="quick-shop-message">\n    '+error.responseJSON.description+"\n</div>"),setTimeout((function(_this){return function(){return _this.closeQuickShop(null,null,"remove error"),_this.addingToCart=!1}})(this),1e3)},QuickShopView2})(Backbone.View),window.RTEView=(function(superClass){extend(RTEView2,superClass);function RTEView2(){return RTEView2.__super__.constructor.apply(this,arguments)}return RTEView2.prototype.initialize=function(){return this.setupTabs(),this.$el.fitVids()},RTEView2.prototype.setupTabs=function(){var groupedContent;return groupedContent=new GroupedContent(this.$el.get(0),{layout:"tabs",intelliparse:!1})},RTEView2})(Backbone.View),window.SelectView=(function(superClass){extend(SelectView2,superClass);function SelectView2(){return SelectView2.__super__.constructor.apply(this,arguments)}return SelectView2.prototype.events={change:"updateSelectText"},SelectView2.prototype.initialize=function(){return this.$el.parent(".select-wrapper").length||this.$el.hasClass("product-variants")||this.$el.wrap("<div class='select-wrapper' />").parent().prepend('<svg role="img" class="select-dropdown">
1<use xlink:href="#icon-dropdown"></use></svg>').prepend("<span class='selected-text'></span>"),this.updateSelectText(),this.$el.hasClass("product-variants")||this.$el.show(),$("#address-country").on("change",(function(_this){return function(){return _this.updateSelectText("province")}})(this))},SelectView2.prototype.updateSelectText=function(select){var newOption,target;return select==="province"?target=$("#address-province"):target=this.$el,newOption=target.find("option:selected").text()||target.find("option").eq(0).val(),target.siblings(".selected-text").text(newOption)},SelectView2})(Backbone.View),window.ShareView=(function(superClass){extend(ShareView2,superClass);function ShareView2(){return ShareView2.__super__.constructor.apply(this,arguments)}return ShareView2.prototype.events={click:"closeShare","click .share-widget-toggle":"openShare"},ShareView2.prototype.openShare=function(e){var otherShareWidgets,targetShareWidget;return targetShareWidget=this.$(e.target).closest(".article-meta-wrap"),otherShareWidgets=$(".article-meta-wrap").not(targetShareWidget),targetShareWidget.addClass("active"),otherShareWidgets.removeClass("active")},ShareView2.prototype.closeShare=function(e){if(!(this.$(e.target).closest(".share-widget-toggle").length||this.$(e.target).closest(".share-widget").length))return $(".article-meta-wrap").removeClass("active")},ShareView2})(Backbone.View),window.ThemeEditor=(function(superClass){extend(ThemeEditor2,superClass);function ThemeEditor2(){return ThemeEditor2.__super__.constructor.apply(this,arguments)}return ThemeEditor2.prototype.initialize=function(){return this.instanceHandlers={},this.instances={},$(document).on("shopify:section:load",(function(_this){return function(event){return _this._onSectionLoad(event)}})(this)).on("shopify:section:unload",(function(_this){return function(event){return _this._onSectionUnload(event)}})(this)).on("shopify:section:select",(function(_this){return function(event){return _this._onSectionSelect(event)}})(this)).on("shopify:section:deselect",(function(_this){return function(event){return _this._onSectionDeselect(event)}})(this)).on("shopify:section:reorder",(function(_this){return function(event){return _this._onSectionReorder(event)}})(this)).on("shopify:block:select",(function(_this){return function(event){return _this._onBlockSelect(event)}})(this)).on("shopify:block:deselect",(function(_this){return function(event){return _this._onBlockDeselect(event)}})(this))},ThemeEditor2.prototype._findInstance=function(event){var $container,instance;return instance=this.instances[event.originalEvent.detail.sectionId],instance!=null?instance:($c
1ontainer=$("[data-section-id]",event.target),this._createInstance($container))},ThemeEditor2.prototype._createInstance=function($container,instanceHandler){var data,el,instance,sectionId,sectionType;if(el=$container.parent().get(0),data=this._loadData(el),sectionType=$container.attr("data-section-type"),sectionId=$container.attr("data-section-id"),sectionType!=null)return instanceHandler=instanceHandler||this.instanceHandlers[sectionType],instance={instanceHandler:instanceHandler,el:el,data:data,$container:$container,sectionId:sectionId},this.instances[sectionId]=instance,instance},ThemeEditor2.prototype._loadData=function(el){var data,dataEl,error;if(dataEl=el.querySelector("[data-section-data]"),!dataEl)return{};data=dataEl.getAttribute("data-section-data")||dataEl.innerHTML;try{return JSON.parse(data)}catch(error1){return error=error1,console.warn("Sections: invalid section data found. "+error.message),{}}},ThemeEditor2.prototype._onSectionLoad=function(event){var $container,ref,ref1;if($container=$("[data-section-id]",event.target),!!$container.length)return(ref=this._createInstance($container))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onSectionLoad=="function"?ref1.onSectionLoad(event):void 0},ThemeEditor2.prototype._onSectionUnload=function(event){var instance,ref;if(instance=this._findInstance(event),instance!=null&&(ref=instance.instanceHandler)!=null&&typeof ref.onSectionUnload=="function"&&ref.onSectionUnload(event),instance)return delete this.instances[instance.sectionId]},ThemeEditor2.prototype._onSectionSelect=function(event){var ref,ref1;return(ref=this._findInstance(event))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onSectionSelect=="function"?ref1.onSectionSelect(event):void 0},ThemeEditor2.prototype._onSectionDeselect=function(event){var ref,ref1;return(ref=this._findInstance(event))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onSectionDeselect=="function"?ref1.onSectionDeselect(event):void 0},ThemeEditor2.prototype._onSectionReorder=function(event){var ref,ref1;return(ref=this._findInstance(event))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onSectionReorder=="function"?ref1.onSectionReorder(event):void 0},ThemeEditor2.prototype._onBlockSelect=function(event){var ref,ref1;return(ref=this._findInstance(event))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onBlockSelect=="function"?ref1.onBlockSelect(event):void 0},ThemeEditor2.prototype._onBlockDeselect=function(event){var ref,ref1;return(ref=this._findInstance(event))!=null&&(ref1=ref.instanceHandler)!=null&&typeof ref1.onBlockDeselect=="function"?ref1.onBlockDeselect(event):void 0},ThemeEditor2.prototype._sectionInit=function(instance){var ref;return instance!=null&&(ref=instance.instanceHandler)!=null&&typeof ref.init=="function"?ref.init(instance):void 0},ThemeEditor2.prototype.register=function(type,instanceHandler){return this.instanceHandlers[type]=instanceHandler,$("[data-section-type="+type+"]").each((function(_this){return function(index,container){var $container;return $container=$(container),_this._sectionInit(_this._createInstance($container,instanceHandler))}})(this))},ThemeEditor2.prototype.getInstance=function(event){return this._findInstance(event)},ThemeEditor2})(Backbone.View),(function(window2,document2){"use strict";if("IntersectionObserver"in window2&&"IntersectionObserverEntry"in window2&&"intersectionRatio"in window2.IntersectionObserverEntry.prototype){"isIntersecting"in window2.IntersectionObserverEntry.prototype||Object.defineProperty(window2.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});return}var registry=[];function IntersectionObserverEntry(entry){this.time=entry.time,this.target=entry.target,this.rootBounds=entry.rootBounds,this.boundingClientRect=entry.boundingClientRect,this.intersectionRect=entry.intersectionRect||getEmptyRect(),this.isIntersecting=!!entry.intersectionRect;var targetRect=this.boundingClientRect,targetArea=targetRect.width*targetRect.height,intersectionRect=this.intersectionRect,intersectionArea=intersectionRect.width*intersectionRect.height;targetArea?this.intersectionRatio=intersectionArea/targetArea:this.intersectionRatio=this.isIntersecting?1:0}function IntersectionObserver2(callback,opt_options){var options=opt_options||{};if(typeof callback!="function")throw new Error("callback must be a function");if(options.root&&options.root.nodeType!=1)throw new Error("root must be an Element");this._checkForIntersections=throttle(this._checkForIntersections.bind(this),this.THROTTLE_TIMEOUT),this._callback=callback,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(options.rootMargin),this.thresholds=this._initThresholds(options.threshold),this.root=options.root||null,this.rootMargin=this._rootMarginValues.map(function(margin){return margin.value+margin.unit}).join(" ")}IntersectionObserver2.prototype.THROTTLE_TIMEOUT=100,IntersectionObserver2.prototype.POLL_INTERVAL=null,IntersectionObserver2.prototype.USE_MUTATION_OBSERVER=!0,IntersectionObserver2.prototype.observe=function(target){var isTargetAlreadyObserved=this._observationTargets.some(function(item){return item.element==target});if(!isTargetAlreadyObserved){if(!(target&&target.nodeType==1))throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:target,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},IntersectionObserver2.prototype.unobserve=function(target){this._observationTargets=this._observationTargets.filter(function(item){return item.element!=target}),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},IntersectionObserver2.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},IntersectionObserver2.prototype.takeRecords=function(){var records=this._queuedEntries.slice();return this._queuedEntries=[],records},IntersectionObserver2.prototype._initThresholds=function(opt_threshold){var threshold=opt_threshold||[0];return Array.isArray(threshold)||(threshold=[threshold]),threshold.sort().filter(function(t,i,a){if(typeof t!="number"||isNaN(t)||t<0||t>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return t!==a[i-1]})},IntersectionObserver2.prototype._parseRootMargin=function(opt_rootMargin){var marginString=opt_rootMargin||"0px",margins=marginString.split(/\s+/).map(function(margin){var parts=/^(-?\d*\.?\d+)(px|%)$/.exec(margin);if(!parts)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(parts[1]),unit:parts[2]}});return margins[1]=margins[1]||margins[0],margins[2]=margins[2]||margins[0],margins[3]=margins[3]||margins[1],margins},IntersectionObserver2.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(addEvent(window2,"resize",this._checkForIntersections,!0),addEvent(document2,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in window2&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(document2,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},IntersectionObserver2.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,removeEvent(window2,"resize",this._checkForIntersections,!0),removeEvent(document2,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},IntersectionObserver2.prototype._checkForIntersections=function(){var rootIsInDom=this._rootIsInDom(),rootRect=rootIsInDom?this._getRootRect():getEmptyRect();
1this._observationTargets.forEach(function(item){var target=item.element,targetRect=getBoundingClientRect(target),rootContainsTarget=this._rootContainsTarget(target),oldEntry=item.entry,intersectionRect=rootIsInDom&&rootContainsTarget&&this._computeTargetAndRootIntersection(target,rootRect),newEntry=item.entry=new IntersectionObserverEntry({time:now(),target:target,boundingClientRect:targetRect,rootBounds:rootRect,intersectionRect:intersectionRect});oldEntry?rootIsInDom&&rootContainsTarget?this._hasCrossedThreshold(oldEntry,newEntry)&&this._queuedEntries.push(newEntry):oldEntry&&oldEntry.isIntersecting&&this._queuedEntries.push(newEntry):this._queuedEntries.push(newEntry)},this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},IntersectionObserver2.prototype._computeTargetAndRootIntersection=function(target,rootRect){if(window2.getComputedStyle(target).display!="none"){for(var targetRect=getBoundingClientRect(target),intersectionRect=targetRect,parent=getParentNode(target),atRoot=!1;!atRoot;){var parentRect=null,parentComputedStyle=parent.nodeType==1?window2.getComputedStyle(parent):{};if(parentComputedStyle.display=="none")return;if(parent==this.root||parent==document2?(atRoot=!0,parentRect=rootRect):parent!=document2.body&&parent!=document2.documentElement&&parentComputedStyle.overflow!="visible"&&(parentRect=getBoundingClientRect(parent)),parentRect&&(intersectionRect=computeRectIntersection(parentRect,intersectionRect),!intersectionRect))break;parent=getParentNode(parent)}return intersectionRect}},IntersectionObserver2.prototype._getRootRect=function(){var rootRect;if(this.root)rootRect=getBoundingClientRect(this.root);else{var html=document2.documentElement,body=document2.body;rootRect={top:0,left:0,right:html.clientWidth||body.clientWidth,width:html.clientWidth||body.clientWidth,bottom:html.clientHeight||body.clientHeight,height:html.clientHeight||body.clientHeight}}return this._expandRectByRootMargin(rootRect)},IntersectionObserver2.prototype._expandRectByRootMargin=function(rect){var margins=this._rootMarginValues.map(function(margin,i){return margin.unit=="px"?margin.value:margin.value*(i%2?rect.width:rect.height)/100}),newRect={top:rect.top-margins[0],right:rect.right+margins[1],bottom:rect.bottom+margins[2],left:rect.left-margins[3]};return newRect.width=newRect.right-newRect.left,newRect.height=newRect.bottom-newRect.top,newRect},IntersectionObserver2.prototype._hasCrossedThreshold=function(oldEntry,newEntry){var oldRatio=oldEntry&&oldEntry.isIntersecting?oldEntry.intersectionRatio||0:-1,newRatio=newEntry.isIntersecting?newEntry.intersectionRatio||0:-1;if(oldRatio!==newRatio)for(var i=0;i<this.thresholds.length;i++){var threshold=this.thresholds[i];if(threshold==oldRatio||threshold==newRatio||threshold<oldRatio!=threshold<newRatio)return!0}},IntersectionObserver2.prototype._rootIsInDom=function(){return!this.root||containsDeep(document2,this.root)},IntersectionObserver2.prototype._rootContainsTarget=function(target){return containsDeep(this.root||document2,target)},IntersectionObserver2.prototype._registerInstance=function(){registry.indexOf(this)<0&&registry.push(this)},IntersectionObserver2.prototype._unregisterInstance=function(){var index=registry.indexOf(this);index!=-1&&registry.splice(index,1)};function now(){return window2.performance&&performance.now&&performance.now()}function throttle(fn,timeout){var timer=null;return function(){timer||(timer=setTimeout(function(){fn(),timer=null},timeout))}}function addEvent(node,event,fn,opt_useCapture){typeof node.addEventListener=="function"?node.addEventListener(event,fn,opt_useCapture||!1):typeof node.attachEvent=="function"&&node.attachEvent("on"+event,fn)}function removeEvent(node,event,fn,opt_useCapture){typeof node.removeEventListener=="function"?node.removeEventListener(event,fn,opt_useCapture||!1):typeof node.detatchEvent=="function"&&node.detatchEvent("on"+event,fn)}function computeRectIntersection(rect1,rect2){var top=Math.max(rect1.top,rect2.top),bottom=Math.min(rect1.bottom,rect2.bottom),left=Math.max(rect1.left,rect2.left),right=Math.min(rect1.right,rect2.right),width=right-left,height=bottom-top;return width>=0&&height>=0&&{top:top,bottom:bottom,left:left,right:right,width:width,height:height}}function getBoundingClientRect(el){var rect;try{rect=el.getBoundingClientRect()}catch(err){}
1return rect?(rect.width&&rect.height||(rect={top:rect.top,right:rect.right,bottom:rect.bottom,left:rect.left,width:rect.right-rect.left,height:rect.bottom-rect.top}),rect):getEmptyRect()}function getEmptyRect(){return{top:0,bottom:0,left:0,right:0,width:0,height:0}}function containsDeep(parent,child){for(var node=child;node;){if(node==parent)return!0;node=getParentNode(node)}return!1}function getParentNode(node){var parent=node.parentNode;return parent&&parent.nodeType==11&&parent.host?parent.host:parent}window2.IntersectionObserver=IntersectionObserver2,window2.IntersectionObserverEntry=IntersectionObserverEntry})(window,document);/*!
2 * rimg v2.1.2
3 * (c) 2018 Pixel Union
4 */(function(global,factory){typeof exports=="object"&&typeof module!="undefined"?module.exports=factory():typeof define=="function"&&define.amd?define(factory):global.rimg=factory()})(this,(function(){"use strict";function defaultTemplateRender(template,size){return template.replace("{size}",size.width+"x"+size.height)}var defaults={scale:1,template:!1,templateRender:defaultTemplateRender,max:{width:1/0,height:1/0},round:32,placeholder:!1};function getData(el,name,options,sanitize){var attr="data-rimg-"+name;if(!el.hasAttribute(attr))return options[name]||defaults[name];var value=el.getAttribute(attr);return sanitize?sanitize(value):value}function parseSize(value){return value=value.split("x"),{width:parseInt(value[0],10),height:parseInt(value[1],10)}}function parseItem(el){var options=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},isImage=el.hasAttribute("data-rimg-template");return{el:el,isImage:isImage,isBackgroundImage:isImage&&el.tagName!=="IMG",scale:getData(el,"scale",options),density:window.devicePixelRatio||1,template:getData(el,"template",options),templateRender:options.templateRender||defaults.templateRender,max:getData(el,"max",options,parseSize),round:getData(el,"round",options),placeholder:getData(el,"placeholder",options,parseSize)}}function roundSize(size,multiple){return Math.ceil(size/multiple)*multiple}function getElementSize(el){for(var size={width:0,height:0};el&&(size.width=el.offsetWidth,size.height=el.offsetHeight,!(size.width>20&&size.height>20));)el=el.parentNode;return size}function trigger(el,name){var event=document.createEvent("Event");return event.initEvent(name,!0,!0),!el.dispatchEvent(event)}function supportedDensity(item,size){return Math.min(Math.min(Math.max(item.max.width/size.width,1),item.density),Math.min(Math.max(item.max.height/size.height,1),item.density)).toFixed(2)}function setImage(item,size,isPlaceholder,onLoad){var render=item.templateRender,density=isPlaceholder?1:supportedDensity(item,size),round=isPlaceholder?1:item.round,width=roundSize(size.width*density,round),height=roundSize(size.height*density,round),ratio=Math.min(1,item.max.width/width,item.max.height/height),displaySize={width:Math.round(ratio*width),height:Math.round(ratio*height)},url=render(item.template,displaySize),image=new Image;image.onload=onLoad,image.src=url,item.isBackgroundImage?item.el.style.backgroundImage="url('"+url+"')":item.el.setAttribute("srcset",url+" "+density+"x")}function loadFullImage(item,size){var el=item.el;setImage(item,size,!1,function(event){event.type==="load"?el.setAttribute("data-rimg","loaded"):(el.setAttribute("data-rimg","error"),trigger(el,"rimg:error")),trigger(el,"rimg:load")})}function loadImage(item){var el=item.el,status=el.getAttribute("data-rimg");if(!(status==="loading"||status==="loaded")){if(!el.complete&&!item.isBackgroundImage){el.addEventListener("load",function cb(){el.removeEventListener("load",cb),loadImage(item)});return}if(!trigger(el,"rimg:loading")){el.setAttribute("data-rimg","loading");var size=getElementSize(item.el);size.width*=item.scale,size.height*=item.scale,item.placeholder?(item.isBackgroundImage||(el.setAttribute("width",Math.min(Math.floor(item.max.width/item.density),size.width)),el.setAttribute("height",Math.min(Math.floor(item.max.height/item.density),size.height))),setImage(item,item.placeholder,!0,function(){return loadFullImage(item,size)})):loadFullImage(item,size)}}}function load(el,options){if(el){trigger(el,"rimg:enter");var item=parseItem(el,options);
4item.isImage&&(item.isBackgroundImage||el.setAttribute("data-rimg-template-svg",el.getAttribute("srcset")),loadImage(item))}}function update(el,options){if(el){trigger(el,"rimg:update");var item=parseItem(el,options);item.isImage&&(item.isBackgroundImage||(el.setAttribute("data-rimg","lazy"),el.setAttribute("srcset",el.getAttribute("data-rimg-template-svg"))),loadImage(item))}}function inViewport(el){var root=document.documentElement,width=Math.min(root.clientWidth,window.innerWidth),height=Math.min(root.clientHeight,window.innerHeight),rect=el.getBoundingClientRect();return rect.bottom>=0&&rect.right>=0&&rect.top<=height&&rect.left<=width}function rimg2(){var selector=arguments.length>0&&arguments[0]!==void 0?arguments[0]:'[data-rimg="lazy"]',options=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},io=new IntersectionObserver(function(entries){entries.forEach(function(entry){(entry.isIntersecting||entry.intersectionRatio>0)&&(io.unobserve(entry.target),load(entry.target,options))})},{rootMargin:"20% 0px"}),api={track:function(){for(var selector2=arguments.length>0&&arguments[0]!==void 0?arguments[0]:'[data-rimg="lazy"]',els=querySelector(selector2),i=0;i<els.length;i++)inViewport(els[i])?load(els[i],options):io.observe(els[i])},update:function(){for(var selector2=arguments.length>0&&arguments[0]!==void 0?arguments[0]:'[data-rimg="loaded"]',els=querySelector(selector2),i=0;i<els.length;i++)update(els[i],options)},untrack:function(){for(var selector2=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"[data-rimg]",els=querySelector(selector2),i=0;i<els.length;i++)io.unobserve(els[i])},unload:function(){io.disconnect()}};return api.track(selector),api}function querySelector(selector){return typeof selector=="string"?document.querySelectorAll(selector):selector instanceof HTMLElement?[selector]:selector instanceof NodeList?selector:[]}return rimg2}));/*!
5 * rimg-shopify v2.2.2
6 * (c) 2018 Pixel Union
7 */(function(global,factory){typeof exports=="object"&&typeof module!="undefined"?module.exports=factory(require("rimg")):typeof define=="function"&&define.amd?define(["rimg"],factory):(global.rimg=global.rimg||{},global.rimg.shopify=factory(global.rimg))})(this,(function(rimg2){"use strict";rimg2=rimg2&&rimg2.hasOwnProperty("default")?rimg2.default:rimg2,Element.prototype.matches||(Element.prototype.matches=Element.prototype.matchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector||Element.prototype.oMatchesSelector||Element.prototype.webkitMatchesSelector||function(s){for(var matches=(this.document||this.ownerDocument).querySelectorAll(s),i=matches.length;--i>=0&&matches.item(i)!==this;);return i>-1});var state={init:init,watch:watch,unwatch:unwatch};function init(){var selector=arguments.length>0&&arguments[0]!==void 0?arguments[0]:'[data-rimg="lazy"]',options=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};state.selector=selector,state.instance=rimg2(selector,options),state.loadedWidth=Math.max(document.documentElement.clientWidth,window.innerWidth||0),document.addEventListener("shopify:section:load",function(event){return watch(event.target)}),window.addEventListener("resize",function(){return _update()}),document.addEventListener("shopify:section:unload",function(event){return unwatch(event.target)}),document.addEventListener("theme:rimg:watch",function(event){return watch(event.target)}),document.addEventListener("theme:rimg:unwatch",function(event){return unwatch(event.target)}),window.jQuery&&jQuery(document).on({"theme:rimg:watch":function(event){return watch(event.target)},"theme:rimg:unwatch":function(event){return unwatch(event.target)}})}function watch(el){typeof el.matches=="function"&&el.matches(state.selector)&&state.instance.track(el),state.instance.track(el.querySelectorAll(state.selector))}function unwatch(el){state.instance.untrack(el.querySelectorAll(state.selector)),typeof el.matches=="function"&&el.matches(state.selector)&&state.instance.untrack(el)}function _update(){var currentWidth=Math.max(document.documentElement.clientWidth,window.innerWidth||0);currentWidth/state.loadedWidth>.5&&currentWidth/state.loadedWidth<2||(state.loadedWidth=currentWidth,state.instance.update(
7))}return state}));/*!
8 * pxs-map v1.0.2
9 * (c) 2018 undefined
10 */(function(global,factory){typeof exports=="object"&&typeof module!="undefined"?module.exports=factory(require("jquery")):typeof define=="function"&&define.amd?define(["jquery"],factory):global.PxsMap=factory(global.$)})(this,(function($2){"use strict";$2=$2&&$2.hasOwnProperty("default")?$2.default:$2;var justDebounce=debounce;function debounce(fn,delay,at_start,guarantee){var timeout,args,self;return function(){if(self=this,args=Array.prototype.slice.call(arguments),timeout&&(at_start||guarantee))return;if(!at_start)return clear(),timeout=setTimeout(run,delay),timeout;timeout=setTimeout(clear,delay),fn.apply(self,args);function run(){clear(),fn.apply(self,args)}function clear(){clearTimeout(timeout),timeout=null}}}var classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")},createClass=(function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}return function(Constructor,protoProps,staticProps){return protoProps&&defineProperties(Constructor.prototype,protoProps),staticProps&&defineProperties(Constructor,staticProps),Constructor}})(),PxsMap2=(function(){function PxsMap3(section){var _this=this;classCallCheck(this,PxsMap3),this.$el=$2("[data-map]",section.el),this.settings=section.data,this.map=null,this.center=null,this.$container=$2("[data-map-container]",this.$el),this.zoom=11+parseInt(this.settings.zoom,10),isNaN(this.zoom)&&(this.zoom=13),this.colors=null,this.settings.colors&&(this.colors=this.settings.colors),this.resize=this.resize.bind(this),this.address=this.settings.address,this.apiKey=this.settings.api_key,this.apiKey&&(window.googleMaps===void 0?(window.googleMaps=!0,$2.getScript("https://maps.googleapis.com/maps/api/js?key="+this.apiKey).done(function(){_this._createMap()}).fail(function(status){console.error(status)})):this._createMap())}return createClass(PxsMap3,[{key:"_createMap",value:function(){var _this2=this;return this.geolocate().done(function(results){_this2.map=new google.maps.Map(_this2.$container.get(0),{center:results[0].geometry.location,clickableIcons:!1,disableDefaultUI:!0,disableDoubleClickZoom:!0,gestureHandling:"none",keyboardShortcuts:!1,maxZoom:_this2.zoom,minZoom:_this2.zoom,scrollWheel:!1,styles:_this2._getMapStyles(),zoom:_this2.zoom,zoomControl:!1}),_this2.center=_this2.map.getCenter(),_this2.map.panBy(0,0),new google.maps.Marker({clickable:!1,map:_this2.map,position:_this2.center}),google.maps.event.addDomListener(window,"resize",justDebounce(_this2.resize,250,!0,!0))}).fail(function(status){var usageLimits="https://developers.google.com/maps/faq#usagelimits",errorMessage=void 0;switch(status){case"ZERO_RESULTS":errorMessage="<p>Unable to find the address:</p> "+_this2.address;break;case"OVER_QUERY_LIMIT":errorMessage='\n              <p>Unable to load Google Maps, you have reached your usage limit.</p>\n              <p>\n                Please visit\n                <a href="'+usageLimits+'" target="_blank">'+usageLimits+"</a>\n                for more details.\n              </p>\n            ";break;default:errorMessage="Unable to load Google Maps.";break}_this2.displayErrorInThemeEditor(errorMessage,status)})}},{key:"geolocate",value:function(){var deferred=$2.Deferred(),geocoder=new google.maps.Geocoder;return geocoder.geocode({address:this.address},function(results,status){status!==google.maps.GeocoderStatus.OK&&deferred.reject(status),deferred.resolve(results)}),deferred}},{key:"resize",value:function(){this.map&&(google.maps.event.trigger(this.map,"resize"),this.map.setCenter(this.center),this.map.panBy(0,100))}},{key:"onSectionUnload",value:function(){this.map&&google.maps.event.clearListeners(this.map,"resize")}},{key:"_getMapStyles",value:function(){if(this.colors)return[{elementType:"geometry",stylers:[{color:this.colors.e}]},{elementType:"labels.icon",stylers:[{visibility:"off"}]},{elementType:"labels.text.fill",stylers:[{color:this.colors.a}]},{elementType:"labels.text.stroke",stylers:[{color:this.colors.e}]},{featureType:"administrative",elementType:"geometry",stylers:[{visibility:"off"}]},{featureType:"administrative.country",stylers:[{visibility:"off"}]},{featureType:"administrative.land_parcel",stylers:[{visibility:"off"}]},{featureType:"administrative.neighborhood",stylers:[{visibility:"off"}]},{featureType:"administrative.locality",stylers:[{visibility:"off"}]},{featureType:"poi",stylers:[{visibility:"off"}]},{featureType:"road",elementType:"geometry.fill",stylers:[{color:this.colors.d}]},{featureType:"road",elementType:"labels.icon",stylers:[{visibility:"off"}]},{featureType:"road.arterial",elementType:"geometry",stylers:[{color:this.colors.c}]},{featureType:"road.highway",elementType:"geometry",stylers:[{color:this.colors.b}]}
10,{featureType:"road.highway.controlled_access",stylers:[{visibility:"off"}]},{featureType:"road.local",elementType:"labels.text.fill",stylers:[{color:this.colors.b}]},{featureType:"road.local",elementType:"labels.text.stroke",stylers:[{color:this.colors.e}]},{featureType:"transit",stylers:[{visibility:"off"}]},{featureType:"water",elementType:"geometry",stylers:[{color:this.colors.f}]}]}},{key:"displayErrorInThemeEditor",value:function(errorMessage){var status=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",isThemeEditor=window.Shopify&&window.Shopify.designMode;isThemeEditor&&(this.$container.html('<div class="map-error-message">'+errorMessage+"</div>"),console.warn(errorMessage,status))}}]),PxsMap3})();return PxsMap2}));/*!
11 * pxs-video v1.0.0
12 * (c) 2018 Pixel Union
13 */(function(global,factory){typeof exports=="object"&&typeof module!="undefined"?module.exports=factory():typeof define=="function"&&define.amd?define(factory):global.PxsVideo=factory()})(this,(function(){"use strict";function createCommonjsModule(fn,module2){return module2={exports:{}},fn(module2,module2.exports),module2.exports}var script=createCommonjsModule(function(module2){/*!
14  * $script.js JS loader & dependency manager
15  * https://github.com/ded/script.js
16  * (c) Dustin Diaz 2014 | License MIT
17  */(function(name,definition){module2.exports?module2.exports=definition():this[name]=definition()})("$script",function(){var doc=document,head=doc.getElementsByTagName("head")[0],s="string",f=!1,push="push",readyState="readyState",onreadystatechange="onreadystatechange",list={},ids={},delay={},scripts={},scriptpath,urlArgs;function every(ar,fn){for(var i=0,j=ar.length;i<j;++i)if(!fn(ar[i]))return f;return 1}function each(ar,fn){every(ar,function(el){return!fn(el)})}function $script(paths,idOrDone,optDone){paths=paths[push]?paths:[paths];var idOrDoneIsDone=idOrDone&&idOrDone.call,done=idOrDoneIsDone?idOrDone:optDone,id=idOrDoneIsDone?paths.join(""):idOrDone,queue=paths.length;function loopFn(item){return item.call?item():list[item]}function callback(){if(!--queue){list[id]=1,done&&done();for(var dset in delay)every(dset.split("|"),loopFn)&&!each(delay[dset],loopFn)&&(delay[dset]=[])}}return setTimeout(function(){each(paths,function loading(path,force){if(path===null)return callback();if(!force&&!/^https?:\/\//.test(path)&&scriptpath&&(path=path.indexOf(".js")===-1?scriptpath+path+".js":scriptpath+p
17ath),scripts[path])return scripts[path]==2?callback():setTimeout(function(){loading(path,!0)},0);scripts[path]=1,create(path,callback)})},0),$script}function create(path,fn){var el=doc.createElement("script"),loaded;el.onload=el.onerror=el[onreadystatechange]=function(){el[readyState]&&!/^c|loade/.test(el[readyState])||loaded||(el.onload=el[onreadystatechange]=null,loaded=1,scripts[path]=2,fn())},el.async=1,el.src=urlArgs?path+(path.indexOf("?")===-1?"?":"&")+urlArgs:path,head.insertBefore(el,head.lastChild)}return $script.get=create,$script.order=function(scripts2,id,done){(function callback(s2){s2=scripts2.shift(),scripts2.length?$script(s2,callback):$script(s2,id,done)})()},$script.path=function(p){scriptpath=p},$script.urlArgs=function(str){urlArgs=str},$script.ready=function(deps,ready,req){deps=deps[push]?deps:[deps];var missing=[];return!each(deps,function(dep){list[dep]||missing[push](dep)})&&every(deps,function(dep){return list[dep]})?ready():(function(key){delay[key]=delay[key]||[],delay[key][push](ready),req&&req(missing)})(deps.join("|")),$script},$script.done=function(idOrDone){$script([null],idOrDone)},$script})}),classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")},createClass=(function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}return function(Constructor,protoProps,staticProps){return protoProps&&defineProperties(Constructor.prototype,protoProps),staticProps&&defineProperties(Constructor,staticProps),Constructor}})(),api="https://www.youtube.com/iframe_api",apiLoadedCallbacks=[],apiLoaded=!1;window.onYouTubeIframeAPIReady=function(){apiLoadedCallbacks.forEach(function(apiLoadedCallback){return apiLoadedCallback()}),apiLoadedCallbacks=[],apiLoaded=!0};var Youtube=(function(){function Youtube2(el,id){classCallCheck(this,Youtube2),this.el=el,this.id=id,this.iframeEl=document.createElement("div"),this.el.appendChild(this.iframeEl),this.onApiLoaded=this._onApiLoaded.bind(this),this.isReady=!1,this.onReady=this._onReady.bind(this),this.onReadyCallback=null,this.onStateChange=this._onStateChange.bind(this),this.onPlayCallback=null,apiLoaded?this._onApiLoaded():(apiLoadedCallbacks.push(this.onApiLoaded),script(api))}return createClass(Youtube2,[{key:"play",value:function(){var _this=this;return new Promise(function(resolve){_this.onPlayCallback=resolve,_this.isReady?_this.player.playVideo():_this.onReadyCallback=function(){return _this.player.playVideo()}})}},{key:"unload",value:function(){this.player.destroy()}},{key:"_onApiLoaded",value:function(){this.player=new YT.Player(this.iframeEl,{videoId:this.id,playerVars:{modestbranding:!0,showinfo:!1,controls:!1},events:{onReady:this.onReady,onStateChange:this.onStateChange}})}},{key:"_onReady",value:function(){this.isReady=!0,this.onReadyCallback&&this.onReadyCallback()}},{key:"_onStateChange",value:function(event){var state=event.data;this.onPlayCallback&&state===YT.PlayerState.PLAYING&&(this.onPlayCallback(),this.onPlayCallback=null)}}]),Youtube2})(),api$1="https://player.vimeo.com/api/player.js",apiLoaded$1=!1,VimeoPlayer=(function(){function VimeoPlayer2(el,id){classCallCheck(this,VimeoPlayer2),this.el=el,this.id=id,this.onApiLoaded=this._onApiLoaded.bind(this),this.onProgress=this._onProgress.bind(this),this.onProgressCallback=null,apiLoaded$1?this._onApiLoaded():script(api$1,this.onApiLoaded)}return createClass(VimeoPlayer2,[{key:"play",value:function(){var _this=this;return new Promise(function(resolve){_this.onProgressCallback=resolve,_this.player.on("progress",_this.onProgress),_this.player.play()})}},{key:"unload",value:function(){this.player.unload().catch()}},{key:"_onApiLoaded",value:function(){this.player=new window.Vimeo.Player(this.el,{id:this.id}),this.player.ready().catch(),apiLoaded$1=!0}},{key:"_onProgress",value:function(){this.player.off("progress",this.onProgress),this.onProgressCallback&&(this.onProgressCallback(),this.onProgressCallback=null)}}]),VimeoPlayer2})(),optionsDefaults={autoplay:!1},Video=(function(){function Video2(el){var options=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};classCallCheck(this,Video2),this.el=el,this.playButton=el.querySelector("[data-vi
17deo-play-button]"),this.onPlayButtonClick=this._play.bind(this),this.video=null;var autoplay=options.autoplay||optionsDefaults.autoplay,videoEl=el.querySelector("[data-video]"),type=videoEl.getAttribute("data-video"),id=videoEl.getAttribute("data-video-id");switch(type){case"youtube":this.video=new Youtube(videoEl,id);break;case"vimeo":this.video=new VimeoPlayer(videoEl,id);break;default:this.video=null;break}this.playButton&&this.playButton.addEventListener("click",this.onPlayButtonClick),autoplay&&this._play()}return createClass(Video2,[{key:"_play",value:function(){var _this=this;this.el.classList.add("video-loading"),this.video.play().then(function(){_this.el.classList.add("video-transitioning"),setTimeout(function(){_this.el.classList.remove("video-loading"),_this.el.classList.remove("video-transitioning"),_this.el.classList.add("video-playing")},200)})}},{key:"unload",value:function(){this.playButton&&this.playButton.removeEventListener("click",this.onPlayClick),this.video&&this.video.unload()}}]),Video2})(),PxsVideo2=(function(){function PxsVideo3(section){classCallCheck(this,PxsVideo3),this.video=null;var el=section.el.querySelector("[data-video-container]"),data=section.data;el&&(this.video=new Video(el,{autoplay:data.autoplay}))}return createClass(PxsVideo3,[{key:"onSectionUnload",value:function(){this.video&&this.video.unload()}}]),PxsVideo3})();return PxsVideo2})),window.ThemeView=(function(superClass){extend(ThemeView2,superClass);function ThemeView2(){return ThemeView2.__super__.constructor.apply(this,arguments)}return ThemeView2.prototype.el=document.body,ThemeView2.prototype.initialize=function(){var body;return body=$(document.body),this.isHome=body.hasClass("template-index"),this.isProduct=body.hasClass("template-product"),this.isCollection=body.hasClass("template-collection"),this.isBlog=body.hasClass("template-blog"),this.isSearch=body.hasClass("template-search"),this.isPasswordPage=body.hasClass("template-password"),this.isGiftCardPage=body.hasClass("gift-card-template"),this.hasArticle=body.find(".article-meta-wrap"),rimg.shopify.init()},ThemeView2.prototype.render=function(){var j,l,len,len1,ref,ref1,results,rte,select;for(this.sections=new ThemeEditor,this.sections.register("header",this.headerSetup(this.sections)),this.sections.register("pxs-map",this.mapSetup(this.sections)),this.sections.register("pxs-video",this.videoSetup(this.sections)),this.sections.register("static-product",this.productSetup(this.sections)),this.sections.register("home-product",this.productSetup(this.sections)),ref=$(".rte"),j=0,len=ref.length;j<len;j++)rte=ref[j],new RTEView({el:rte});for(Theme.currencySwitcher&&(this.currencyView=new CurrencyView({el:this.$el})),this.isHome&&new HomeView({el:this.$el}),this.isCollection&&new CollectionView({el:this.$el}),this.isBlog&&new BlogView({el:this.$el}),this.isSearch&&new ProductListView({el:$("#search-results")}),this.hasArticle&&new ShareView({el:this.$el}),this.isPasswordPage&&new PasswordView({el:this.$el}),this.isGiftCardPage&&new GiftCardView,new QuickShopView({el:this.$el}),ref1=$("select"),results=[],l=0,len1=ref1.length;l<len1;l++)select=ref1[l],results.push(new SelectView({el:select}));return results},ThemeView2.prototype.headerSetup=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new HeaderView({el:$(".main-header")})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),!this.instances[instance.sectionId])return this.init(instance)},onSectionUnload:function(event){var instance;return instance=sections.getInstance(event),this.instances[instance.sectionId].prepareRemove(),this.instances[instance.sectionId].remove(),delete this.instances[instance.sectionId]}}},ThemeView2.prototype.mapSetup=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new PxsMap({el:instance.el,data:instance.data})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),!this.instances[instance.sectionId])return this.init(instance)},onSectionUnload:function(event){var instance;return instance=sections.getInstance(event),this.instances[instance.sectionId].onSectionUnload(),delete this.instances[instance.sectionId]}}},ThemeView2.prototype.videoSetup=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new PxsVideo({el:instance.el,data:instance.data})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),!this.instances[instance.sectionId])return this.init(instance)},onSectionUnload:function(event){var instance;return instance=sections.getInstance(event),this.instances[instance.sectionId].onSectionUnload(),delete this.instances[instance.sectionId]}}},ThemeView2.prototype.productSetup=function(sections){return{instances:{},init:function(instance){return this.instances[instance.sectionId]=new Product({el:instance.el,data:instance.data})},onSectionLoad:function(event){var instance;if(instance=sections.getInstance(event),!this.instances[instance.sectionId])return this.init(instance)},onSectionUnload:function(event){var instance;return instance=sections.getInstance(event),this.instances[instance.sectionId].onSectionUnload(),delete this.instances[instance.sectionId]}}},ThemeView2})(Backbone.View),$(function(){return window.theme=new ThemeView,window.theme.render()});
18//# sourceMappingURL=/cdn/shop/t/6/assets/theme.js.map?v=60479426504909131751544469251

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.