PageSourceSearch

https://scentsorie.com/cdn/shop/t/69/compiled_assets/scripts.js?v=75450346688532194951783114931

js scentsorie.com collected 2026-10-07 03:06:37 UTC 14,586 bytes, 2 lines download raw bytes

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__.header)try{class StickyHeader extends HTMLElement{constructor(){super(),this.header=null,this.headerSection=null,this.headerBounds={top:0,bottom:0},this.currentScrollTop=0,this.preventReveal=!1,this.preventHide=!1,this.isScrolling=null,this.predictiveSearch=null,this._rafScroll=0,this._pendingScrollTop=0,this._state="reset",this.THRESHOLD_EPS=4,this._started=!1,this.onScroll=this.onScroll.bind(this),this._runScroll=this._runScroll.bind(this),this._measure=this._measure.bind(this),this._start=this._start.bind(this),this.hideHeaderOnScrollUp=()=>{this.preventReveal=!0},this._wakeOnScroll=this._wakeOnScroll.bind(this),this._wakeOnPointer=this._wakeOnPointer.bind(this),this._wakeOnKey=this._wakeOnKey.bind(this),this._onResize=this._onResize.bind(this),this._ensureStartedOnResize=this._ensureStartedOnResize.bind(this),this._resizeTimer=0}_getDocumentTop(el){let top=0,node=el;for(;node;)top+=node.offsetTop||0,node=node.offsetParent;return top}connectedCallback(){window.addEventListener("scroll",this._wakeOnScroll,{passive:!0,once:!0}),window.addEventListener("pointerdown",this._wakeOnPointer,{passive:!0,once:!0}),window.addEventListener("touchstart",this._wakeOnPointer,{passive:!0,once:!0}),window.addEventListener("keydown",this._wakeOnKey,{passive:!0,once:!0}),window.addEventListener("resize",this._ensureStartedOnResize,{passive:!0})}disconnectedCallback(){window.removeEventListener("scroll",this._wakeOnScroll),window.removeEventListener("pointerdown",this._wakeOnPointer),window.removeEventListener("touchstart",this._wakeOnPointer),window.removeEventListener("keydown",this._wakeOnKey),window.removeEventListener("resize",this._ensureStartedOnResize),window.removeEventListener("scroll",this.onScroll),window.removeEventListener("resize",this._onResize),this.removeEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),this._rafScroll&&cancelAnimationFrame(this._rafScroll),this._rafScroll=0,this._resizeTimer&&clearTimeout(this._resizeTimer),this._resizeTimer=0}_onResize(){this._resizeTimer&&clearTimeout(this._resizeTimer),this._resizeTimer=setTimeout(()=>
1{if(this._resizeTimer=0,!this._started||!this.header)return;this._measure(),this.currentScrollTop=window.pageYOffset||document.documentElement.scrollTop||0;const eps=this.THRESHOLD_EPS;this.currentScrollTop<=this.headerBounds.top+eps&&this._setState("reset"),this.onScroll()},120)}_wakeOnScroll(){this._start()}_wakeOnPointer(){this._start()}_wakeOnKey(){this._start()}_ensureStartedOnResize(){this._started||this._start()}_start(){this._started||(window.removeEventListener("pointerdown",this._wakeOnPointer),window.removeEventListener("touchstart",this._wakeOnPointer),window.removeEventListener("keydown",this._wakeOnKey),this.header=document.getElementById("shopify-section-header")||document.querySelector(".shopify-section-header")||null,this.header&&(this._started=!0,window.removeEventListener("resize",this._ensureStartedOnResize),this.headerSection=this.header.querySelector(".header-section")||this.header,this.predictiveSearch=this.querySelector("predictive-search"),this.addEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),this._measure(),window.addEventListener("scroll",this.onScroll,{passive:!0}),window.addEventListener("resize",this._onResize,{passive:!0}),this.onScroll()))}_measure(){if(!this.header)return;const outerH=Math.ceil(this.header.getBoundingClientRect().height||0),innerH=this.headerSection?Math.ceil(this.headerSection.getBoundingClientRect().height||0):0,h=Math.max(outerH,innerH),next=`${h}px`;document.documentElement.style.getPropertyValue("--header-height")!==next&&document.documentElement.style.setProperty("--header-height",next);const top=this.headerSection?this._getDocumentTop(this.headerSection):0;this.headerBounds={top,bottom:top+h}}onScroll(){this._pendingScrollTop=window.pageYOffset||document.documentElement.scrollTop||0,!this._rafScroll&&(this._rafScroll=requestAnimationFrame(this._runScroll))}_runScroll(){this._rafScroll=0;const scrollTop=this._pendingScrollTop;if(this.predictiveSearch&&this.predictiveSearch.isOpen){this.currentScrollTop=scrollTop;return}if(window.getComputedStyle(this.header).display==="none"){this.currentScrollTop=scrollTop;return}const layoutRect=this.headerSection?.getBoundingClientRect();if(!layoutRect||layoutRect.height<1){this.currentScrollTop=scrollTop;return}const eps=this.THRESHOLD_EPS;let hb=this.headerBounds;if(hb.bottom>hb.top+eps||(this._measure(),hb=this.headerBounds),!(hb.bottom>hb.top+eps)){this.currentScrollTop=scrollTop;return}const pastBottom=scrollTop>hb.bottom+eps,beforeTop=scrollTop<=hb.top+eps;if(!pastBottom){beforeTop?this._setState("reset"):scrollTop<this.currentScrollTop?this._setState("revealed"):this._setState("reset"),this.currentScrollTop=scrollTop;return}scrollTop>this.currentScrollTop&&pastBottom?this.preventHide||this._setState("hidden"):scrollTop<this.currentScrollTop&&pastBottom?this.preventReveal?(clearTimeout(this.isScrolling),this.isScrolling=setTimeout(()=>{this.preventReveal=!1},66),this._setState("hidden")):this._setState("revealed"):beforeTop&&this._setState("reset"),this.currentScrollTop=scrollTop}_setState(next){if(!(!this.header||this._state===next)){if(this._state=next,next==="hidden"){this.header.classList.add("shopify-section-header-hidden","shopify-section-header-sticky");return}if(next==="revealed"){this.header.classList.add("shopify-section-header-sticky","animate"),this.header.classList.remove("shopify-section-header-hidden");return}this.header.classList.remove("shopify-section-header-hidden","shopify-section-header-sticky","animate")}}}customElements.define("sticky-header",StickyHeader)}catch(e){console.error(e)}})(),(function(){if(__sections__["mobile-header"])try{class MobileStickyHeader extends HTMLElement{constructor(){super(),this._onLayoutResize=this._onLayoutResize.bind(this),this._layoutResizeTimer=0}connectedCallback(){this.header=document.getElementById("shopify-section-mobile-header")||this.closest(".shopify-section-mobile-header"),this.header&&(this.headerSection=this.header.querySelector(".mobile-header"),this.headerSection&&(this.headerBounds={},this.currentScrollTop=0,this.preventReveal=!1,this.preventHide=!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),window.addEventListener("resize",this._onLayoutResize,{passive:!0}),this.createObserver()))}disconnectedCallback(){this.removeEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),window.removeEventListener("scroll",this.onScrollHandler),window.removeEventListener("resize",this._onLayoutResize),this._layoutRe
1sizeTimer&&clearTimeout(this._layoutResizeTimer),this._layoutResizeTimer=0}_onLayoutResize(){this._layoutResizeTimer&&clearTimeout(this._layoutResizeTimer),this._layoutResizeTimer=setTimeout(()=>{this._layoutResizeTimer=0,!(!this.header||!this.headerSection)&&window.matchMedia("(max-width: 920px)").matches&&(this.createObserver(),this.onScrollHandler())},120)}createObserver(){new IntersectionObserver((entries,observer2)=>{this.headerBounds=entries[0].intersectionRect,observer2.disconnect()}).observe(this.headerSection)}onScroll(){const scrollTop=window.pageYOffset||document.documentElement.scrollTop;if(!(this.predictiveSearch&&this.predictiveSearch.isOpen)){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(){this.header.classList.add("shopify-section-mobile-header-hidden","shopify-section-mobile-header-sticky")}reveal(){this.header.classList.add("shopify-section-mobile-header-sticky","animate"),this.header.classList.remove("shopify-section-mobile-header-hidden")}reset(){this.header.classList.remove("shopify-section-mobile-header-hidden","shopify-section-mobile-header-sticky","animate")}}customElements.define("mobile-sticky-header",MobileStickyHeader)}catch(e){console.error(e)}})(),(function(){if(__sections__["secondary-header"])try{class StickySecondaryHeader extends HTMLElement{constructor(){super(),this.header=null,this.headerSection=null,this.currentScrollTop=0,this.preventReveal=!1,this.preventHide=!1,this.isScrolling=null,this.predictiveSearch=null,this._rafScroll=0,this._pendingScrollTop=0,this._state="reset",this.headerBounds={top:0,bottom:0},this.THRESHOLD_EPS=4,this._started=!1,this.onScroll=this.onScroll.bind(this),this._runScroll=this._runScroll.bind(this),this._measure=this._measure.bind(this),this._start=this._start.bind(this),this.hideHeaderOnScrollUp=()=>{this.preventReveal=!0},this._wakeOnScroll=this._wakeOnScroll.bind(this),this._wakeOnPointer=this._wakeOnPointer.bind(this),this._wakeOnKey=this._wakeOnKey.bind(this),this._onResize=this._onResize.bind(this),this._ensureStartedOnResize=this._ensureStartedOnResize.bind(this),this._resizeTimer=0}_getDocumentTop(el){let top=0,node=el;for(;node;)top+=node.offsetTop||0,node=node.offsetParent;return top}connectedCallback(){window.addEventListener("scroll",this._wakeOnScroll,{passive:!0,once:!0}),window.addEventListener("pointerdown",this._wakeOnPointer,{passive:!0,once:!0}),window.addEventListener("touchstart",this._wakeOnPointer,{passive:!0,once:!0}),window.addEventListener("keydown",this._wakeOnKey,{passive:!0,once:!0}),window.addEventListener("resize",this._ensureStartedOnResize,{passive:!0})}disconnectedCallback(){window.removeEventListener("scroll",this._wakeOnScroll),window.removeEventListener("pointerdown",this._wakeOnPointer),window.removeEventListener("touchstart",this._wakeOnPointer),window.removeEventListener("keydown",this._wakeOnKey),window.removeEventListener("resize",this._ensureStartedOnResize),window.removeEventListener("scroll",this.onScroll),window.removeEventListener("resize",this._onResize),this.removeEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),this._rafScroll&&cancelAnimationFrame(this._rafScroll),this._rafScroll=0,this._resizeTimer&&clearTimeout(this._resizeTimer),this._resizeTimer=0}_onResize(){this._resizeTimer&&clearTimeout(this._resizeTimer),this._resizeTimer=setTimeout(()=>
1{if(this._resizeTimer=0,!this._started||!this.header)return;this._measure(),this.currentScrollTop=window.pageYOffset||document.documentElement.scrollTop||0;const eps=this.THRESHOLD_EPS;this.currentScrollTop<=this.headerBounds.top+eps&&this._setState("reset"),this.onScroll()},120)}_wakeOnScroll(){this._start()}_wakeOnPointer(){this._start()}_wakeOnKey(){this._start()}_ensureStartedOnResize(){this._started||this._start()}_start(){this._started||(window.removeEventListener("pointerdown",this._wakeOnPointer),window.removeEventListener("touchstart",this._wakeOnPointer),window.removeEventListener("keydown",this._wakeOnKey),this.header=this.closest(".shopify-section-header"),this.header&&(this._started=!0,window.removeEventListener("resize",this._ensureStartedOnResize),this.headerSection=this.header.querySelector(".secondary-header-section")||this.header.querySelector(".header-section")||this.header,this.predictiveSearch=this.querySelector("predictive-search"),this.addEventListener("preventHeaderReveal",this.hideHeaderOnScrollUp),this._measure(),window.addEventListener("scroll",this.onScroll,{passive:!0}),window.addEventListener("resize",this._onResize,{passive:!0}),this.onScroll()))}_measure(){if(!this.header)return;const outerH=Math.ceil(this.header.getBoundingClientRect().height||0),innerH=this.headerSection?Math.ceil(this.headerSection.getBoundingClientRect().height||0):0,h=Math.max(outerH,innerH),next=`${h}px`,primarySticky=document.querySelector("sticky-header");primarySticky&&this.header&&!this.header.contains(primarySticky)||document.documentElement.style.getPropertyValue("--header-height")!==next&&document.documentElement.style.setProperty("--header-height",next);const top=this.headerSection?this._getDocumentTop(this.headerSection):0;this.headerBounds={top,bottom:top+h}}onScroll(){this._pendingScrollTop=window.pageYOffset||document.documentElement.scrollTop||0,!this._rafScroll&&(this._rafScroll=requestAnimationFrame(this._runScroll))}_runScroll(){this._rafScroll=0;const scrollTop=this._pendingScrollTop;if(this.predictiveSearch&&this.predictiveSearch.isOpen){this.currentScrollTop=scrollTop;return}if(window.getComputedStyle(this.header).display==="none"){this.currentScrollTop=scrollTop;return}const layoutRect=this.headerSection?.getBoundingClientRect();if(!layoutRect||layoutRect.height<1){this.currentScrollTop=scrollTop;return}const eps=this.THRESHOLD_EPS;let hb=this.headerBounds;if(hb.bottom>hb.top+eps||(this._measure(),hb=this.headerBounds),!(hb.bottom>hb.top+eps)){this.currentScrollTop=scrollTop;return}const pastBottom=scrollTop>hb.bottom+eps,beforeTop=scrollTop<=hb.top+eps;if(scrollTop<=hb.bottom+eps){this._setState("reset"),this.currentScrollTop=scrollTop;return}scrollTop>this.currentScrollTop&&pastBottom?this.preventHide||this._setState("hidden"):scrollTop<this.currentScrollTop&&pastBottom?this.preventReveal?(clearTimeout(this.isScrolling),this.isScrolling=setTimeout(()=>{this.preventReveal=!1},66),this._setState("hidden")):this._setState("revealed"):beforeTop&&this._setState("reset"),this.currentScrollTop=scrollTop}_setState(next){if(!(!this.header||this._state===next)){if(this._state=next,next==="hidden"){this.header.classList.add("shopify-section-header-hidden","shopify-section-header-sticky");return}if(next==="revealed"){this.header.classList.add("shopify-section-header-sticky","animate"),this.header.classList.remove("shopify-section-header-hidden");return}this.header.classList.remove("shopify-section-header-hidden","shopify-section-header-sticky","animate")}}}customElements.define("sticky-secondary-header",StickySecondaryHeader)}catch(e){console.error(e)}})()})();
2//# sourceMappingURL=/cdn/shop/t/69/compiled_assets/scripts.js.map?v=75450346688532194951783114931

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.