{"version":3,"sources":["webpack:///./node_modules/@ionic/core/dist/esm-es5/ion-img.entry.js"],"names":["imgCss","Img","t","i","this","ionImgWillLoad","ionImgDidLoad","ionError","onLoad","emit","onError","prototype","srcChanged","addIO","componentDidLoad","undefined","src","window","IntersectionObserverEntry","removeIO","io","IntersectionObserver","isIntersecting","load","observe","el","setTimeout","loadError","loadSrc","disconnect","render","class","decoding","alt","part","Object","defineProperty","get","enumerable","configurable","style"],"mappings":"gHAAA,2EAAgKA,EAAO,qMAAyMC,EAAI,WAAW,SAASC,EAAEA,GAAG,IAAIC,EAAEC,KAAK,eAAiBA,KAAKF,GAAGE,KAAKC,eAAe,eAAYD,KAAK,iBAAiB,GAAGA,KAAKE,cAAc,eAAYF,KAAK,gBAAgB,GAAGA,KAAKG,SAAS,eAAYH,KAAK,WAAW,GAAGA,KAAKI,OAAO,WAAWL,EAAEG,cAAcG,QAAQL,KAAKM,QAAQ,WAAWP,EAAEI,SAASE,QAA0nC,OAAlnCP,EAAES,UAAUC,WAAW,WAAWR,KAAKS,SAASX,EAAES,UAAUG,iBAAiB,WAAWV,KAAKS,SAASX,EAAES,UAAUE,MAAM,WAAW,IAAIX,EAAEE,UAAmBW,IAAXX,KAAKY,MAA2C,qBAATC,QAAsB,yBAAyBA,QAAQ,8BAA8BA,QAAQ,mBAAmBA,OAAOC,0BAA0BP,WAAWP,KAAKe,WAAWf,KAAKgB,GAAG,IAAIC,sBAAqB,SAAUlB,GAAMA,EAAE,GAAGmB,iBAAgBpB,EAAEqB,OAAOrB,EAAEiB,eAAef,KAAKgB,GAAGI,QAAQpB,KAAKqB,KAASC,YAAW,WAAY,OAAOxB,EAAEqB,SAAS,OAAOrB,EAAES,UAAUY,KAAK,WAAWnB,KAAKuB,UAAUvB,KAAKM,QAAQN,KAAKwB,QAAQxB,KAAKY,IAAIZ,KAAKC,eAAeI,QAAQP,EAAES,UAAUQ,SAAS,WAAcf,KAAKgB,KAAIhB,KAAKgB,GAAGS,aAAazB,KAAKgB,QAAGL,IAAYb,EAAES,UAAUmB,OAAO,WAAW,OAAO,eAAE,OAAK,CAACC,MAAM,eAAW3B,OAAO,eAAE,MAAM,CAAC4B,SAAS,QAAQhB,IAAIZ,KAAKwB,QAAQK,IAAI7B,KAAK6B,IAAIzB,OAAOJ,KAAKI,OAAOE,QAAQN,KAAKuB,UAAUO,KAAK,YAAYC,OAAOC,eAAelC,EAAES,UAAU,KAAK,CAAC0B,IAAI,WAAW,OAAO,eAAWjC,OAAOkC,YAAW,EAAMC,cAAa,IAAOJ,OAAOC,eAAelC,EAAE,WAAW,CAACmC,IAAI,WAAW,MAAM,CAACrB,IAAI,CAAC,gBAAgBsB,YAAW,EAAMC,cAAa,IAAcrC,EAA76C,GAAk7CD,EAAIuC,MAAMxC","file":"js/chunk-2d0e5812.bc3079e1.js","sourcesContent":["import{r as registerInstance,e as createEvent,h,H as Host,i as getElement}from\"./index-7a8b7a1c.js\";import{b as getIonMode}from\"./ionic-global-63a97a32.js\";var imgCss=\":host{display:block;-o-object-fit:contain;object-fit:contain}img{display:block;width:100%;height:100%;-o-object-fit:inherit;object-fit:inherit;-o-object-position:inherit;object-position:inherit}\";var Img=function(){function t(t){var i=this;registerInstance(this,t);this.ionImgWillLoad=createEvent(this,\"ionImgWillLoad\",7);this.ionImgDidLoad=createEvent(this,\"ionImgDidLoad\",7);this.ionError=createEvent(this,\"ionError\",7);this.onLoad=function(){i.ionImgDidLoad.emit()};this.onError=function(){i.ionError.emit()}}t.prototype.srcChanged=function(){this.addIO()};t.prototype.componentDidLoad=function(){this.addIO()};t.prototype.addIO=function(){var t=this;if(this.src===undefined){return}if(typeof window!==\"undefined\"&&\"IntersectionObserver\"in window&&\"IntersectionObserverEntry\"in window&&\"isIntersecting\"in window.IntersectionObserverEntry.prototype){this.removeIO();this.io=new IntersectionObserver((function(i){if(i[0].isIntersecting){t.load();t.removeIO()}}));this.io.observe(this.el)}else{setTimeout((function(){return t.load()}),200)}};t.prototype.load=function(){this.loadError=this.onError;this.loadSrc=this.src;this.ionImgWillLoad.emit()};t.prototype.removeIO=function(){if(this.io){this.io.disconnect();this.io=undefined}};t.prototype.render=function(){return h(Host,{class:getIonMode(this)},h(\"img\",{decoding:\"async\",src:this.loadSrc,alt:this.alt,onLoad:this.onLoad,onError:this.loadError,part:\"image\"}))};Object.defineProperty(t.prototype,\"el\",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,\"watchers\",{get:function(){return{src:[\"srcChanged\"]}},enumerable:false,configurable:true});return t}();Img.style=imgCss;export{Img as ion_img};"],"sourceRoot":""}