gatus/web/static/js/app-legacy.js

1 line
39 KiB
JavaScript
Raw Normal View History

2022-01-03 01:15:32 +01:00
(function(){"use strict";var e={4812:function(e,t,n){n.d(t,{L:function(){return Jt}});n(6992),n(8674),n(9601),n(7727);var s=n(9963),o=n(6252),r=n(3577),a=n.p+"img/logo.png",i={key:0,class:"container container-xs relative mx-auto xl:rounded xl:border xl:shadow-xl xl:my-5 p-5 pb-12 xl:pb-5 text-left dark:bg-gray-800 dark:text-gray-200 dark:border-gray-500",id:"global"},l={class:"mb-2"},u={class:"flex flex-wrap"},g=(0,o._)("div",{class:"w-3/4 text-left my-auto"},[(0,o._)("div",{class:"text-3xl xl:text-5xl lg:text-4xl font-light"},"Health Status")],-1),c={class:"w-1/4 flex justify-end"},d=["src"],h={key:1,src:a,alt:"Gatus",class:"object-scale-down",style:{"max-width":"100px","min-width":"50px","min-height":"50px"}},p={key:0,class:"text-red-500 text-center my-2"},f={class:"text-xl"},m={key:0,class:"text-red-500"},A={key:1,class:"text-red-500"},v={key:1},w=["href"];function y(e,t,n,s,a,y){var x=(0,o.up)("router-view"),T=(0,o.up)("Tooltip"),k=(0,o.up)("Social");return(0,o.wg)(),(0,o.iD)(o.HY,null,[a.retrievedConfig?((0,o.wg)(),(0,o.iD)("div",i,[(0,o._)("div",l,[(0,o._)("div",u,[g,(0,o._)("div",c,[y.getLogo?((0,o.wg)(),(0,o.iD)("img",{key:0,src:y.getLogo,alt:"Gatus",class:"object-scale-down",style:{"max-width":"100px","min-width":"50px","min-height":"50px"}},null,8,d)):((0,o.wg)(),(0,o.iD)("img",h))])])]),e.$route&&e.$route.query.error?((0,o.wg)(),(0,o.iD)("div",p,[(0,o._)("div",f,["access_denied"===e.$route.query.error?((0,o.wg)(),(0,o.iD)("span",m,"You do not have access to this status page")):((0,o.wg)(),(0,o.iD)("span",A,(0,r.zw)(e.$route.query.error),1))])])):(0,o.kq)("",!0),a.config&&a.config.oidc&&!a.config.authenticated?((0,o.wg)(),(0,o.iD)("div",v,[(0,o._)("a",{href:"".concat(a.SERVER_URL,"/oidc/login"),class:"max-w-lg mx-auto w-full flex justify-center py-3 px-4 border border-transparent rounded-md shadow-lg text-white bg-green-700 hover:bg-green-800"}," Login with OIDC ",8,w)])):(0,o.kq)("",!0),(0,o.Wm)(x,{onShowTooltip:y.showTooltip},null,8,["onShowTooltip"])])):(0,o.kq)("",!0),(0,o.Wm)(T,{result:a.tooltip.result,event:a.tooltip.event},null,8,["result","event"]),(0,o.Wm)(k)],64)}n(1539);var x=n.p+"img/github.png",T=function(e){return(0,o.dD)("data-v-a88161aa"),e=e(),(0,o.Cn)(),e},k={id:"social"},R=T((function(){return(0,o._)("a",{href:"https://github.com/TwiN/gatus",target:"_blank",title:"Gatus on GitHub"},[(0,o._)("img",{src:x,alt:"GitHub",width:"32",height:"auto"})],-1)})),b=[R];function I(e,t,n,s,r,a){return(0,o.wg)(),(0,o.iD)("div",k,b)}var D={name:"Social"},S=n(3744);const C=(0,S.Z)(D,[["render",I],["__scopeId","data-v-a88161aa"]]);var E=C,B=(n(6977),(0,o._)("div",{class:"tooltip-title"},"Timestamp:",-1)),P={id:"tooltip-timestamp"},U=(0,o._)("div",{class:"tooltip-title"},"Response time:",-1),O={id:"tooltip-response-time"},H=(0,o._)("div",{class:"tooltip-title"},"Conditions:",-1),z={id:"tooltip-conditions"},M=(0,o._)("br",null,null,-1),Q={key:0,id:"tooltip-errors-container"},W=(0,o._)("div",{class:"tooltip-title"},"Errors:",-1),q={id:"tooltip-errors"},X=(0,o._)("br",null,null,-1);function Y(e,t,n,s,a,i){return(0,o.wg)(),(0,o.iD)("div",{id:"tooltip",ref:"tooltip",class:(0,r.C_)(a.hidden?"invisible":""),style:(0,r.j5)("top:"+a.top+"px; left:"+a.left+"px")},[n.result?(0,o.WI)(e.$slots,"default",{key:0},(function(){return[B,(0,o._)("code",P,(0,r.zw)(i.prettifyTimestamp(n.result.timestamp)),1),U,(0,o._)("code",O,(0,r.zw)((n.result.duration/1e6).toFixed(0))+"ms",1),H,(0,o._)("code",z,[((0,o.wg)(!0),(0,o.iD)(o.HY,null,(0,o.Ko)(n.result.conditionResults,(function(t){return(0,o.WI)(e.$slots,"default",{key:t},(function(){return[(0,o.Uk)((0,r.zw)(t.success?"✓":"X")+" ~ "+(0,r.zw)(t.condition),1),M]}))})),128))]),n.result.errors&&n.result.errors.length?((0,o.wg)(),(0,o.iD)("div",Q,[W,(0,o._)("code",q,[((0,o.wg)(!0),(0,o.iD)(o.HY,null,(0,o.Ko)(n.result.errors,(function(t){return(0,o.WI)(e.$slots,"default",{key:t},(function(){return[(0,o.Uk)(" - "+(0,r.zw)(t),1),X]}))})),128))])])):(0,o.kq)("",!0)]})):(0,o.kq)("",!0)],6)}n(4916),n(5306);var K={name:"Endpoints",props:{event:Event,result:Object},methods:{prettifyTimestamp:fun