var __awaiter=this&&this.__awaiter||function(t,e,r,i){function n(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,s){function a(t){try{h(i.next(t))}catch(e){s(e)}}function o(t){try{h(i["throw"](t))}catch(e){s(e)}}function h(t){t.done?r(t.value):n(t.value).then(a,o)}h((i=i.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,a;return a={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function o(t){return function(e){return h([t,e])}}function h(o){if(i)throw new TypeError("Generator is already executing.");while(a&&(a=0,o[0]&&(r=0)),r)try{if(i=1,n&&(s=o[0]&2?n["return"]:o[0]?n["throw"]||((s=n["return"])&&s.call(n),0):n.next)&&!(s=s.call(n,o[1])).done)return s;if(n=0,s)o=[o[0]&2,s.value];switch(o[0]){case 0:case 1:s=o;break;case 4:r.label++;return{value:o[1],done:false};case 5:r.label++;n=o[1];o=[0];continue;case 7:o=r.ops.pop();r.trys.pop();continue;default:if(!(s=r.trys,s=s.length>0&&s[s.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!s||o[1]>s[0]&&o[1]<s[3])){r.label=o[1];break}if(o[0]===6&&r.label<s[1]){r.label=s[1];s=o;break}if(s&&r.label<s[2]){r.label=s[2];r.ops.push(o);break}if(s[2])r.ops.pop();r.trys.pop();continue}o=e.call(t,r)}catch(h){o=[6,h];n=0}finally{i=s=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};System.register(["./p-d105fb25.system.js"],(function(t){"use strict";var e,r;return{setters:[function(t){e=t.r;r=t.h}],execute:function(){var i=":host{display:inline-block}";var n=t("bds_image",function(){function t(t){e(this,t);this.src=undefined;this.alt=undefined;this.width=undefined;this.height=undefined;this.objectFit="cover";this.dataTest=null;this.imageLoaded=false;this.loadError=false;this.currentSrc=undefined}t.prototype.loadImage=function(){return __awaiter(this,void 0,void 0,(function(){var t,e,r,i;return __generator(this,(function(n){switch(n.label){case 0:if(!this.src)return[3,7];n.label=1;case 1:n.trys.push([1,6,,7]);return[4,fetch(this.src)];case 2:t=n.sent();if(!t.ok)return[3,4];return[4,t.blob()];case 3:e=n.sent();r=URL.createObjectURL(e);this.currentSrc=r;this.imageLoaded=true;return[3,5];case 4:this.loadError=true;n.label=5;case 5:return[3,7];case 6:i=n.sent();this.loadError=true;return[3,7];case 7:return[2]}}))}))};t.prototype.render=function(){if(!this.imageLoaded&&!this.loadError){this.loadImage()}if(this.imageLoaded){return r("img",{src:this.currentSrc,alt:this.alt,style:{objectFit:this.objectFit,width:this.width,height:this.height},"data-test":this.dataTest})}else if(!this.src){return r("div",{style:{width:this.width||this.height?this.width:"100%"}},r("bds-illustration",{type:"empty-states",name:"image-not-found",alt:this.alt,"data-test":this.dataTest}))}else{return r("div",{style:{width:this.width||this.height?this.width:"100%"}},r("bds-illustration",{type:"empty-states",name:"broken-image",alt:this.alt,"data-test":this.dataTest}))}};return t}());n.style=i}}}));