PageSourceSearch

https://www.eminent.com/cdn/shop/t/14/assets/custom.js?v=126912187105407954141776099795

js eminent.com collected 2026-10-03 23:39:03 UTC 7,650 bytes, 2 lines download raw bytes

1(function(){if(typeof window.jQuery>"u"){var script=document.createElement("script");script.src="https://code.jquery.com/jquery-3.6.0.min.js",script.type="text/javascript",script.onload=function(){jQuery(document).ready(function(){var toggleBtn=jQuery(".sort-header"),sortList=jQuery(".custom-sort-list"),closeBtn=jQuery(".sort-close");jQuery(document).on("click",".sort-header",function(){jQuery(this).toggleClass("active");var container=jQuery(this).closest(".custom-sort-container"),sortList2=container.find(".custom-sort-list"),closeBtn2=container.find(".sort-close");sortList2.stop(!0,!0).slideToggle(200),closeBtn2.toggle()}),jQuery(document).on("click",".sort-close",function(){var container=jQuery(this).closest(".custom-sort-container"),sortList2=container.find(".custom-sort-list"),toggleBtn2=container.find(".sort-header");toggleBtn2.removeClass("active"),sortList2.stop(!0,!0).slideUp(200),closeBtn.hide()}),jQuery(document).on("click",".custom-sort-list-items li",function(){var sortValue=jQuery(this).data("value"),url=new URL(window.location.href);url.searchParams.set("sort_by",sortValue),window.location.href=url.toString()}),jQuery(document).on("click",function(e){jQuery(e.target).closest(".custom-sort-container").length||(toggleBtn.removeClass("active"),sortList.stop(!0,!0).slideUp(200),closeBtn.hide())})})},document.head.appendChild(script)}})(),(function(){var drawer=document.getElementById("filterDrawer");drawer&&(drawer.querySelectorAll('input[type="checkbox"][id]').forEach(function(input){input.removeAttribute("id")}),drawer.querySelectorAll("label[for]").forEach(function(label){label.removeAttribute("for")}))})(),document.addEventListener("input",function(e){var drawer=document.getElementById("filterDrawer");drawer&&drawer.classList.contains("open")&&e.target.closest("#filterDrawer")&&e.target.type==="checkbox"&&e.stopImmediatePropagation()},!0);function applyDrawerFilters(){var drawer=document.getElementById("filterDrawer");if(drawer){var form=drawer.querySelector(".filter-form");if(form){var searchParams=new URLSearchParams(new FormData(form));theme.CollectionAjaxFilter(searchParams)}}}function updateDrawerUI(){var drawer=document.getElementById("filterDrawer");if(drawer){var checked=drawer.querySelectorAll('.filter-form input[type="checkbox"]:checked'),count=checked.length,clearBtn=drawer.querySelector("#clearFilter");clearBtn&&(clearBtn.style.display=count>0?"":"none");var countSpan=drawer.querySelector(".total_count");countSpan&&(countSpan.textContent=count>0?" ("+count+")":"");var header=drawer.querySelector(".drawer-header > span");if(header){var title=header.textContent.replace(/\s*\(\d+\)/,"");header.textContent=count>0?title+" ("+count+")":title}}}function hideDrawerOverlays(){var drawer=document.getElementById("filterDrawer");if(drawer){var stickyBar=drawer.querySelector(".btn-fltr-sticky");stickyBar&&(stickyBar.style.display="none")}}document.addEventListener("change",function(e){if(e.target.closest("#filterDrawer")&&e.target.type==="checkbox"){var li=e.target.closest("li.tag");li&&li.classList.toggle("tag--active",e.target.checked),updateDrawerUI()}}),document.addEventListener("click",function(e){var drawer=document.querySelector("#filterDrawer");drawer&&(e.target.closest("#openFilters")?(drawer.classList.add("open"),document.body.classList.add("drawer-open"),updateDrawerUI()):e.target.closest("#closeFilters")||e.target.closest("#btnFilterApply")?(e.target.closest("#btnFilterApply")&&e.preventDefault(),drawer.classList.remove("open"),document.body.classList.remove("drawer-open"),hideDrawerOverlays(),applyDrawerFilters()):e.target.closest("#clearFilter")&&(drawer.classList.remove("open"),document.body.classList.remove("drawer-open"),hideDrawerOverlays()))});function initializeFlickity(){try{let e=document.querySelector(".upsell-carousel");e?(attachVariantChangeListeners(),attachAjaxAddToCartListeners(),new Flickity(e,{cellAlign:"left",wrapAround:!1,prevNextButtons:!1})):console.log("Element .upsell-carousel not found.")}catch(t){console.log("Error initializing Flickity: ",t)}}function attachVariantChangeListeners(){try{document.querySelectorAll(".upsell-item-slide .variant-input input[type='radio']").forEach(function(e){e.addEventListener("change",handleVariantChange)}),document.querySelectorAll(".upsell-item-slide .upsell-variant-wrapper select").forEach(function(e){e.addEventListener("change",handleVariantChange)})}catch(e){console.log("Error attaching variant change listeners: ",e)}}function handleVariantChange(e){try{let t=e.target,r=getSelectedVariantColor(t),n=getSelectedVariantSize(t),a=r||n;r&&n&&(a=`${r} / ${n}
1`),updateVariantSelection(t,a)}catch{return null}}function getSelectedVariantColor(e){try{let t=e.closest(".upsell_item").querySelector(".variant-input input[type='radio']:checked");return t?t.value:null}catch{return null}}function getSelectedVariantSize(e){try{let t=e.closest(".upsell_item").querySelector(".upsell-variant-wrapper select");return t?t.value:null}catch{return null}}function updateVariantSelection(e,t){try{let r=e.closest(".upsell_item");JSON.parse(r.querySelector(".upsell-item-slide form").getAttribute("data-product-json")).forEach(function(e2){if(e2.title===t){r.querySelector(".product-single__variants").value=e2.id,r.querySelector(".product-single__variants").dispatchEvent(new Event("change")),r.querySelector(".price").textContent=theme.Currency.formatMoney(e2.price,theme.settings.moneyFormat),r.querySelector(".single_img img").src=e2.featured_image.src;let n2=r.querySelector(".form-buttons .upsell-button");e2.available?(n2.textContent="ADD",n2.removeAttribute("disabled")):(n2.textContent="SOLD OUT",n2.setAttribute("disabled",!0))}})}catch{return null}}function attachAjaxAddToCartListeners(){try{document.querySelectorAll(".upsell-add-to-card").forEach(function(e2){new theme.AjaxProduct(e2,"[data-add-to-cart]",{scopedEventId:"ProductScreen-"})})}catch{return null}}document.addEventListener("DOMContentLoaded",function(){let e=document.querySelectorAll(".site--has-mega-menu"),t;if(e.length===0){console.log("No elements found with the class .site--has-mega-menu");return}function r(r2){t&&clearTimeout(t),e.forEach(e2=>{e2&&e2.classList.remove("active-mega-menu")}),r2.currentTarget&&r2.currentTarget.classList.add("active-mega-menu")}function n(r2){r2.currentTarget&&(t=setTimeout(()=>{e.forEach(e2=>{e2&&e2.classList.remove("active-mega-menu")})},100))}e.forEach(e2=>{e2&&(e2.addEventListener("mouseenter",r),e2.addEventListener("mouseleave",n))});var a=document.querySelector(".description-tab .collapsible-content__inner"),l=document.getElementById("read-more-btn");a&&(a.offsetWidth>300&&a.classList.add("max-width-300"),a.scrollHeight>a.clientHeight&&a.classList.add("show-more"),l.addEventListener("click",function(){a.style.maxHeight=a.scrollHeight+"px",a.classList.remove("show-more"),l.style.display="none"}));try{initializeFlickity()}catch(i){console.log("Error during DOMContentLoaded event: ",i)}});function processLists(){const swatchesList=document.querySelectorAll(".mpg-swatch-circle.mpg-swatch__nav");return swatchesList.length===0?!1:(swatchesList.forEach(list=>{if(list.dataset.processed)return;list.dataset.processed="true";const items=list.querySelectorAll("span"),maxVisible=5;if(items.length>maxVisible){const hiddenCount=items.length-maxVisible;list.setAttribute("data-more",hiddenCount)}}),!0)}function checkForLists(){processLists()&&clearInterval(checkInterval)}const checkInterval=setInterval(checkForLists,100);setTimeout(function(){clearInterval(checkInterval)},2e3);
2//# sourceMappingURL=/cdn/shop/t/14/assets/custom.js.map?v=126912187105407954141776099795

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.