1(function(){var __sections__={};(function(){for(var i=0,s=document.getElementById("sections-script").getAttribute("data-sections").split(",");i<s.length;i++)__sections__[s[i]]=!0})(),(function(){if(!(!__sections__["custom-terracycle-cards"]&&!Shopify.designMode))try{(function(){$(document).ready(function(){var colsLarge=4,colsMedium=2,colsSmall=1,lowBreakLarge=1e3,lowBreakMedium=500,stagePadding=50,carOptions={stagePadding:Number(stagePadding),margin:10,loop:!1,responsive:{0:{items:1},767:{items:3},1200:{items:5}}};$(".owl-carousel").owlCarousel(carOptions),Shopify.derm_custom.handleOwlSideScroll($(".owl-carousel")),$(".owl-carousel").find("li.item").each(function(){$(this).css("min-height",$(this).parent().parent().parent().height()+"px")}),$(window).resize(function(){$(".owl-carousel").find("li.item").each(function(){$(this).css("min-height",$(this).parent().parent().parent().height()+"px")})})})})()}catch(e){console.error(e)}})(),(function(){if(__sections__.footer)try{class LocalizationForm extends HTMLElement{constructor(){super(),this.elements={input:this.querySelector('input[name="locale_code"], input[name="country_code"]'),button:this.querySelector("button"),panel:this.querySelector(".disclosure__list-wrapper")},this.elements.button.addEventListener("click",this.openSelector.bind(this)),this.elements.button.addEventListener("focusout",this.closeSelector.bind(this)),this.addEventListener("keyup",this.onContainerKeyUp.bind(this)),this.querySelectorAll("a").forEach(item=>item.addEventListener("click",this.onItemClick.bind(this)))}hidePanel(){this.elements.button.setAttribute("aria-expanded","false"),this.elements.panel.setAttribute("hidden",!0)}onContainerKeyUp(event){event.code.toUpperCase()==="ESCAPE"&&(this.hidePanel(),this.elements.button.focus())}onItemClick(event){event.preventDefault();const form=this.querySelector("form");this.elements.input.value=event.currentTarget.dataset.value,form&&form.submit()}openSelector(){this.elements.button.focus(),this.elements.panel.toggleAttribute("hidden"),this.elements.button.setAttribute("aria-expanded",(this.elements.button.getAttribute("aria-expanded")==="false").toString())}closeSelector(event){const shouldClose=event.relatedTarget&&event.relatedTarget.nodeName==="BUTTON";(event.relatedTarget===null||shouldClose)&&this.hidePanel()}}customElements.define("localization-form",LocalizationForm)}catch(e){console.error(e)}})(),(function(){if(__sections__.header)try{class StickyHeader extends HTMLElement{constructor(){super()}connectedCallback(){this.header=document.getElementById("shopify-section-header"),this.headerBounds={},this.currentScrollTop=0,this.preventReveal=!1,this.predictiveSearch=this.querySelector("predictive-search"),this.onScrollHandler=this.onScroll.bind(this),this.hideHeaderOnScrollUp=()=>this.preventReveal=!0,this.addEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),window.addEventListener("scroll",this.onScrollHandler,!1),this.createObserver()}disconnectedCallback(){this.removeEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),window.removeEventListener("scroll",this.onScrollHandler)}createObserver(){new IntersectionObserver((entries,observer2)=>{this.headerBounds=entries[0].intersectionRect,observer2.disconnect()}).observe(this.header)}onScroll(){const scrollTop=window.pageYOffset||document.documentElement.scrollTop;if(!(this.predictiveSearch&&this.predictiveSearch.isOpen)&&!this.dangDoi){if(scrollTop<=this.headerBounds.top){requestAnimationFrame(this.reset.bind(this)),this.currentScrollTop=scrollTop;return}if(!(Math.abs(scrollTop-this.currentScrollTop)<6)){if(scrollTop>this.currentScrollTop&&scrollTop>this.headerBounds.bottom){if(this.preventHide)return;requestAnimationFrame(this.hide.bind(this))}else scrollTop<this.currentScrollTop&&scrollTop>this.headerBounds.bottom?this.preventReveal?(window.clearTimeout(this.isScrolling),this.isScrolling=setTimeout(()=>{this.preventReveal=!1},66),requestAnimationFrame(this.hide.bind(this))):requestAnimationFrame(this.reveal.bind(this)):scrollTop<=this.headerBounds.top&&requestAnimationFrame(this.reset.bind(this));this.currentScrollTop=scrollTop}}}hide(){const doiTrangThai=!this.header.classList.contains("eg-header-gon");this.header.classList.add("shopify-section-header-sticky","eg-header-gon"),this.closeMenuDisclosure(),this.closeSearchModal(),doiTrangThai&&this.khoaLucChuyenDong()}reveal(){const doiTrangThai=this.header.classList.contains("eg-header-gon");this.header.classList.add("shopify-section-header-sticky","animate"),this.header.classList.remove("shopify-section-header-hidden","eg-header-gon"),doiTrangThai&&this.khoaLucChuyenDong()}khoaLucChuyenDong(){this.dangDoi=!0,window.clearTimeout(this.henMoKhoa),this.henMoKhoa=setTimeout(()=>{this.dangDoi=!1,this.currentScrollTop=window.pageYOffset||document.documentElement.scrollTop},350)}reset(){this.header.classList.remove("shopify-section-header-hidden","shopify-section-header-sticky","animate","eg-header-gon")}closeMenuDisclosure(){this.disclosures=this.disclosures||this.header.querySelectorAll("header-menu"),this.disclosures.forEac
1h(disclosure=>disclosure.close())}closeSearchModal(){this.searchModal=this.searchModal||this.header.querySelector("details-modal"),this.searchModal.close(!1)}}customElements.define("sticky-header",StickyHeader)}catch(e){console.error(e)}})(),(function(){if(__sections__["main-collection-product-grid-derm-custom"])try{document.addEventListener("DOMContentLoaded",function(event){var luoiBanLe=document.querySelector("#ProductGridContainer");luoiBanLe&&luoiBanLe.addEventListener("click",function(e){if(e.target.classList.contains("collection--description-more-link")){console.log("RUN");const truncated_description=document.querySelector(".collection--description--short"),full_description=document.querySelector(".collection--description--full");truncated_description.style.display==="none"?(console.log("1111"),truncated_description.style.display="block",full_description.style.display="none"):(console.log("2222"),truncated_description.style.display="none",full_description.style.display="block")}})})}catch(e){console.error(e)}})(),(function(){if(__sections__["main-collection-product-grid"])try{document.addEventListener("DOMContentLoaded",function(event){document.querySelector("#ProductGridContainer").addEventListener("click",function(e){if(e.target.classList.contains("collection--description-more-link")){const truncated_description=document.querySelector(".collection--description--short"),full_description=document.querySelector(".collection--description--full");truncated_description.style.display==="none"?(truncated_description.style.display="block",full_description.style.display="none"):(truncated_description.style.display="none",full_description.style.display="block")}})})}catch(e){console.error(e)}})(),(function(){if(__sections__["product-recommendations"])try{class ProductRecommendations extends HTMLElement{constructor(){super();const handleIntersection=(entries,observer)=>{entries[0].isIntersecting&&(observer.unobserve(this),fetch(this.dataset.url).then(response=>response.text()).then(text=>{const html=document.createElement("div");html.innerHTML=text;const recommendations=html.querySelector("product-recommendations");recommendations&&recommendations.innerHTML.trim().length&&(this.innerHTML=recommendations.innerHTML),html.querySelector(".grid__item")&&this.classList.add("product-recommendations--loaded")}).catch(e=>{console.error(e)}))};new IntersectionObserver(handleIntersection.bind(this),{rootMargin:"0px 0px 200px 0px"}).observe(this)}}customElements.define("product-recommendations",ProductRecommendations)}catch(e){console.error(e)}})()})(); 2//# sourceMappingURL=/cdn/shop/t/19/compiled_assets/scripts.js.map?v=13662804282025885571790949269
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.