/*! * (C) Ionic http://ionicframework.com - MIT License */ System.register(["./p-332c71da.system.js","./p-5fc8d5ef.system.js","./p-ca86ce8b.system.js"],(function(t){"use strict";var i,e,n,s,r,c,o;return{setters:[function(t){i=t.r;e=t.d;n=t.h;s=t.H;r=t.f},function(t){c=t.k},function(t){o=t.b}],execute:function(){var f=":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 u=f;var h=t("ion_img",function(){function t(t){var n=this;i(this,t);this.ionImgWillLoad=e(this,"ionImgWillLoad",7);this.ionImgDidLoad=e(this,"ionImgDidLoad",7);this.ionError=e(this,"ionError",7);this.inheritedAttributes={};this.onLoad=function(){n.ionImgDidLoad.emit()};this.onError=function(){n.ionError.emit()};this.loadSrc=undefined;this.loadError=undefined;this.alt=undefined;this.src=undefined}t.prototype.srcChanged=function(){this.addIO()};t.prototype.componentWillLoad=function(){this.inheritedAttributes=c(this.el,["draggable"])};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[i.length-1].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(){var t=this,i=t.loadSrc,e=t.alt,r=t.onLoad,c=t.loadError,f=t.inheritedAttributes;var u=f.draggable;return n(s,{key:"212cb19b83defa47a677e44659eccc5e7e1bc5a2",class:o(this)},n("img",{key:"975230d5ef5f262c8e5f040eb59cd1033241f3c8",decoding:"async",src:i,alt:e,onLoad:r,onError:c,part:"image",draggable:a(u)}))};Object.defineProperty(t.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{src:["srcChanged"]}},enumerable:false,configurable:true});return t}());var a=function(t){switch(t){case"true":return true;case"false":return false;default:return undefined}};h.style=u}}}));