PageSourceSearch

https://muji.ca/cdn/shop/t/945/assets/custom.min.js?v=58159326844582483361789070858

js muji.ca collected 2026-10-03 21:40:21 UTC 8,640 bytes, 1 lines download raw bytes

1(()=>{(function(t){t._empty=t._empty||[],t._beforeRender=t._beforeRender||[],t._afterRender=t._afterRender||[],t._renderedAll=t._renderedAll||[],t._overrideContent=t._overrideContent||function(e){return e.content},t.onEmpty=function(e){e&&t._empty.push(e)},t.onBeforeRender=function(e){e&&t._beforeRender.push(e)},t.onAfterRender=function(e){e&&t._afterRender.push(e)},t.onRenderedAll=function(e){e&&t._renderedAll.push(e)},t.overrideCellContent=function(e){t._overrideContent=e}})(window.eastsideco_sizeGuides||(window.eastsideco_sizeGuides={}));var w=function(){let t={PROCESSING_COOLDOWN:2e3},e=!1,n=null,o=c=>(c||"").toLowerCase()==="gift cards",i=async()=>{try{return await(await fetch("/cart.js")).json()}catch{return null}},r=async c=>{try{return await(await fetch("/cart/change.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({id:c,quantity:0})})).json()}catch{return null}},a=c=>c.filter(d=>o(d.product_type)),l=c=>{let d=c.some(u=>o(u.product_type)),f=c.some(u=>!o(u.product_type));return d&&f},y=async c=>{if(o(c.product_type))return;let d=await i();if(!d?.items)return;let f=a(d.items);f.length!==0&&await Promise.all(f.map(u=>r(u.key)))},s=()=>{n&&clearTimeout(n),n=setTimeout(()=>{e=!1},t.PROCESSING_COOLDOWN)},p=async c=>{if(!(e||!c?.items?.length)&&l(c.items)){e=!0;try{let d=c.items.find(f=>!o(f.product_type));await y(d)}catch{}finally{s()}}};return(()=>{let c=XMLHttpRequest.prototype.open,d=XMLHttpRequest.prototype.send;XMLHttpRequest.prototype.open=function(f,u,...m){return this._cartUrl=u,c.apply(this,[f,u,...m])},XMLHttpRequest.prototype.send=function(f){return this._cartUrl?.includes("cart.js")&&this.addEventListener("load",function(){try{let u=JSON.parse(this.responseText);p(u)}catch{}}),d.apply(this,arguments)}})(),{handleConflict:y}}();window.handleGiftCardConflict=w.handleConflict;document.addEventListener("DOMContentLoaded",function(){var t=window.eastsideco_sizeGuides;t.onRenderedAll(function(e){var n=document.querySelector('[data-app="eastsideco_sizeGuides"] button, [data-app="eastsideco_sizeGuides"] a'),o=document.querySelector(".modal_close"),i=document.querySelector(".modal_background"),r=document.body.querySelector(".esc-size-guide--p
1opup"),a=document.getElementsByTagName("body")[0];o.addEventListener("click",l=>{a.style.overflow="unset"}),i.addEventListener("click",l=>{a.style.overflow="unset"}),n.addEventListener("click",l=>{a.style.overflow="hidden"}),n.addEventListener("click",l=>{r.style.display==="none"&&(a.style.overflow="unset")})})});var E=new MutationObserver(function(t){for(let e of t)if(e.type==="childList"){for(node of e.addedNodes)if(node.classList&&(node.classList.contains("bss-pb-frontend")||node.classList.contains("bss_pb_img"))){let n=node.querySelector(".bss-pb-frontend");n&&(n.style.position="relative")}else if(node.classList&&node.classList.contains("qimify-minicart-popup-wrapper")){let n=node.querySelector(".minicart-banner");n&&n.remove();let o=node.querySelector(".qimify-minicart-items"),i=document.querySelector(".minicart-banner");if(o&&i){let r=i.cloneNode(!0);o.appendChild(r)}break}}else e.type==="attributes"&&e.target.id==="attentive_overlay"&&e.attributeName==="style"&&(e.target.style.zIndex=700)});E.observe(document,{attributes:!0,childList:!0,characterData:!1,subtree:!0});var g=document.querySelector('.site-footer-block-content [data-app="eastsideco_sizeGuides"]');g&&new MutationObserver(function(e,n){for(let o of e)if(o.type==="childList"){$(o.target.closest(".site-footer-block-content").previousElementSibling).show(),n.disconnect();break}}).observe(g,{attributes:!1,childList:!0,characterData:!1,subtree:!0});$(".accordion").accordion({heightStyle:"panel"});(function(t,e){function n(o,i,r=!1){var a=e.getElementById(i);e.getElementById(o).addEventListener("click",function(l){l.preventDefault(),r&&a.setAttribute("tabindex","-1"),a.focus()})}t.skipLink=n})(window,document);"Shoppad.apps.infiniteoptions".split(".").reduce(function(t,e){return t[e]||(t[e]={}),t[e]},window);window.Shoppad.apps.infiniteoptions.beforeReady=function(t){t("appLoad",function(e){var n=document.querySelector(".product-form--atc-button"),o=n.dataset.available==="true";o&&(n.disabled=!1,n.classList.remove("disabled"))})};$(".product-description-toggle").click(function(t){t.preventDefault();var e=$(".product-description"),n=$(".description"),o=$(this).parent(e).hasClass("product-description-full");n.toggleClass("product-description-partial"),o?e.addClass("product-description-short").removeClass("product-description-full"):e.removeClass("product-description-short").addClass("product-description-full")});var v=!1,L=new MutationObserver(function(t){t.forEach(function(e){e.addedNodes&&e.addedNodes.length>0&&e.target.querySelector(".modal-inner")&&!v&&(v=!0,$(document).on("click",'.product-form__quantity-btn[data-action="decrease-product-quantity"]',function(){let o=$("#product-quantity-input"),i=o.val(),r=Math.max(i-1,1);o.val(r)}),$(document).on("click",'.product-form__quantity-btn[data-action="increase-product-quantity"]',function(){let o=$("#product-quantity-input"),i=parseInt(o.val()),r=parseInt(Math.max(i,1))+1;o.val(r)}),L.disconnect())})}),S=document.body,_={childList:!0,subtree:!0};v||L.observe(S,_);(function(){function t(n){if(n.hasAttribute("data-atc-observed"))return;n.setAttribute("data-atc-observed","true");let o=new MutationObserver(function(i){i.forEach(function(r){if(r.type==="attributes"&&r.attributeName==="class"){let a=n.getAttribute("data-disable-gift-card-atc")==="true",l=n.getAttribute("data-disable-regular-item-atc")==="true";(a||l)&&(o.disconnect(),n.classList.add("disabled"),o.observe(n,{attributes:!0,attributeFilter:["disabled","class"]}))}})});o.observe(n,{attributes:!0,attributeFilter:["disabled","class"]})}document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll(".product-form--atc-button").forEach(function(o){t(o)})}),new MutationObserver(function(n){n.forEach(function(o){o.addedNodes.forEach(function(i){if(i.nodeType===1){i.classList&&i.classList.contains("product-form--atc-button")&&t(i);let r=i.querySelectorAll&&i.querySelectorAll(".product-form--atc-button");r&&r.forEach(function(a){t(a)})}})})}).observe(document.body,{childList:!0,subtree:!0})})();function C(t,e,n,o){let r=b(n-t),a=b(o-e),l=Math.sin(r/2)*Math.sin(r/2)+Math.cos(b(t))*Math.cos(b(n))*Math.sin(a/2)*Math.sin(a/2);return 6371*(2*Math.atan2(Math.sqrt(l),Math.sqrt(1-l)))}function b(t){return t*(Math.PI/180)}var q={ON:{lat:51.2538,lng:-85.3232},AB:{lat:53.9333,lng:-116.5765},BC:{lat:53.7267,lng:-127.6476},MB:{lat:53.7609,lng:-98.8139},NB:{lat:46.5653,lng:-66.4619},NL:{lat:53.1355,lng:-57.6604},NS:{lat:45.151,lng:-63.1887},PE:{lat:46.5107,lng:-63.4168},SK:{lat:52.9399,lng:-106.4509}};function M(){let t=document.querySelectorAll(".use-my-location-btn"),e=d
1ocument.querySelectorAll(".use-my-location-btn-text"),n=document.querySelectorAll(".use-my-location-btn-loading"),o=Array.from(t).map(s=>s.innerHTML),i=document.querySelector(".province-selector");t.forEach(s=>{s.disabled=!0,s.classList.add("loading")}),e.forEach(s=>{s.style.display="none"}),n.forEach(s=>{s.style.display="block"});let r={maximumAge:0,timeout:1e4,enableHighAccuracy:!0},a=function(){t.forEach((s,p)=>{s.disabled=!1,s.innerHTML=o[p],s.classList.remove("loading")}),e.forEach(s=>{s.style.display="block"}),n.forEach(s=>{s.style.display="none"})},l=function(s){a();let p=s.coords.latitude,h=s.coords.longitude,c=null,d=1/0;for(let[f,u]of Object.entries(q)){let m=C(p,h,u.lat,u.lng);m<d&&(d=m,c=f)}if(c){i.value=c;let f=new Event("change",{bubbles:!0});i.dispatchEvent(f)}},y=function(s){a();let p="Unable to retrieve your location.";switch(s.code){case s.PERMISSION_DENIED:p="Location access denied. Please enable location services.";break;case s.POSITION_UNAVAILABLE:p="Location information unavailable.";break;case s.TIMEOUT:p="Location request timed out.";break}console.error("Error details:",{code:s.code,message:p})};navigator.geolocation.getCurrentPosition(l,y,r)}document.addEventListener("DOMContentLoaded",t=>{let e=document.getElementById("info-message"),n=document.querySelectorAll(".use-my-location-btn");e&&document.addEventListener("click",i=>{let r=e.getBoundingClientRect();i.clientX>=r.left&&i.clientX<=r.right&&i.clientY>=r.top&&i.clientY<=r.bottom||(e.style.visibility="hidden")});let o=document.querySelectorAll(".accordion");o.length>0&&o.forEach(i=>{let r={collapsible:!1,heightStyle:"content"};window.jQuery&&window.jQuery.ui&&window.jQuery.ui.accordion&&new window.jQuery.ui.accordion(i,r)}),n&&n.length>0&&n.forEach(i=>{i.addEventListener("click",M)})});})();

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.