PageSourceSearch

https://www.centralcoastcoffee.com.au/cdn/shop/t/40/assets/product…?v=76205587921027153181784363496

js centralcoastcoffee.com.au collected 2026-10-06 13:28:05 UTC 2,533 bytes, 2 lines download raw bytes

1import{mediaQueryLarge,onDocumentLoaded}from"@theme/utilities";const productInformationGridSelector=".product-information__grid:not(.product-information--media-none)",stockStatusSelector=".variant-stock-status",stockStatusContentSelector=".variant-stock-status__content",minLockedMediaHeight=300;function unlockMediaHeight(grid){grid.removeAttribute("data-media-height-locked"),grid.style.removeProperty("--product-information-locked-media-height")}function getDetailsHeight(grid){const details=grid.querySelector(".product-details");if(!(details instanceof HTMLElement))return 0;const detailsHeight=details.getBoundingClientRect().height,expandedStockStatuses=details.querySelectorAll(`${stockStatusSelector}[open]`);let expandedStockHeight=0;for(const stockStatus of expandedStockStatuses){const content=stockStatus.querySelector(stockStatusContentSelector);if(!(content instanceof HTMLElement))continue;const styles=window.getComputedStyle(content),marginBlockStart=Number.parseFloat(styles.marginBlockStart)||0,marginBlockEnd=Number.parseFloat(styles.marginBlockEnd)||0;expandedStockHeight+=content.getBoundingClientRect().height+marginBlockStart+marginBlockEnd}return Math.max(Math.round(detailsHeight-expandedStockHeight),minLockedMediaHeight)}function lockMediaHeight(grid){if(grid.dataset.mediaHeightLocked==="true")return;const height=getDetailsHeight(grid);height<=0||(grid.style.setProperty("--product-information-locked-media-height",`${height}px`),grid.dataset.mediaHeightLocked="true")}function lockProductInformationMedia(root=document){const grids=root.querySelectorAll(productInformationGridSelector);for(const grid of grids)if(grid instanceof HTMLElement){if(!mediaQueryLarge.matches){unlockMediaHeight(grid);continue}lockMediaHeight(grid)}}function scheduleMediaHeightLock(){requestAnimationFrame(()=>{requestAnimationFrame(()=>lockProductInformationMedia())})}function handleStockStatusToggle(event){const target=event.target;if(!(target instanceof HTMLElement)||!target.matches(stockStatusSelector))return;const grid=target.closest(productInformationGridSelector);grid instanceof HTMLElement&&lockProductInformationMedia(grid.parentElement||document)}onDocumentLoaded(scheduleMediaHeightLock),mediaQueryLarge.addEventListener("change",scheduleMediaHeightLock),document.addEventListener("toggle",handleStockStatusToggle,!0),document.addEventListener("shopify:section:load",scheduleMediaHeightLock);
2//# sourceMappingURL=/cdn/shop/t/40/assets/product-information-height-lock.js.map?v=76205587921027153181784363496

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.