https://www.editionsducommun.org/cdn/shop/t/2/assets/application.js?v=177729211926772822111687186425
1(function(t,e){typeof define=="function"&&define.amd?define([],e):typeof module=="object"&&module.exports?module.exports=e():t.SimpleLightbox=e()})(this,function(){function e(t){for(var e2=1;e2<arguments.length;e2++){var n=arguments[e2];if(n)for(var i2 in n)n.hasOwnProperty(i2)&&(t[i2]=n[i2])}return t}function i(t,e2){t&&e2&&(t.className+=" "+e2)}function s(t,e2){t&&e2&&(t.className=t.className.replace(new RegExp("(\\s|^)"+e2+"(\\s|$)")," ").trim())}function o(t){var e2=document.createElement("div");return e2.innerHTML=t.trim(),e2.childNodes[0]}function l(t,e2){return(t.matches||t.matchesSelector||t.msMatchesSelector).call(t,e2)}function r(t){this.init.apply(this,arguments)}return r.defaults={elementClass:"",elementLoadingClass:"slbLoading",htmlClass:"slbActive",closeBtnClass:"",nextBtnClass:"",prevBtnClass:"",loadingTextClass:"",closeBtnCaption:"Close",nextBtnCaption:"Next",prevBtnCaption:"Previous",loadingCaption:"Loading...",bindToItems:!0,closeOnOverlayClick:!0,closeOnEscapeKey:!0,nextOnImageClick:!0,showCaptions:!0,captionAttribute:"title",urlAttribute:"href",startAt:0,loadingTimeout:100,appendTarget:"body",beforeSetContent:null,beforeClose:null,afterClose:null,beforeDestroy:null,afterDestroy:null,videoRegex:new RegExp(/youtube.com|vimeo.com/)},e(r.prototype,{init:function(n){n=this.options=e({},r.defaults,n);var t,i2=this;n.$items&&(t=n.$items.get()),n.elements&&(t=[].slice.call(typeof n.elements=="string"?document.querySelectorAll(n.elements):n.elements)),this.eventRegistry={lightbox:[],thumbnails:[]},this.items=[],this.captions=[],t&&t.forEach(function(t2,e2){i2.items.push(t2.getAttribute(n.urlAttribute)),i2.captions.push(t2.getAttribute(n.captionAttribute)),n.bindToItems&&i2.addEvent(t2,"click",function(t3){t3.preventDefault(),i2.showPosition(e2)},"thumbnails")}),n.items&&(this.items=n.items),n.captions&&(this.captions=n.captions)},addEvent:function(t,e2,n,i2){return this.eventRegistry[i2||"lightbox"].push({element:t,eventName:e2,callback:n}),t.addEventListener(e2,n),this},removeEvents:function(t){return this.eventRegistry[t].forEach(function(t2){t2.element.removeEventListener(t2.eventName,t2.callback)}),this.eventRegistry[t]=[],this},next:function(){return this.showPosition(this.currentPosition+1)},prev:function(){return this.showPosition(this.currentPosition-1)},normalizePosition:function(t){return t>=this.items.length?t=0:t<0&&(t=this.items.length-1),t},showPosition:function(t){var e2=this.normalizePosition(t);return this.currentPosition!==void 0&&(this.direction=e2>this.currentPosition?"next":"prev"),this.currentPosition=e2,this.setupLightboxHtml().prepareItem(this.currentPosition,this.setContent).show()},loading:function(t){var e2=this,n=this.options;t?this.loadingTimeout=setTimeout(function(){i(e2.$el,n.elementLoadingClass),e2.$content.innerHTML='<p class="slbLoadingText '+n.loadingTextClass+'">'+n.loadingCaption+"</p>",e2.show()},n.loadingTimeout):(s(this.$el,n.elementLoadingClass),clearTimeout(this.loadingTimeout))},prepareItem:function(t,e2){var n=this,i2=this.items[t];if(this.loading(!0),this.options.videoRegex.test(i2))e2.call(n,o('<div class="slbIframeCont"><iframe class="slbIframe" frameborder="0" allowfullscreen src="'+i2+'"></iframe></div>'));else{var s2=o('<div class="slbImageWrap"><img class="slbImage" src="'+i2+'" /></div>');this.$currentImage=s2.querySelector(".slbImage"),this.options.showCaptions&&this.captions[t]&&s2.appendChild(o('<div class="slbCaption">'+this.captions[t]+"</div>")),this.loadImage(i2,function(){n.setImageDimensions(),e2.call(n,s2),n.loadImage(n.items[n.normalizePosition(n.currentPosition+1)])})}return this},loadImage:function(t,e2){if(!this.options.videoRegex.test(t)){var n=new Image;e2&&(n.onload=e2),n.src=t}},setupLightboxHtml:function(){var t=this.options;return this.$el||(this.$el=o('<div class="slbElement '+t.elementClass+'"><div class="slbOverlay"></div><div class="slbWrapOuter"><div class="slbWrap"><div class="slbContentOuter"><div class="slbContent"></div><button type="button" title="'+t.closeBtnCaption+'" class="slbCloseBtn '+t.closeBtnClass+'">\xD7</button>'+(1<this.items.length?'<div class="slbArrows"><button type="button" title="'+t.prevBtnCaption+'" class="prev slbArrow'+t.prevBtnClass+'">'+t.prevBtnCaption+'</button><button type="button" title="'+t.nextBtnCaption+'" class="next slbArrow'+t.nextBtnClass+'">'+t.nextBtnCaption+"</button></div>":"")+"</div></div></div></div>"),this.$content=this.$el.querySelector(".slbContent")),this.$content.innerHTML="",this},show:function(){return this.modalInDom||(document.querySelector(this.options.appendTarget).appendChild(this.$el),i(document.documentElement,this.options.htmlClass),this.setupLightboxEvents(),this.modalInDom=!0),this},setContent:function(t){var e2=typeof t=="string"?o(t):t;return this.loading(!1),this.setupLightboxHtml(),s(this.$content,"slbDirectionNext"),s(this.$content,"slbDirectionPrev"),this.direction&&i(this.$content,this.direction==="next"?"slbDirectionNext":"slbDirectionPrev"),this.options.beforeSetContent&&this.options.beforeSetContent(e2,this),this.$content.appendChild(e2),this},setImageDimensions:function(){this.$currentImage&&(this.$currentImage.style.maxHeight=("innerHeight"in window?window.innerHeight:document.documentElement.offsetHeight)+"px")},setupLightboxEvents:function(){var n=this;return this.eventRegistry.lightbox.length||this.addEvent(this.$el,"click",function(t){var e2=t.target;l(e2,".slbCloseBtn")||n.options.closeOnOverlayClick&&l(e2,".slbWrap")?n.close():l(e2,".slbArrow")?l(e2,".next")?n.next():n.prev():n.options.nextOnImageClick&&1<n.items.length&&l(e2,".slbImage")&&n.next()}).addEvent(document,"keyup",function(t){n.options.closeOnEscapeKey&&t.keyCode===27&&n.close(),1<n.items.length&&((t.keyCode===39||t.keyCode===68)&&n.next(),(t.keyCode===37||t.keyCode===65)&&n.prev())}).addEvent(window,"resize",function(){n.setImageDimensions()}),this},close:function(){this.modalInDom&&(this.runHook("beforeClose"),this.removeEvents("lightbox"),this.$el&&this.$el.parentNode.removeChild(this.$el),s(document.documentElement,this.options.htmlClass),this.modalInDom=!1,this.runHook("afterClose")),this.direction=void 0,this.currentPosition=this.options.startAt},destroy:function(){this.close(),this.runHook("beforeDestroy"),this.removeEvents("thumbnails"),this.runHook("afterDestroy")},runHook:function(t){this.options[t]&&this.options[t](this)}}),r.open=function(t){var e2=new r(t);return t.content?e2.setContent(t.content).show():e2.showPosition(e2.options.startAt)},r.registerAsJqueryPlugin=function(i2){i2.fn.simpleLightbox=function(t){var e2,n=this;return this.each(function(){i2.data(this,"simpleLightbox")||(e2=e2||new r(i2.extend({},t,{$items:n})),i2.data(this,"simpleLightbox",e2))})},i2.SimpleLightbox=r},typeof window<"u"&&window.jQuery&&r.registerAsJqueryPlugin(window.jQuery),r}),SimpleLightbox.defaults={elementClass:"",elementLoadingClass:"slbLoading",htmlClass:"slbActive",closeBtnClass:"",nextBtnClass:" visually-hidden",prevBtnClass:" visually-hidden",loadingTextClass:"",closeBtnCaption:"Fermer",nextBtnCaption:"Suivante",prevBtnCaption:"Pr\xE9c\xE9dente",loadingCaption:"Chargement\u2026",bindToItems:!0,closeOnOverlayClick:!0,closeOnEscapeKey:!0,nextOnImageClick:!0,showCaptions:!1,captionAttribute:"title",urlAttribute:"href",startAt:0,loadingTimeout:100,appendTarget:"body",beforeSetContent:null,beforeClose:null,beforeDestroy:null,videoRegex:new RegExp(/youtube.com|vimeo.com/)},(function(){function addEvent(el,type,handler){el.attachEvent?el.attachEvent("on"+type,handler):el.addEventListener(type,handler)}function removeEvent(el,type,handler){el.detachEvent?el.detachEvent("on"+type,handler):el.removeEventListener(type,handler)}function toggleVisibility(elt2){elt2.classList.toggle("visually-hidden")}var selector="*[data-address-toggle]",elements=document.querySelectorAll(selector);
1elements.forEach(function(el,i){addEvent(el,"click",function(){var targetElt=el.parentNode.nextElementSibling;targetElt.classList.toggle("visually-hidden")})}),console.log("Brutal EdC shop initialized !!"),new SimpleLightbox({elements:".c-image_gallery a"});const urlParams=new URLSearchParams(window.location.search),customerPosted=urlParams.get("customer_posted"),customerError=urlParams.get("contact[tags]");if(customerPosted!=null||customerError=="newsletter"){var elt=document.getElementById("newsletter_subscription");elt.scrollIntoView()}document.querySelectorAll('[data-section-type="product-recommendations"]').forEach(productRecommendations=>{console.log("Load product-recommendations section",productRecommendations.dataset);var baseUrl=productRecommendations.dataset.baseUrl,productId=productRecommendations.dataset.productId,limit=productRecommendations.dataset.limit,intent=productRecommendations.dataset.intent,url=baseUrl+"?section_id=product-recommendations&limit="+limit+"&product_id="+productId+"&intent="+intent;fetch(url).then(function(response){return response.text()}).then(function(body){return productRecommendations.parentElement.innerHTML=body,body})});var productSubscriptionButton=document.getElementById("product_subscription_show");productSubscriptionButton!=null&&(productSubscriptionButton.onclick=productSubscriptionButton.onkeypress=function(e){var modaleElt=document.getElementById("product-modale");console.log("Show modale"),toggleVisibility(modaleElt),document.getElementById("product").parentNode.scrollIntoView()});var productSubscriptionForm=document.getElementById("product-subscription-form");if(productSubscriptionForm!=null){const productSubscriptionConfig={urls:{"offre-augmentee-t7kcrfy65bayex":{"":"https://www.asciiland.net",FIRSTCODE:"https://www.asciiland.net/contacts","2NDCODE":"https://www.asciiland.net/project"},"abonnement-2023":{"":"https://pay.gocardless.com/AL0005XF0T5F12",REABONNEMENT:"https://pay.gocardless.com/AL0005XF11Q8X1"},"abonnement-culture-des-precedents":{"":"https://pay.gocardless.com/AL0005XF1S1JZG"},"abonnement-essai-et-sciences-sociales":{"":"https://pay.gocardless.com/AL0005XF20GM0M"},"abonnement-poesie":{"":"https://pay.gocardless.com/AL0005XF1KZD33"},"abonnement-litterature":{"":"https://pay.gocardless.com/AL0005XF22NY9D"}}};var productElt=document.getElementById("product");if(productElt!=null){var handle=productElt.dataset.productHandle,product={elt:productElt,type:productElt.dataset.productType,handle,urls:productSubscriptionConfig.urls[handle]};product.urls!=null?productSubscription(product,productSubscriptionForm):console.log("Error, missing urls for product",handle)}else console.log("Error, missing product")}function productSubscription(product2,form){form.onsubmit=function(e){e.preventDefault(),console.log("action",form.action),console.log("promo_code",form.promo_code.value);var promoCode=form.promo_code.value,subscriptionUrl=product2.urls[promoCode],errorElt=document.getElementById("promo_code_error");errorElt.innerText="",subscriptionUrl!=null?(console.log("Follow link",subscriptionUrl),document.location.href=subscriptionUrl):(console.log("Invalid promo code",promoCode),errorElt.innerText="Code promotionnel non valide.")};var cancelButtonElt=form.elements.cancel;cancelButtonElt.onclick=cancelButtonElt.onkeypress=function(e){var modaleElt=document.getElementById("product-modale");toggleVisibility(modaleElt)}}})(); 2//# sourceMappingURL=/cdn/shop/t/2/assets/application.js.map?v=177729211926772822111687186425
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.