PageSourceSearch

https://www.manucurist.com/cdn/shop/t/72/assets/lazyimage.js?v=132260343735824898401682416249

js manucurist.com collected 2026-09-24 18:53:51 UTC 9,063 bytes, 42 lines download raw bytes

1/*! (c) Andrea Giammarchi @webreflection ISC */
2!function(){"use strict";var e=function(e,t){var n=function(e){for(var t=0,n=e.length;t<n;t++)r(e[t])},r=function(e){var t=e.target,n=e.attributeName,r=e.oldValue;t.attributeChangedCallback(n,r,t.getAttribute(n))};return function(o,a){var l=o.constructor.observedAttributes;return l&&e(a).then((function(){new t(n).observe(o,{attributes:!0,attributeOldValue:!0,attributeFilter:l});for(var e=0,a=l.length;e<a;e++)o.hasAttribute(l[e])&&r({target:o,attributeName:l[e],oldValue:null})})),o}};function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function n(e,n){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=function(e,n){if(e){if("string"==typeof e)return t(e,n);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?t(e,n):void 0}}(e))||n&&e&&"number"==typeof e.length){r&&(e=r);var o=0,a=function(){};return{s:a,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var l,i=!0,u=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return i=e.done,e},e:function(e){u=!0,l=e},f:function(){try{i||null==r.return||r.return()}finally{if(u)throw l}}}}
3/*! (c) Andrea Giammarchi - ISC */var r=!0,o=!1,a="querySelectorAll",l="querySelectorAll",i=self,u=i.document,c=i.Element,s=i.MutationObserver,f=i.Set,d=i.WeakMap,h=function(e){return l in e},v=[].filter,g=function(e){var t=new d,i=function(n,r){var o;if(r)for(var a,l=function(e){return e.matches||e.webkitMatchesSelector||e.msMatchesSelector}(n),i=0,u=p.length;i<u;i++)l.call(n,a=p[i])&&(t.has(n)||t.set(n,new f),(o=t.get(n)).has(a)||(o.add(a),e.handle(n,r,a)));else t.has(n)&&(o=t.get(n),t.delete(n),o.forEach((function(t){e.handle(n,r,t)})))},g=function(e){for(var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=0,r=e.length;n<r;n++)i(e[n],t)},p=e.query,y=e.root||u,m=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document,l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:MutationObserver,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:["*"],u=function t(o,l,i,u,c,s){var f,d=n(o);try{for(d.s();!(f=d.n()).done;){var h=f.value;(s||a in h)&&(c?i.has(h)||(i.add(h),u.delete(h),e(h,c)):u.has(h)||(u.add(h),i.delete(h),e(h,c)),s||t(h[a](l),l,i,u,c,r))}}catch(e){d.e(e)}finally{d.f()}},c=new l((function(e){if(i.length){var t,a=i.join(","),l=new Set,c=new Set,s=n(e);try{for(s.s();!(t=s.n()).done;){var f=t.value,d=f.addedNodes,h=f.removedNodes;u(h,a,l,c,o,o),u(d,a,l,c,r,o)}}catch(e){s.e(e)}finally{s.f()}}})),s=c.observe;return(c.observe=function(e){return s.call(c,e,{subtree:r,childList:r})})(t),c}(i,y,s,p),b=c.prototype.attachShadow;return b&&(c.prototype.attachShadow=function(e){var t=b.call(this,e);return m.observe(t),t}),p.length&&g(y[l](p)),{drop:function(e){for(var n=0,r=e.length;n<r;n++)t.delete(e[n])},flush:function(){for(var e=m.takeRecords(),t=0,n=e.length;t<n;t++)g(v.call(e[t].removedNodes,h),!1),g(v.call(e[t].addedNodes,h),!0)},observer:m,parse:g}},p=self,y=p.document,m=p.Map,b=p.MutationObserver,w=p.Object,E=p.Set,S=p.WeakMap,A=p.Element,M=p.HTMLElement,O=p.Node,N=p.Error,C=p.TypeError,T=p.Reflect,q=w.defineProperty,I=w.keys,D=w.getOwnPropertyNames,L=w.setPrototypeOf,P=!self.customElements,k=function(e){for(var t=I(e),n=[],r=t.length,o=0;o<r;o++)n[o]=e[t[o]],delete e[t[o]];return function(){for(var o=0;o<r;o++)e[t[o]]=n[o]}};if(P){var x=function(){var e=this.constructor;if(!$.has(e))throw new C("Illegal constructor");var t=$.get(e);if(W)return z(W,t);var n=H.call(y,t);return z(L(n,e.prototype),t)},H=y.createElement,$=new m,_=new m,j=new m,R=new m,V=[],U=g({query:V,handle:function(e,t,n){var r=j.get(n);if(t&&!r.isPrototypeOf(e)){var o=k(e);W=L(e,r);try{new r.constructor}finally{W=null,o()}}var a="".concat(t?"":"dis","connectedCallback");a in r&&e[a]()}}).parse,W=null,F=function(e){if(!_.has(e)){var t,n=new Promise((function(e){t=e}));_.set(e,{$:n,_:t})}return _.get(e).$},z=e(F,b);q(self,"customElements",{configurable:!0,value:{define:function(e,t){if(R.has(e))throw new N('the name "'.concat(e,'" has already been used with this registry'));$.set(t,e),j.set(e,t.prototype),R.set(e,t),V.push(e),F(e).then((function(){U(y.querySelectorAll(e))})),_.get(e)._(t)},get:function(e){return R.get(e)},whenDefined:F}}),q(x.prototype=M.prototype,"constructor",{value:x}),q(self,"HTMLElement",{configurable:!0,value:x}),q(y,"createElement",{configurable:!0,value:function(e,t){var n=t&&t.is,r=n?R.get(n):R.get(e);return r?new r:H.call(y,e)}}),"isConnected"in O.prototype||q(O.prototype,"isConnected",{configurable:!0,get:function(){return!(this.ownerDocument.compareDocumentPosition(this)&this.DOCUMENT_POSITION_DISCONNECTED)}})}else if(P=!self.customElements.get("extends-li"))try{var B=function e(){return self.Reflect.construct(HTMLLIElement,[],e)};B.prototype=HTMLLIElement.prototype;var G="extends-li";self.customElements.define("extends-li",B,{extends:"li"}),P=y.createElement("li",{is:G}).outerHTML.indexOf(G)<0;var J=self.customElements,K=J.get,Q=J.whenDefined;q(self.customElements,"whenDefined",{configurable:!0,value:function(e){var t=this;return Q.call(this,e).then((function(n){return n||K.call(t,e)}))}})}catch(e){}if(P){var X=function(e){var t=ae.get(e);ve(t.querySelectorAll(this),e.isConnected)},Y=self.customElements,Z=y.createElement,ee=Y.define,te=Y.get,ne=Y.upgrade,re=T||{construct:function(e){return e.call(this)}},oe=re.construct,ae=new S,le=new E,ie=new m,ue=new m,ce=new m,se=new m,fe=[],de=[],he=function(e){return se.get(e)||te.call(Y,e)},ve=g({query:de,handle:function(e,t,n){var r=ce.get(n);if(t&&!r.isPrototypeOf(e)){var o=k(e);be=L(e,r);try{new r.constructor}finally{be=null,o()}}var a="".concat(t?"":"dis","connectedCallback");a in r&&e[a]()}}).parse,ge=g({query:fe,handle:function(e,t){ae.has(e)&&(t?le.add(e):le.delete(e),de.length&&X.call(de,e))}}).parse,pe=A.prototype.attachShadow;pe&&(A.prototype.attachShadow=function(e){var t=pe.call(this,e);return ae.set(this,t),t});var ye=function(e){if(!ue.has(e)){var t,n=new Promise((function(e){t=e}));ue.set(e,{$:n,_:t})}return ue.get(e).$},me=e(ye,b),be=null;D(self).filter((function(e){return/^HTML.*Element$/.test(e)}
3)).forEach((function(e){var t=self[e];function n(){var e=this.constructor;if(!ie.has(e))throw new C("Illegal constructor");var n=ie.get(e),r=n.is,o=n.tag;if(r){if(be)return me(be,r);var a=Z.call(y,o);return a.setAttribute("is",r),me(L(a,e.prototype),r)}return oe.call(this,t,[],e)}q(n.prototype=t.prototype,"constructor",{value:n}),q(self,e,{value:n})})),q(y,"createElement",{configurable:!0,value:function(e,t){var n=t&&t.is;if(n){var r=se.get(n);if(r&&ie.get(r).tag===e)return new r}var o=Z.call(y,e);return n&&o.setAttribute("is",n),o}}),q(Y,"get",{configurable:!0,value:he}),q(Y,"whenDefined",{configurable:!0,value:ye}),q(Y,"upgrade",{configurable:!0,value:function(e){var t=e.getAttribute("is");if(t){var n=se.get(t);if(n)return void me(L(e,n.prototype),t)}ne.call(Y,e)}}),q(Y,"define",{configurable:!0,value:function(e,t,n){if(he(e))throw new N("'".concat(e,"' has already been defined as a custom element"));var r,o=n&&n.extends;ie.set(t,o?{is:e,tag:o}:{is:"",tag:e}),o?(r="".concat(o,'[is="').concat(e,'"]'),ce.set(r,t.prototype),se.set(e,t),de.push(r)):(ee.apply(Y,arguments),fe.push(r=e)),ye(e).then((function(){o?(ve(y.querySelectorAll(r)),le.forEach(X,[r])):ge(y.querySelectorAll(r))})),ue.get(e)._(t)}})}}();
4/*! Lazy Image */
5class LazyImage extends HTMLImageElement {
6  constructor() {
7    super();
8
9    this.wrapper = this.closest('.media-wrapper');
10    if (this.wrapper === null) return;
11
12    this.handleLazy();
13    addEventListener('resize', this.handleLazy.bind(this), true);
14
15    const observer = new MutationObserver((changes) => {
16      changes.forEach((change) => {
17        if (change.attributeName.includes('src') || change.attributeName.includes('srcset')) {
18          this.handleLazy();
19        }
20      });
21    });
22    observer.observe(this, {attributes : true});
23  }
24
25  handleLazy () {
26    const mql = window.matchMedia('(min-width: 750px)');
27    if (mql.matches && this.classList.contains('medium-hide')) return;
28    if (!mql.matches && this.classList.contains('small-hide')) return;
29    if (this.complete || this.classList.contains('loaded')) return;
30    
31    this.wrapper.classList.add('loading');
32    this.addEventListener('load', () => {
33      const loaded = () => {
34        this.classList.add('loaded');
35        this.wrapper.classList.remove('loading');
36      };
37
38      window.requestIdleCallback ? window.requestIdleCallback(loaded, {timeout: 150}) : setTimeout(loaded);
39    }, false);
40  }
41}
42window.customElements.define('lazy-image', LazyImage, { extends: 'img' });

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.