import{n as o}from"./plugin-vue2_normalizer.ed7092a9.js";const n={data:function(){return{code:null,error:null}},props:{showTitle:{default:!0}},methods:{clear:function(){this.error=null,this.code=null},fromXHR:function(e){if(e.status===0)this.code=null,this.error="Failed to contact temBoard server.";else{this.code=e.status;var r=e.getResponseHeader("content-type");r.includes("application/json")?(this.error=JSON.parse(e.responseText).error,this.error===""&&(this.error="Unknown error. Please contact temBoard administrator.")):r.includes("text/plain")?this.error=`<pre>${e.responseText}</pre>`:this.error="Unknown error. Please contact temBoard administrator."}},setHTML:function(e){this.code=null,this.error=e}}};var a=function(){var r=this,t=r._self._c;return r.error?t("div",{staticClass:"alert alert-danger",attrs:{role:"alert"}},[t("h4",{staticClass:"modal-title",attrs:{id:"ErrorLabel"}},[r.showTitle?[r._v("Error "+r._s(r.code))]:r._e(),t("button",{staticClass:"close",attrs:{type:"button","aria-label":"Close"},on:{click:function(s){return s.preventDefault(),r.clear.apply(null,arguments)}}},[t("span",{attrs:{"aria-hidden":"true"}},[r._v("\xD7")])])],2),t("div",{staticClass:"pr-3"},[t("p",{domProps:{innerHTML:r._s(r.error)}})])]):r._e()},l=[],i=o(n,a,l,!1,null,null,null,null);const u=i.exports;export{u as E};
