1let getDiscountPercent=function(price,compareAtPrice,selector){const discount=compareAtPrice-price,discountPercentage=Math.floor(discount/compareAtPrice*100);if(selector&&discountPercentage>0){let discountElement=document.querySelector(selector);discountElement.innerHTML=`${discountPercentage}% OFF`,discountElement.classList.add("price-promo-percentage-off")}else return discountPercentage},adjustSurroundingElements=function(direction="up",stickyCTAAdjacentElementIds,styleAdjustmentIntervalId){if(stickyCTAAdjacentElementIds.forEach(id=>{const element=document.querySelector(`#${id}`);element&&(element.style.transition="margin-bottom .3s")}),direction!=="up"&&direction!=="down"){console.error('adjustSurroundingElements function only takes one of two arguments: string "up" or string "down"');return}const directionStyles={marginBottom:{up:"100px",down:null}};styleAdjustmentIntervalId&&clearInterval(styleAdjustmentIntervalId),styleAdjustmentIntervalId=setInterval(()=>{let allElementsExist=!0;stickyCTAAdjacentElementIds.forEach(id=>{const element=document.querySelector(`#${id}`);element?element.style.marginBottom=directionStyles.marginBottom[direction]:allElementsExist=!1}),allElementsExist&&(clearInterval(styleAdjustmentIntervalId),styleAdjustmentIntervalId=null)},30),setTimeout(()=>{clearInterval(styleAdjustmentIntervalId),styleAdjustmentIntervalId=null},5e3)};window.LG_custom={getDiscountPercent,adjustSurroundingElements}; 2//# sourceMappingURL=/cdn/shop/t/220/assets/global-variables.js.map?v=134606679069928074891788226704
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.