1import{a as pt}from"./chunk-32PHKMFN.js";import{d as mt}from"./chunk-N5UJIS7H.js";import{c as gt,j as ut}from"./chunk-3Q3TXNKH.js";import{a as dt}from"./chunk-RTT6FY7Y.js";import{a as ht}from"./chunk-USJX2DWZ.js";import{m as pe}from"./chunk-AHXEG3IB.js";import{a as Ae}from"./chunk-USHQKH6K.js";import{a as ze,b as ae,c as G,d as Ye,e as oe,f as se,g as re,h as ce,i as U,l as Je}from"./chunk-B2LVE2JO.js";import"./chunk-6JP4RI6P.js";import{a as Ve}from"./chunk-OKSR2FPP.js";import{a as qe}from"./chunk-H333FLY2.js";import"./chunk-WVJPZYXS.js";import{a as Fe}from"./chunk-7UCUHBZF.js";import"./chunk-I2LYZ4DT.js";import{l as lt}from"./chunk-IS6UHDWO.js";import{a as ct}from"./chunk-GLRGU6RY.js";import"./chunk-3R4HDSC2.js";import{a as Ke}from"./chunk-Q6AQQNJA.js";import"./chunk-4YLUWPDP.js";import{B as et,V as de,ba as q,ca as tt,d as j,da as it,ea as nt,ia as at,la as ot,m as Xe,ma as st,na as rt,p as Qe,s as Ze,y as le}from"./chunk-6JYNQDSM.js";import{b as We}from"./chunk-MRYWWEFA.js";import"./chunk-CF65D2XR.js";import"./chunk-BS2AOQ45.js";import{a as Ge,b as je}from"./chunk-EEJVXAEY.js";import"./chunk-JMXXGCKZ.js";import{a as Ue}from"./chunk-XUWCYNR3.js";import{g as K}from"./chunk-TIIHEXNO.js";import{o as W}from"./chunk-UZ6K5GCM.js";import"./chunk-PDJEIOQ7.js";import"./chunk-YBTSKEMN.js";import{m as Ie}from"./chunk-YNCBRS3L.js";import{a as He}from"./chunk-FOLKBJ2S.js";import"./chunk-IVF4RZW5.js";import"./chunk-2KA2G7WN.js";import"./chunk-LULTOA3E.js";import"./chunk-OIGGUN3J.js";import{F as Le,b as we,g as Oe,l as Te,x as Re,z as Be}from"./chunk-27Z5CVTB.js";import"./chunk-7QTY2353.js";import{a as Ne}from"./chunk-GB5ZYUPV.js";import{a as Ee,c as Pe,d as De}from"./chunk-ES7TQF2A.js";import"./chunk-WZ3NTYYW.js";import{e as Se,o as ye,t as Me,y as $e}from"./chunk-WQFPLM7Y.js";import"./chunk-3KQDXHFO.js";import{$b as V,Cc as S,E as fe,Ec as u,Fa as M,Ga as E,Kd as ve,Nb as Ce,Oc as _e,Pc as ee,Ra as v,Rc as N,Rd as be,S as Z,Sc as s,Tc as d,Uc as k,Va as St,Vc as A,bc as f,d as J,dc as C,ed as xe,fc as R,fd as ke,gc as B,gd as te,hc as L,hd as ie,ic as P,jc as o,kc as n,la as b,lc as w,pd as c,qa as bt,qd as l,rd as ne,s as X,t as Q,tc as O,yb as t,za as T}from"./chunk-DD6G5OUP.js";import{a as F,b as z}from"./chunk-L5VMGDEB.js";be();bt();St();be();var yt=()=>["edit"],Mt=(i,g)=>({count:i,pages:g}),Et=i=>({checkId:i}),Pt=(i,g)=>[i,g],Dt=i=>({time:i});function It(i,g){i&1&&(o(0,"span",7),w(1,"span")(2,"span")(3,"span"),n())}function wt(i,g){if(i&1&&s(0),i&2){let e=u();k(" ",e.getStatusIcon(e.check==null?null:e.check.status)," ")}}function Ot(i,g){i&1&&(o(0,"span",8),s(1),c(2,"translate"),n()),i&2&&(t(),d(l(2,1,"checks.detail.shadow")))}function Tt(i,g){if(i&1&&(o(0,"span",11),s(1),c(2,"translate"),n()),i&2){let e=u();P("title",e.statusPageNames),t(),k(" ",ne(2,2,"checks.detail.onStatusPages",ie(5,Mt,e.statusPageCount,e.statusPageCount===1?"Page":"Pages"))," ")}}function Rt(i,g){if(i&1){let e=O();o(0,"button",21),S("click",function(){M(e);let a=u();return E(a.toggleMode())}),s(1),c(2,"translate"),c(3,"translate"),n()}if(i&2){let e=u();P("disabled",e.isModeUpdating),t(),k(" ",e.isModeUpdating?l(2,2,"checks.detail.updating"):l(3,4,"checks.detail.activate")," ")}}function Bt(i,g){if(i&1){let e=O();o(0,"button",22),S("click",function(){M(e);let a=u();return E(a.toggleMode())}),s(1),c(2,"translate"),c(3,"translate"),n()}if(i&2){let e=u();P("disabled",e.isModeUpdating),t(),k(" ",e.isModeUpdating?l(2,2,"checks.detail.updating"):l(3,4,"checks.detail.shadowMode")," ")}}function Lt(i,g){if(i&1){let e=O();o(0,"div",23)(1,"span",69),s(2,"\u23F8"),n(),o(3,"div",70)(4,"strong"),s(5),c(6,"translate"),n(),o(7,"p"),s(8),c(9,"translate"),n()(),o(10,"button",71),S("click",function(){M(e);let a=u(2);return E(a.togglePause())}),s(11),c(12,"translate"),n()()}i&2&&(t(5),d(l(6,4,"checks.detail.pausedBanner.title")),t(3),d(l(9,6,"checks.detail.pausedBanner.description")),t(2),P("monReadonly","checks.manage"),t(),k(" ",l(12,8,"checks.resume")," "))}function Nt(i,g){if(i&1){let e=O();o(0,"div",24)(1,"span",72),s(2),c(3,"translate"),n(),o(4,"button",73),S("click",function(){M(e);let a=u(2);return E(a.dismissShadowBanner())}),s(5," \xD7 "),n()()}i&2&&(t(2),d(l(3,1,"checks.detail.shadowBanner")))}function At(i,g){if(i&1&&(o(0,"div",25),s(1),n()),i&2){let e=u(2);t(),k(" ",e.modeUpdateError," ")}}function $t(i,g){if(i&1){let e=O();o(0,"div",26)(1,"div",74),S("click",function(a){return a.stopPropagation()}),o(2,"div",75)(3,"h3"),s(4),c(5,"translate"),n(),o(6,"button",76),S("click",function(){M(e);let a=u(2);return E(a.cancelActivate())}),s(7,"\xD7"),n()(),o(8,"div",77)(9,"p"),s(10),c(11,"translate"),n()(),o(12,"div",78)(13,"button",79),S("click",function(){M(e);let a=u(2);return E(a.cancelActivate())}
1),s(14),c(15,"translate"),n(),o(16,"button",80),S("click",function(){M(e);let a=u(2);return E(a.confirmActivate())}),s(17),c(18,"translate"),n()()()()}i&2&&(t(4),d(l(5,4,"checks.detail.activateDialog.title")),t(6),d(l(11,6,"checks.detail.activateDialog.message")),t(4),k(" ",l(15,8,"checks.detail.activateDialog.cancel")," "),t(3),k(" ",l(18,10,"checks.detail.activateDialog.confirm")," "))}function Ht(i,g){if(i&1){let e=O();o(0,"div",27)(1,"span",81),s(2,"\u26A0"),n(),o(3,"span",82),s(4),c(5,"translate"),n(),o(6,"button",83),S("click",function(){M(e);let a=u(2);return E(a.dismissHistoryError())}),s(7," \xD7 "),n()()}i&2&&(t(4),d(l(5,1,"checks.detail.historyError")))}function Ut(i,g){if(i&1&&(o(0,"div",28)(1,"span",84),s(2,"i"),n(),o(3,"div",85)(4,"strong"),s(5),c(6,"translate"),n(),o(7,"p"),s(8),c(9,"translate"),n()(),o(10,"a",86),s(11),c(12,"translate"),n()()),i&2){let e=u(2);t(5),d(l(6,4,"checks.detail.heartbeatWaiting.title")),t(3),d(l(9,6,"checks.detail.heartbeatWaiting.description")),t(2),P("routerLink",ie(10,Pt,e.routes.HEARTBEATS,e.check.id)),t(),k(" ",l(12,8,"checks.detail.heartbeatWaiting.openIntegration")," ")}}function Ft(i,g){i&1&&(o(0,"div",33),s(1),c(2,"translate"),n()),i&2&&(t(),k(" ",l(2,1,"checks.detail.stats.shadowNoIncident")," "))}function zt(i,g){if(i&1&&(s(0),o(1,"span",42),s(2,"ms"),n()),i&2){let e=u(2);k(" ",e.check.lastLatencyMs)}}function Vt(i,g){i&1&&s(0," \u2014 ")}function Kt(i,g){i&1&&s(0," N/A ")}function Wt(i,g){if(i&1&&s(0),i&2){let e=u(2);k(" ",e.hasData?e.uptimePercentage+"%":"\u2014"," ")}}function Gt(i,g){i&1&&(o(0,"div",38),s(1),c(2,"translate"),n()),i&2&&(t(),k(" ",l(2,1,"checks.detail.stats.shadowModeHint")," "))}function jt(i,g){i&1&&(o(0,"span",42),s(1,"ms"),n())}function qt(i,g){if(i&1&&(o(0,"span",92),s(1),n()),i&2){let e=u().$implicit;t(),k("",e.latencyMs,"ms")}}function Yt(i,g){if(i&1&&(o(0,"div",89),w(1,"span",90),o(2,"span",91),s(3),n(),f(4,qt,2,1,"span",92),n()),i&2){let e=g.$implicit,r=u(3);N(e.status),P("title",r.getRegionTooltip(e)),t(),N(e.status),t(2),d(e.region),t(),C(e.latencyMs?4:-1)}}function Jt(i,g){if(i&1&&(o(0,"div",43)(1,"div",48)(2,"h2"),s(3),c(4,"translate"),n()(),o(5,"div",51)(6,"div",87),B(7,Yt,5,7,"div",88,R),n()()()),i&2){let e=u(2);t(3),d(l(4,1,"checks.detail.regionStatus")),t(4),L(e.regionStatuses)}}function Xt(i,g){if(i&1&&(o(0,"div",101),w(1,"div",102),n()),i&2){let e=u(3);t(),N(e.sslExpiryInfo.level),_e("width",e.sslExpiryInfo.progressPercent,"%")}}function Qt(i,g){if(i&1&&(o(0,"div",44)(1,"div",48)(2,"h2")(3,"span",93),s(4),c(5,"translate"),n()()(),o(6,"div",51)(7,"div",94)(8,"div",95)(9,"div",96)(10,"span",97),s(11),c(12,"translate"),n(),o(13,"span",98),s(14),n()(),o(15,"div",96)(16,"span",97),s(17),c(18,"translate"),n(),o(19,"span",99),s(20),n()(),o(21,"div",96)(22,"span",97),s(23),c(24,"translate"),n(),o(25,"span",100),s(26),n()()(),f(27,Xt,2,4,"div",101),n()()()),i&2){let e=u(2);t(4),d(l(5,12,"checks.detail.ssl.certificateStatus")),t(3),N(e.sslExpiryInfo.level),t(4),d(l(12,14,"checks.detail.ssl.expiryDate")),t(3),d(e.sslExpiryInfo.expiresAt?e.formatDateLong(e.sslExpiryInfo.expiresAt):"Not yet determined"),t(3),d(l(18,16,"checks.detail.ssl.daysRemaining")),t(3),d(e.sslExpiryInfo.daysRemaining!==null?e.sslExpiryInfo.daysRemaining+" days":"\u2014"),t(3),d(l(24,18,"checks.detail.ssl.status")),t(2),N(e.sslExpiryInfo.level),t(),d(e.sslExpiryInfo.levelLabel),t(),C(e.sslExpiryInfo.expiresAt?27:-1)}}function Zt(i,g){i&1&&(o(0,"div",45)(1,"div",48)(2,"h2"),s(3),c(4,"translate"),n()(),o(5,"div",51)(6,"div",103)(7,"p"),s(8),c(9,"translate"),n()()()()),i&2&&(t(3),d(l(4,2,"checks.detail.ssl.certificateStatus")),t(5),d(l(9,4,"checks.detail.ssl.waitingMessage")))}function ei(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",108),s(5),n()(),o(6,"div",60)(7,"span",61),s(8),c(9,"translate"),n(),o(10,"span",62),s(11),c(12,"translate"),n()()),i&2){let e=u(3);t(2),d(l(3,7,"checks.detail.domainExpiry.daysRemaining")),t(2),N(e.domainExpiryInfo.level),t(),d(e.domainExpiryInfo.daysRemaining!==null?e.domainExpiryInfo.daysRemaining:"\u2014"),t(3),d(l(9,9,"checks.detail.domainExpiry.warningThreshold")),t(3),A("",e.domainExpiryInfo.thresholdDays," ",l(12,11,"checks.detail.domainExpiry.days"))}}function ti(i,g){i&1&&(o(0,"div",107)(1,"span",109),s(2),c(3,"translate"),n(),o(4,"span",110),s(5),c(6,"translate"),n()()),i&2&&(t(2),d(l(3,2,"checks.detail.domainExpiry.notMonitorable")),t(3),d(l(6,4,"checks.detail.domainExpiry.notMonitorableHint")))}function ii(i,g){if(i&1&&(o(0,"div",46)(1,"div",48)(2,"h2"),s(3),c(4,"translate"),n()(),o(5,"div",51)(6,"div",104)(7,"div",59)(8,"div",60)(9,"span",61),s(10),c(11,"translate"),n(),o(12,"span",105),s(13),n()(),o(14,"div",60)(15,"span",61),s(16),c(17,"translate"),n(),o(18,"span",106),s(19),c(20,"translate"),c(21,"translate"),n()(),f(22,ei,13,13),f(23,ti,7,6,"div",107),n()()()()),i&2){let e=u(2);t(3),d(l(4,9,"checks.detail.domainExpiry.title")),t(3),N(e.domainExpiryInfo.level),t(4),d(l(11,11,"checks.detail.domainExpiry.domain")),t(3),d(e.domainExpiryInfo.domain),t(3),d(l(17,13,"checks.detail.domainExpiry.expiryDate")),t(3),d(e.domainExpiryInfo.expiresAt||(e.domainExpiryInfo.expiryNotMonitorable?l(20,15,"checks.detail.domainExpiry.notMonitorable"):l(21,17,"checks.detail.domainExpiry.notYetDetermined"))),t(3),C(e.domainExpiryInfo.expiryNotMonitorable?-1:22),t(),C(e.domainExpiryInfo.expiryNotMonitorable?23:-1)}}function ni(i,g){if(i&1){let e=O();o(0,"button",111),S("click",function(){let a=M(e).$implicit,p=u(2);return E(p.setUptimeFilter(a.value))}),s(1),n()}if(i&2){let e=g.$implicit,r=u(2);ee("active",e.value===r.activeUptimeFilter),V("data-testid","uptime-filter-"+e.label),t(),k(" ",e.label," ")}}function ai(i,g){i&1&&(o(0,"div",52),w(1,"div",112),o(2,"span"),s(3),c(4,"translate"),n()()),i&2&&(t(3),d(l(4,1,"checks.detail.loadingData")))}function oi(i,g){i&1&&(o(0,"div",53)(1,"p"),s(2),c(3,"translate"),n(),o(4,"p",113),s(5),c(6,"translate"),n()()),i&2&&(t(2),d(l(3,2,"checks.detail.noMonitoringData")),t(3),d(l(6,4,"checks.detail.dataAfterFirstCheck")))}function si(i,g){if(i&1&&(w(0,"div",114),o(1,"div",115)(2,"span",116),w(3,"span",117),s(4),c(5,"translate"),n(),o(6,"span",116),w(7,"span",118),s(8),c(9,"translate"),n(),o(10,"span",116),w(11,"span",119),s(12),c(13,"translate"),n(),o(14,"span",116),w(15,"span",120),s(16),c(17,"translate"),n(),o(18,"span",116),w(19,"span",121),s(20),c(21,"translate"),n()(),o(22,"div",122)(23,"div",123)(24,"span",124),s(25),c(26,"translate"),n(),o(27,"span",125),s(28),n()(),o(29,"div",123)(30,"span",124)(31,"span",126),s(32,"P50"),n(),s(33,":"),n(),o(34,"span",125),s(35),n()(),o(36,"div",123)(37,"span",124)(38,"span",127),s(39,"P95"),n(),s(40,":"),n(),o(41,"span",125),s(42),n()(),o(43,"div",123)(44,"span",124)(45,"span",128),s(46,"P99"),n(),s(47,":"),n(),o(48,"span",125),s(49),n()()()),i&2){let e=u(2);P("options",e.uptimeChartOptions)("merge",e.uptimeChartOptions),t(4),k(" ",l(5,12,"checks.detail.legend.online")),t(4),k(" ",l(9,14,"checks.detail.legend.partialOutage")),t(4),k(" ",l(13,16,"checks.detail.legend.outage")),t(4),k(" ",l(17,18,"checks.detail.legend.maintenance")),t(4),k(" ",l(21,20,"checks.detail.legend.pausedNoData")),t(5),k("",l(26,22,"checks.detail.availability"),":"),t(3),k("",e.uptimePercentage,"%"),t(7),k("",e.p50ResponseTime,"ms"),t(7),k("",e.p95ResponseTime,"ms"),t(7),k("",e.p99ResponseTime,"ms")}}function ri(i,g){if(i&1){let e=O();o(0,"button",111),S("click",function(){let a=M(e).$implicit,p=u(2);return E(p.setResponseFilter(a.value))}),s(1),n()}if(i&2){let e=g.$implicit,r=u(2);ee("active",e.value===r.activeResponseFilter),V("data-testid","response-filter-"+e.label),t(),k(" ",e.label," ")}}function ci(i,g){i&1&&(o(0,"div",55),w(1,"div",112),o(2,"span"),s(3),c(4,"translate"),n()()),i&2&&(t(3),d(l(4,1,"checks.detail.loadingData")))}function li(i,g){i&1&&(o(0,"div",56)(1,"p"),s(2),c(3,"translate"),n()()),i&2&&(t(2),d(l(3,1,"checks.detail.noResponseData")))}function di(i,g){if(i&1&&(w(0,"div",129),o(1,"div",130)(2,"div",123)(3,"span",124),s(4),c(5,"translate"),n(),o(6,"span",125),s(7),n()(),o(8,"div",123)(9,"span",124),s(10),c(11,"translate"),n(),o(12,"span",125),s(13),n()(),o(14,"div",123)(15,"span",124),s(16),c(17,"translate"),n(),o(18,"span",125),s(19),n()(),o(20,"div",123)(21,"span",124),s(22,"~"),o(23,"span",127),s(24,"P95"),n(),s(25,":"),n(),o(26,"span",125),s(27),n()()()),i&2){let e=u(2);P("options",e.responseChartOptions)("merge",e.responseChartOptions),t(4),k("",l(5,9,"checks.detail.chartStats.avg"),":"),t(3),k("",e.avgResponseTime,"ms"),t(3),k("",l(11,11,"checks.detail.chartStats.min"),":"),t(3),k("",e.minResponseTime,"ms"),t(3),k("",l(17,13,"checks.detail.chartStats.max"),":"),t(3),k("",e.maxResponseTime,"ms"),t(8),k("",e.p95ResponseTime,"ms")}}function pi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2,"URL"),n(),o(3,"span",131),s(4),n()(),o(5,"div",60)(6,"span",61),s(7),c(8,"translate"),n(),o(9,"span",62),s(10),n()(),o(11,"div",60)(12,"span",61),s(13),c(14,"translate"),n(),o(15,"span",62),s(16),n()()),i&2){let e,r,a,p=u(2);t(4),d((e=p.getHttpConfig())==null?null:e.url),t(3),d(l(8,5,"checks.detail.configLabels.method")),t(3),d((r=p.getHttpConfig())==null?null:r.method),t(3),d(l(14,7,"checks.detail.configLabels.expectedStatus")),t(3),d(((a=p.getHttpConfig())==null?null:a.expectedStatusCode)||200)}}function hi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",132),s(5),n()()),i&2){let e=u(3);t(2),d(l(3,2,"checks.detail.configLabels.requestBody")),t(3),d(e.check.requestBody)}}function mi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",62),s(5),c(6,"translate"),n()()),i&2){let e=u(3);t(2),d(l(3,3,"checks.detail.configLabels.requestHeaders")),t(3),A("",e.parsedHeaders.length," ",l(6,5,"checks.detail.configLabels.headerCount"))}}function gi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",62),s(5),c(6,"translate"),n()()),i&2){let e=u(3);t(2),d(l(3,3,"checks.detail.configLabels.assertions")),t(3),A("",e.parsedAssertions.length," ",l(6,5,"checks.detail.configLabels.assertionCount"))}}function ui(i,g){if(i&1&&(f(0,hi,6,4,"div",60),f(1,mi,7,7,"div",60),f(2,gi,7,7,"div",60)),i&2){let e=u(2);C(e.check.requestBody?0:-1),t(),C(e.parsedHeaders.length>0?1:-1),t(),C(e.parsedAssertions.length>0?2:-1)}}function fi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()(),o(6,"div",60)(7,"span",61),s(8),c(9,"translate"),n(),o(10,"span",62),s(11),n()()),i&2){let e,r,a=u(2);t(2),d(l(3,4,"checks.detail.configLabels.host")),t(3),d((e=a.getTcpConfig())==null?null:e.host),t(3),d(l(9,6,"checks.detail.configLabels.port")),t(3),d((r=a.getTcpConfig())==null?null:r.port)}}function Ci(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()()),i&2){let e,r=u(2);t(2),d(l(3,2,"checks.detail.configLabels.host")),t(3),d((e=r.getPingConfig())==null?null:e.host)}}function _i(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()()),i&2){let e,r=u(3);t(2),d(l(3,2,"checks.detail.configLabels.expectedValue")),t(3),d((e=r.getDnsConfig())==null?null:e.expectedValue)}}function xi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()()),i&2){let e,r=u(3);t(2),d(l(3,2,"checks.detail.configLabels.nameserver")),t(3),d((e=r.getDnsConfig())==null?null:e.nameserver)}}function ki(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()(),o(6,"div",60)(7,"span",61),s(8),c(9,"translate"),n(),o(10,"span",62),s(11),n()(),f(12,_i,6,4,"div",60),f(13,xi,6,4,"div",60)),i&2){let e,r,a,p,h=u(2);t(2),d(l(3,6,"checks.detail.configLabels.domain")),t(3),d((e=h.getDnsConfig())==null?null:e.hostname),t(3),d(l(9,8,"checks.detail.configLabels.recordType")),t(3),d((r=h.getDnsConfig())==null?null:r.recordType),t(),C((a=h.getDnsConfig())!=null&&a.expectedValue?12:-1),t(),C((p=h.getDnsConfig())!=null&&p.nameserver?13:-1)}}function vi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()(),o(6,"div",60)(7,"span",61),s(8),c(9,"translate"),n(),o(10,"span",62),s(11),n()(),o(12,"div",60)(13,"span",61),s(14),c(15,"translate"),n(),o(16,"span",62),s(17),c(18,"translate"),n()()),i&2){let e,r,a,p=u(2);t(2),d(l(3,7,"checks.detail.configLabels.host")),t(3),d((e=p.getSslConfig())==null?null:e.hostname),t(3),d(l(9,9,"checks.detail.configLabels.port")),t(3),d(((r=p.getSslConfig())==null?null:r.port)||443),t(3),d(l(15,11,"checks.detail.configLabels.warningDays")),t(3),A("",((a=p.getSslConfig())==null?null:a.warningDays)||30," ",l(18,13,"checks.detail.configLabels.days"))}}function bi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",131),s(5),n()(),o(6,"div",60)(7,"span",61),s(8),c(9,"translate"),n(),o(10,"span",62),s(11),c(12,"translate"),n()()),i&2){let e,r,a=u(2);t(2),d(l(3,5,"checks.detail.configLabels.domain")),t(3),d((e=a.getDomainExpiryConfig())==null?null:e.domain),t(3),d(l(9,7,"checks.detail.configLabels.warningThreshold")),t(3),A("",((r=a.getDomainExpiryConfig())==null?null:r.thresholdDays)||30," ",l(12,9,"checks.detail.configLabels.days"))}}function Si(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",62),s(5),n()()),i&2){let e=u(2);t(2),d(l(3,2,"checks.detail.configLabels.keyword")),t(3),d(e.check.keyword)}}function yi(i,g){if(i&1&&(o(0,"span",133),s(1),n()),i&2){let e=g.$implicit;t(),d(e)}}function Mi(i,g){if(i&1&&(o(0,"div",60)(1,"span",61),s(2),c(3,"translate"),n(),o(4,"span",62),B(5,yi,2,1,"span",133,R),n()()),i&2){let e=u(2);t(2),d(l(3,1,"checks.detail.configLabels.tags")),t(3),L(e.check.tags)}}function Ei(i,g){if(i&1&&(o(0,"span"),s(1),n()),i&2){let e=u().$implicit;t(),k(" ",e.expected)}}function Pi(i,g){if(i&1&&(o(0,"div",60)(1,"span",134),s(2),n(),o(3,"span",62),s(4),f(5,Ei,2,1,"span"),n()()),i&2){let e=g.$implicit;t(2),d(e.path),t(2),k(" ",e.operator," "),t(),C(e.operator!=="exists"?5:-1)}}function Di(i,g){if(i&1&&(o(0,"div",63)(1,"div",48)(2,"h2"),s(3),c(4,"translate"),n()(),o(5,"div",51)(6,"div",59),B(7,Pi,6,3,"div",60,R),n()()()),i&2){let e=u(2);t(3),d(l(4,1,"checks.detail.assertionsDetail")),t(4),L(e.parsedAssertions)}}function Ii(i,g){i&1&&(o(0,"div",65)(1,"span",135),s(2,"\u2714"),n(),o(3,"p"),s(4),c(5,"translate"),n()()),i&2&&(t(4),d(l(5,1,"checks.detail.noRecentIncidents")))}function wi(i,g){if(i&1&&(o(0,"div",136)(1,"span",137),s(2),n(),o(3,"div",138)(4,"span",139),s(5),n(),o(6,"span",140),s(7),n(),o(8,"span",141),s(9),n()()()),i&2){let e=g.$implicit,r=u(3);t(),N(e.status),t(),k(" ",e.status==="ongoing"?"\u26A0":"\u2714"," "),t(3),d(e.title),t(2),d(r.formatDate(e.startedAt)),t(2),d(e.duration)}}function Oi(i,g){if(i&1&&(o(0,"div",66),B(1,wi,10,6,"div",136,R),n()),i&2){let e=u(2);t(),L(e.incidents)}}function Ti(i,g){i&1&&(o(0,"div",147)(1,"p"),s(2),c(3,"translate"),n()()),i&2&&(t(2),d(l(3,1,"checks.detail.notificationsDisabled")))}function Ri(i,g){i&1&&(o(0,"div",148),w(1,"div",112),o(2,"span"),s(3),c(4,"translate"),n()()),i&2&&(t(3),d(l(4,1,"common.loading")))}function Bi(i,g){if(i&1&&(o(0,"div",149)(1,"span"),s(2),n()()),i&2){let e=u(4);t(2),d(e.routingError)}}function Li(i,g){if(i&1&&(o(0,"div",152)(1,"span",158),s(2),n()()),i&2){let e=g.$implicit;t(2),A("",e.name," (",e.type,")")}}function Ni(i,g){i&1&&(o(0,"span",153),s(1),c(2,"translate"),n()),i&2&&(t(),k(" ",l(2,1,"checks.detail.noAutoChannels")," "))}function Ai(i,g){i&1&&(o(0,"div",155)(1,"p",113),s(2),c(3,"translate"),n()()),i&2&&(t(2),d(l(3,1,"checks.detail.noAssignedChannelsHint")))}function $i(i,g){if(i&1){let e=O();o(0,"button",163),S("click",function(){M(e);let a=u().$implicit,p=u(6);return E(p.removeRouting(a.channelId))}),s(1," \xD7 "),n()}}function Hi(i,g){if(i&1&&(o(0,"div",160)(1,"span",158),s(2),n(),f(3,$i,2,0,"button",162),n()),i&2){let e=g.$implicit,r=u(6);
1t(2),A("",e.channelName," (",e.channelType,")"),t(),C(r.canManageNotifications?3:-1)}}function Ui(i,g){if(i&1){let e=O();o(0,"button",164),S("click",function(){M(e);let a=u(6);return E(a.resetToAllChannels())}),s(1),c(2,"translate"),n()}i&2&&(t(),k(" ",l(2,1,"checks.detail.resetToDefault")," "))}function Fi(i,g){if(i&1&&(o(0,"div",156)(1,"div",159),B(2,Hi,4,3,"div",160,R),n(),f(4,Ui,3,3,"button",161),n()),i&2){let e=u(5);t(2),L(e.filteredCheckRoutings),t(2),C(e.canManageNotifications?4:-1)}}function zi(i,g){if(i&1&&(o(0,"option",167),s(1),n()),i&2){let e=g.$implicit;P("value",e.id),t(),A("",e.name," (",e.type,")")}}function Vi(i,g){if(i&1){let e=O();o(0,"div",157)(1,"select",165),S("change",function(a){M(e);let p=u(5);return E(p.addRouting(a))}),o(2,"option",166),s(3),c(4,"translate"),n(),B(5,zi,2,3,"option",167,R),n()()}if(i&2){let e=u(5);t(3),d(l(4,1,"checks.detail.addChannel")),t(2),L(e.availableUnroutedChannels)}}function Ki(i,g){if(i&1&&(o(0,"div")(1,"div",150)(2,"h4"),s(3),c(4,"translate"),n(),o(5,"p",113),s(6),c(7,"translate"),n(),o(8,"div",151),B(9,Li,3,2,"div",152,R),f(11,Ni,3,3,"span",153),n()(),o(12,"div",154)(13,"h4"),s(14),c(15,"translate"),n(),f(16,Ai,4,3,"div",155),f(17,Fi,5,1,"div",156),f(18,Vi,7,3,"div",157),n()()),i&2){let e=u(4);t(3),d(l(4,7,"checks.detail.autoChannels")),t(3),d(l(7,9,"checks.detail.autoChannelsHint")),t(3),L(e.autoChannels),t(2),C(e.autoChannels.length===0?11:-1),t(3),d(l(15,11,"checks.detail.assignedChannels")),t(2),C(e.filteredCheckRoutings.length===0?16:-1),t(),C(e.filteredCheckRoutings.length>0?17:-1),t(),C(e.canManageNotifications&&e.availableUnroutedChannels.length>0?18:-1)}}function Wi(i,g){if(i&1&&(o(0,"div"),f(1,Ri,5,3,"div",148),f(2,Bi,3,1,"div",149),f(3,Ki,19,13,"div"),n()),i&2){let e=u(3);t(),C(e.routingLoading?1:-1),t(),C(e.routingError?2:-1),t(),C(!e.routingLoading&&!e.routingError?3:-1)}}function Gi(i,g){if(i&1){let e=O();o(0,"div",67)(1,"div",48)(2,"h2"),s(3),c(4,"translate"),n()(),o(5,"div",51)(6,"div",142)(7,"label",143)(8,"input",144),S("ngModelChange",function(a){M(e);let p=u(2);return E(p.onNotificationsEnabledChange(a))}),n(),w(9,"span",145),n(),o(10,"span",146),s(11),c(12,"translate"),n()(),f(13,Ti,4,3,"div",147),f(14,Wi,4,3,"div"),n()()}if(i&2){let e=u(2);t(3),d(l(4,6,"checks.detail.notificationChannels")),t(5),P("ngModel",e.check.notificationsEnabled)("disabled",!e.canEditNotifications),t(3),d(l(12,8,"checks.detail.notificationsEnabled")),t(2),C(e.check!=null&&e.check.notificationsEnabled?-1:13),t(),C(e.check!=null&&e.check.notificationsEnabled?14:-1)}}function ji(i,g){if(i&1&&(o(0,"div",68)(1,"span"),s(2),c(3,"translate"),n()()),i&2){let e=u(2);t(2),d(ne(3,1,"checks.detail.lastUpdated",te(4,Dt,e.formatRelativeTime(e.lastRefreshAt))))}}function qi(i,g){if(i&1&&(o(0,"div",19),f(1,Lt,13,10,"div",23),f(2,Nt,6,3,"div",24),f(3,At,2,1,"div",25),f(4,$t,19,12,"div",26),f(5,Ht,8,3,"div",27),f(6,Ut,13,13,"div",28),o(7,"div",29)(8,"div",30)(9,"div",31),s(10),c(11,"translate"),n(),o(12,"div",32),s(13),c(14,"uppercase"),n(),f(15,Ft,3,3,"div",33),n(),o(16,"div",30)(17,"div",31)(18,"span",34),s(19),c(20,"translate"),n()(),o(21,"div",35),f(22,zt,3,1)(23,Vt,1,0),n()(),o(24,"div",30)(25,"div",31)(26,"span",36),s(27),c(28,"translate"),n()(),o(29,"div",37),f(30,Kt,1,0),f(31,Wt,1,1),n(),f(32,Gt,3,3,"div",38),n(),o(33,"div",30)(34,"div",31),s(35),c(36,"translate"),n(),o(37,"div",39),s(38),n()(),o(39,"div",40),c(40,"translate"),o(41,"div",31),s(42),c(43,"translate"),n(),o(44,"div",41),s(45),f(46,jt,2,0,"span",42),n()()(),f(47,Jt,9,3,"div",43),f(48,Qt,28,20,"div",44),f(49,Zt,10,6,"div",45),f(50,ii,24,19,"div",46),o(51,"div",47)(52,"div",48)(53,"h2")(54,"span",36),s(55),c(56,"translate"),n()(),o(57,"div",49),B(58,ni,2,4,"button",50,R),n()(),o(60,"div",51),f(61,ai,5,3,"div",52),f(62,oi,7,6,"div",53),f(63,si,50,24),n()(),o(64,"div",47)(65,"div",48)(66,"h2")(67,"span",34),s(68),c(69,"translate"),n()(),o(70,"div",54),B(71,ri,2,4,"button",50,R),n()(),o(73,"div",51),f(74,ci,5,3,"div",55),f(75,li,4,3,"div",56),f(76,di,28,15),n()(),o(77,"div",57)(78,"div",58)(79,"div",48)(80,"h2"),s(81),c(82,"translate"),n()(),o(83,"div",51)(84,"div",59)(85,"div",60)(86,"span",61),s(87),c(88,"translate"),n(),o(89,"span",62),s(90),c(91,"uppercase"),n()(),o(92,"div",60)(93,"span",61),s(94),c(95,"translate"),n(),o(96,"span",62),s(97),n()(),f(98,pi,17,9),f(99,ui,3,3),f(100,fi,12,8),f(101,Ci,6,4,"div",60),f(102,ki,14,10),f(103,vi,19,15),f(104,bi,13,11),f(10
15,Si,6,4,"div",60),f(106,Mi,7,3,"div",60),n()()(),f(107,Di,9,3,"div",63),o(108,"div",58)(109,"div",48)(110,"h2"),s(111),c(112,"translate"),n(),o(113,"a",64),s(114),c(115,"translate"),n()(),o(116,"div",51),f(117,Ii,6,3,"div",65),f(118,Oi,3,0,"div",66),n()()(),f(119,Gi,15,10,"div",67),f(120,ji,4,6,"div",68),n()),i&2){let e=u();t(),C(e.check&&!e.check.enabled?1:-1),t(),C(e.getCheckMode()==="shadow"&&!e.shadowBannerDismissed?2:-1),t(),C(e.modeUpdateError?3:-1),t(),C(e.showActivateConfirmDialog?4:-1),t(),C(e.historyError?5:-1),t(),C(e.isHeartbeatWaitingForFirstPing()?6:-1),t(4),d(l(11,58,"checks.detail.stats.currentStatus")),t(2),N(e.check.status),t(),k(" ",l(14,60,e.check.status)," "),t(2),C(e.getCheckMode()==="shadow"&&e.check.status==="down"?15:-1),t(4),d(l(20,62,"checks.detail.stats.responseTime")),t(3),C(e.check.lastLatencyMs!=null?22:23),t(5),d(l(28,64,"checks.detail.stats.uptime30d")),t(3),C(e.getCheckMode()==="shadow"?30:-1),t(),C(e.getCheckMode()!=="shadow"?31:-1),t(),C(e.getCheckMode()==="shadow"?32:-1),t(3),d(l(36,66,"checks.detail.stats.lastCheck")),t(3),d(e.formatRelativeTime(e.check.lastCheckedAt)),t(),P("title",l(40,68,"checks.detail.stats.p95Hint")),t(3),d(l(43,70,"checks.detail.stats.p95Latency")),t(3),k(" ",e.hasData?e.p95ResponseTime:"\u2014"," "),t(),C(e.hasData&&e.p95ResponseTime>0?46:-1),t(),C(e.check.type!=="heartbeat"&&e.regionStatuses.length>1?47:-1),t(),C((e.check==null?null:e.check.type)==="ssl"&&e.sslExpiryInfo?48:-1),t(),C((e.check==null?null:e.check.type)==="ssl"&&!e.sslExpiryInfo?49:-1),t(),C((e.check==null?null:e.check.type)==="domain-expiry"&&e.domainExpiryInfo?50:-1),t(5),d(l(56,72,"checks.detail.uptimeHistory")),t(3),L(e.uptimeFilterOptions),t(3),C(e.uptimeChartLoading?61:-1),t(),C(!e.uptimeChartLoading&&e.uptimeHistory.length===0?62:-1),t(),C(!e.uptimeChartLoading&&e.uptimeHistory.length>0?63:-1),t(5),d(l(69,74,"checks.detail.responseTimeChart")),t(3),L(e.responseFilterOptions),t(3),C(e.responseChartLoading?74:-1),t(),C(!e.responseChartLoading&&e.responseHistory.length===0?75:-1),t(),C(!e.responseChartLoading&&e.responseHistory.length>0?76:-1),t(5),d(l(82,76,"checks.detail.configuration")),t(6),d(l(88,78,"checks.detail.configLabels.checkType")),t(3),d(l(91,80,e.check.type)),t(4),d(l(95,82,"checks.detail.configLabels.interval")),t(3),d(e.getDisplayInterval()),t(),C(e.check.type==="http"?98:-1),t(),C(e.check.type==="http"&&e.hasApiMonitoringConfig()?99:-1),t(),C(e.check.type==="tcp"?100:-1),t(),C(e.check.type==="ping"?101:-1),t(),C(e.check.type==="dns"?102:-1),t(),C(e.check.type==="ssl"?103:-1),t(),C(e.check.type==="domain-expiry"?104:-1),t(),C(e.check.keyword?105:-1),t(),C(e.check.tags&&e.check.tags.length>0?106:-1),t(),C(e.parsedAssertions.length>0?107:-1),t(4),d(l(112,84,"checks.detail.recentIncidents")),t(2),P("routerLink",e.routes.INCIDENTS)("queryParams",te(88,Et,e.check.id)),t(),d(l(115,86,"checks.detail.viewAll")),t(3),C(e.incidents.length===0?117:-1),t(),C(e.incidents.length>0?118:-1),t(),C(e.hasNotificationsView?119:-1),t(),C(e.lastRefreshAt?120:-1)}}function Yi(i,g){if(i&1){let e=O();o(0,"div",168),S("click",function(){M(e);let a=u();return E(a.cancelDelete())}),o(1,"div",169),S("click",function(a){return a.stopPropagation()}),o(2,"div",75)(3,"h3"),s(4),c(5,"translate"),n(),o(6,"button",76),S("click",function(){M(e);let a=u();return E(a.cancelDelete())}),s(7,"\xD7"),n()(),o(8,"div",77)(9,"p"),s(10),c(11,"translate"),o(12,"strong"),s(13),n(),s(14),c(15,"translate"),n(),o(16,"p",170),s(17),c(18,"translate"),n()(),o(19,"div",78)(20,"button",171),S("click",function(){M(e);let a=u();return E(a.cancelDelete())}),s(21),c(22,"translate"),n(),o(23,"button",172),S("click",function(){M(e);let a=u();return E(a.deleteCheck())}),s(24),c(25,"translate"),n()()()()}if(i&2){let e=u();t(4),d(l(5,7,"checks.detail.deleteModal.title")),t(6),k(" ",l(11,9,"checks.detail.deleteModal.messagePrefix")," "),t(3),d(e.check==null?null:e.check.name),t(),k("",l(15,11,"checks.detail.deleteModal.messageSuffix")," "),t(3),d(l(18,13,"checks.detail.deleteModal.warning")),t(4),d(l(22,15,"common.cancel")),t(3),d(l(25,17,"common.delete"))}}var ft=[{label:"24h",value:1},{label:"7d",value:7},{label:"30d",value:30}],Ct=[{label:"1h",value:1},{label:"3h",value:3},{label:"24h",value:24},{label:"7d",value:168},{label:"30d",value:720}],Ji=2,Nn=(()=>{class i{constructor(){this.routes=Ne,this.route=T(Ee),this.router=T(Pe),this.store=T(Ie),this.checksService=T(dt),this.notificationChannelsService=T(pt),this.formatter=T(Fe),this.pageHeaderService=T(Ue),this.pollingOrchestrator=T(qe),this.appNotificationService=T(Ae),this.translationService=T($e),this.cdr=T(ve),this.destroy$=new J,this.checkSubscriptions$=new J,this.chartLoadTimer=null,this.pollTickCount=0,this.checkId="",this.checkState=v(null),this.loadingState=v(!0),this.errorState=v(""),this.historyErrorState=v(""),this.showDeleteModal=!1,this.uptimeChartLoadingState=v(!1),this.responseChartLoadingState=v(!1),this.uptimeHistoryState=v([]),this.responseHistoryState=v([]),this.incidentsState=v([]),this.parsedHeadersState=v([]),this.parsedAssertionsState=v([]),this.regionStatusesState=v([]),this.sslExpiryInfoState=v(null),this.domainExpiryInfoState=v(null),this.statusPageCountState=v(0),this.statusPageNamesState=v(""),this.shadowModeUiEnabled=!1,this.isModeUpdatingState=v(!1),this.modeUpdateErrorState=v(""),this.showActivateConfirmDialog=!1,this.shadowBannerDismissed=!1,this.checkRoutingsState=v([]),this.availableChannelsState=v([]),this.routingLoadingState=v(!1),this.routingErrorState=v(""),this.hasNotificationsViewState=v(!1),this.canManageNotificationsState=v(!1),this.canEditNotificationsState=v(!1),this._canManageChecks=!1,this.uptimeFilterOptions=ft,this.responseFilterOptions=Ct,this.activeUptimeFilterState=v(30),this.activeResponseFilterState=v(24),this.uptimeChartOptionsState=v({}),this.responseChartOptionsState=v({}
1),this.uptimePercentageState=v(0),this.avgResponseTimeState=v(0),this.minResponseTimeState=v(0),this.maxResponseTimeState=v(0),this.p50ResponseTimeState=v(0),this.p95ResponseTimeState=v(0),this.p99ResponseTimeState=v(0),this.hasDataState=v(!1),this.lastRefreshAtState=v(null),this._autoChannelsCache=[],this._autoChannelsKey=null,this._filteredCheckRoutingsCache=[],this._filteredCheckRoutingsKey=null,this._availableUnroutedChannelsCache=[],this._availableUnroutedChannelsKey=null}get check(){return this.checkState()}set check(e){this.checkState.set(e)}get loading(){return this.loadingState()}set loading(e){this.loadingState.set(e)}get error(){return this.errorState()}set error(e){this.errorState.set(e)}get historyError(){return this.historyErrorState()}set historyError(e){this.historyErrorState.set(e)}get uptimeChartLoading(){return this.uptimeChartLoadingState()}set uptimeChartLoading(e){this.uptimeChartLoadingState.set(e)}get responseChartLoading(){return this.responseChartLoadingState()}set responseChartLoading(e){this.responseChartLoadingState.set(e)}get uptimeHistory(){return this.uptimeHistoryState()}set uptimeHistory(e){this.uptimeHistoryState.set(e)}get responseHistory(){return this.responseHistoryState()}set responseHistory(e){this.responseHistoryState.set(e)}get incidents(){return this.incidentsState()}set incidents(e){this.incidentsState.set(e)}get parsedHeaders(){return this.parsedHeadersState()}set parsedHeaders(e){this.parsedHeadersState.set(e)}get parsedAssertions(){return this.parsedAssertionsState()}set parsedAssertions(e){this.parsedAssertionsState.set(e)}get regionStatuses(){return this.regionStatusesState()}set regionStatuses(e){this.regionStatusesState.set(e)}get sslExpiryInfo(){return this.sslExpiryInfoState()}set sslExpiryInfo(e){this.sslExpiryInfoState.set(e)}get domainExpiryInfo(){return this.domainExpiryInfoState()}set domainExpiryInfo(e){this.domainExpiryInfoState.set(e)}get statusPageCount(){return this.statusPageCountState()}set statusPageCount(e){this.statusPageCountState.set(e)}get statusPageNames(){return this.statusPageNamesState()}set statusPageNames(e){this.statusPageNamesState.set(e)}get isModeUpdating(){return this.isModeUpdatingState()}set isModeUpdating(e){this.isModeUpdatingState.set(e)}get modeUpdateError(){return this.modeUpdateErrorState()}set modeUpdateError(e){this.modeUpdateErrorState.set(e)}get checkRoutings(){return this.checkRoutingsState()}set checkRoutings(e){this.checkRoutingsState.set(e)}get availableChannels(){return this.availableChannelsState()}set availableChannels(e){this.availableChannelsState.set(e)}get routingLoading(){return this.routingLoadingState()}set routingLoading(e){this.routingLoadingState.set(e)}get routingError(){return this.routingErrorState()}set routingError(e){this.routingErrorState.set(e)}get hasNotificationsView(){return this.hasNotificationsViewState()}set hasNotificationsView(e){this.hasNotificationsViewState.set(e)}get canManageNotifications(){return this.canManageNotificationsState()}set canManageNotifications(e){this.canManageNotificationsState.set(e)}get canEditNotifications(){return this.canEditNotificationsState()}set canEditNotifications(e){this.canEditNotificationsState.set(e)}get activeUptimeFilter(){return this.activeUptimeFilterState()}set activeUptimeFilter(e){this.activeUptimeFilterState.set(e)}get activeResponseFilter(){return this.activeResponseFilterState()}set activeResponseFilter(e){this.activeResponseFilterState.set(e)}get uptimeChartOptions(){return this.uptimeChartOptionsState()}set uptimeChartOptions(e){this.uptimeChartOptionsState.set(e)}get responseChartOptions(){return this.responseChartOptionsState()}set responseChartOptions(e){this.responseChartOptionsState.set(e)}get uptimePercentage(){return this.uptimePercentageState()}set uptimePercentage(e){this.uptimePercentageState.set(e)}get avgResponseTime(){return this.avgResponseTimeState()}set avgResponseTime(e){this.avgResponseTimeState.set(e)}get minResponseTime(){return this.minResponseTimeState()}set minResponseTime(e){this.minResponseTimeState.set(e)}get maxResponseTime(){return this.maxResponseTimeState()}set maxResponseTime(e){this.maxResponseTimeState.set(e)}get p50ResponseTime(){return this.p50ResponseTimeState()}set p50ResponseTime(e){this.p50ResponseTimeState.set(e)}get p95ResponseTime(){return this.p95ResponseTimeState()}set p95ResponseTime(e){this.p95ResponseTimeState.set(e)}get p99ResponseTime(){return this.p99ResponseTimeState()}set p99ResponseTime(e){this.p99ResponseTimeState.set(e)}get hasData(){return this.hasDataState()}set hasData(e){this.hasDataState.set(e)}get lastRefreshAt(){return this.lastRefreshAtState()}set lastRefreshAt(e){this.lastRefreshAtState.set(e)}ngOnInit(){this.pageHeaderService.set("checks.title"),this.loadShadowBannerState(),this.store.select(K("notifications.view")).pipe(b(this.destroy$)).subscribe(e=>{let r=!this.hasNotificationsView;this.hasNotificationsView=e,e&&r&&(this.store.dispatch(ht()),this.check?.notificationsEnabled&&this.loadNotificationRouting())}),this.store.select(K("notifications.manage")).pipe(b(this.destroy$)).subscribe(e=>{this.canManageNotifications=e,this.updateCanEditNotifications()}),this.store.select(K("checks.manage")).pipe(b(this.destroy$)).subscribe(e=>{this._canManageChecks=e,this.updateCanEditNotifications()}),this.store.select(mt).pipe(b(this.destroy$)).subscribe(e=>{this.availableChannels=e}),Q([this.route.paramMap.pipe(X(e=>e.get("id")||""),Z()),this.route.queryParamMap.pipe(Z((e,r)=>e.get("uptimeDays")===r.get("uptimeDays")&&e.get("responseHours")===r.get("responseHours")))]).pipe(b(this.destroy$)).subscribe(([e,r])=>{let a=e!==this.checkId;a&&(this.teardownCurrentCheck(),this.checkId=e);let p=parseInt(r.get("uptimeDays")||"",10);this.activeUptimeFilter=ft.some(m=>m.value===p)?p:30;let h=parseInt(r.get("responseHours")||"",10);this.activeResponseFilter=Ct.some(m=>m.value===h)?h:24,a?this.initializeCheck():this.dispatchChartLoads()})}ngOnDestroy(){this.chartLoadTimer!==null&&(clearTimeout(this.chartLoadTimer),this.chartLoadTimer=null),this.checkSubscriptions$.next(),this.checkSubscriptions$.complete(),this.pollingOrchestrator.stopOwner("check-detail-component"),this.destroy$.next(),this.destroy$.complete()}teardownCurrentCheck(){this.checkSubscriptions$.next(),this.pollingOrchestrator.stopOwner("check-detail-component"),this.chartLoadTimer!==null&&(clearTimeout(this.chartLoadTimer),this.chartLoadTimer=null),this.pollTickCount=0,this.check=null,this.loading=!0,this.error="",this.historyError="",this.regionStatuses=[],this.incidents=[],this.uptimeChartLoading=!1,this.responseChartLoading=!1,this.uptimeHistory=[],this.responseHistory=[],this.uptimeChartOptions={},this.responseChartOptions={},this.lastRefreshAt=null,this.statusPageCount=0,this.statusPageNames="",this.checkRoutings=[],this.routingLoading=!1,this.routingError=""}initializeCheck(){this.store.dispatch(j({id:this.checkId})),this.store.dispatch(ct()),this.store.dispatch(de({checkId:this.checkId})),this.store.dispatch(pe({checkId:this.checkId,limit:5})),this.deferChartLoads(),this.store.select(lt(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.statusPageCount=a.length,this.statusPageNames=a.map(p=>p.title).join(", ")}),this.store.select(at(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{let p=this.check;this.check=a,this.parseApiMonitoringData(),this.updateSslExpiryInfo(),this.updateDomainExpiryInfo(),a?.notificationsEnabled&&!p&&this.hasNotificationsView&&!this.routingLoading&&this.loadNotificationRouting()}),this.store.select(ot(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.processUptimeHistoryData(a)}),this.store.select(st(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.processResponseTimesData(a)}),this.store.select(q(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.loading=a.status==="loading"}),this.store.select(tt(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.uptimeChartLoading=a.status==="loading"}),this.store.select(it(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.responseChartLoading=a.status==="loading"}),this.store.select(q(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.error=a.errorMessage||""}),this.store.select(rt(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.regionStatuses=a}),this.store.select(ut(this.checkId)).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe(a=>{this.incidents=a.map(p=>this.mapIncidentToSummary(p))});let e=a=>a.status==="blocked",r=Q([this.store.select(q(this.checkId)),this.store.select(nt(this.checkId)),this.store.select(gt(this.checkId))]).pipe(X(a=>a.some(e)));this.pollingOrchestrator.startPolling({resourceKey:`check-detail-${this.checkId}`,ownerKey:"check-detail-component",intervalMs:3e4,paused$:r}).pipe(b(this.checkSubscriptions$),b(this.destroy$),fe(()=>this.check?.enabled!==!1)).subscribe(()=>{this.store.dispatch(j({id:this.checkId})),this.pollTickCount+=1,this.pollTickCount%Ji===0&&(this.store.dispatch(de({checkId:this.checkId})),this.store.dispatch(pe({checkId:this.checkId,limit:5}))),this.lastRefreshAt=new Date().toISOString()})}mapIncidentToSummary(e){let r=new Date(e.startedAt),a=e.resolvedAt?new Date(e.resolvedAt):void 0,p=e.status==="Resolved",h="";if(a){let m=a.getTime()-r.getTime();h=this.formatDuration(m)}else{let m=Date.now()-r.getTime();h=this.formatDuration(m)+" (ongoing)"}return{id:e.id,title:e.title,startedAt:r,endedAt:a,duration:h,status:p?"resolved":"ongoing"}}formatDuration(e){let r=Math.floor(e/1e3);if(r<60)return`${r}s`;let a=Math.floor(r/60);if(a<60)return`${a}m`;let p=Math.floor(a/60);return p<24?`${p}h ${a%60}m`:`${Math.floor(p/24)}d ${p%24}h`}processUptimeHistoryData(e){let r=this.detectGranularity(e||[]);if(!e||e.length===0){let m=this.fillMissingSlots([],r);this.uptimeHistory=m.map(x=>({date:this.formatSlotLabel(x,r),status:"no-data",uptime:-1})),this.uptimeChartOptions=this.buildUptimeChartOptions(m,r),this.responseHistory.length===0&&(this.hasData=!1);return}this.hasData=!0;let a=this.fillMissingSlots(e,r),p=a.reduce((m,x)=>m+x.totalChecks,0),h=a.reduce((m,x)=>m+x.successfulChecks,0);p>0&&(this.uptimePercentage=Math.round(h/p*1e3)/10),this.uptimeHistory=a.map(m=>{let x=Math.round(m.uptimePercent),_;m.hasPause||m.hasMaintenance?_="partial":m.totalChecks===0?_="no-data":m.uptimePercent===100?_="up":m.uptimePercent===0?_="down":_="partial";let D=!m.hasPause&&!m.hasMaintenance&&m.totalChecks===0;
1return{date:this.formatSlotLabel(m,r),status:_,uptime:D?-1:x}}),this.uptimeChartOptions=this.buildUptimeChartOptions(a,r)}detectGranularity(e){if(e.length>=2&&e.some(a=>!!a.timestamp)){let a=new Date(e[0].timestamp||e[0].date).getTime(),p=new Date(e[1].timestamp||e[1].date).getTime(),h=Math.abs(p-a)/(1e3*60*60);if(h<=1.5)return"hourly";if(h<=7)return"6hour"}return this.activeUptimeFilter===1?"hourly":this.activeUptimeFilter===7&&e.length>0&&e.some(r=>!!r.timestamp)?"6hour":"daily"}formatSlotLabel(e,r){if(r==="hourly")return`${new Date(e.timestamp||e.date).getHours().toString().padStart(2,"0")}:00`;if(r==="6hour"){let p=new Date(e.timestamp||e.date),h=this.formatter.formatDate(p,"medium"),m=p.getHours().toString().padStart(2,"0");return`${h} ${m}:00`}let a=new Date(e.date);return this.formatter.formatDate(a,"medium")}formatTooltipHeader(e,r){if(r==="hourly"){let p=new Date(e.timestamp||e.date),h=p.getHours().toString().padStart(2,"0"),m=new Date(p);m.setHours(m.getHours()+1);let x=m.getHours().toString().padStart(2,"0");return`${h}:00 - ${x}:00`}if(r==="6hour"){let p=new Date(e.timestamp||e.date),h=this.formatter.formatDate(p,"medium"),m=p.getHours().toString().padStart(2,"0"),x=new Date(p);x.setHours(x.getHours()+6);let _=x.getHours().toString().padStart(2,"0");return`${h}, ${m}:00 - ${_}:00`}let a=new Date(e.date);return this.formatter.formatDate(a,"medium")}fillMissingSlots(e,r){return r==="hourly"?this.fillMissingHourlySlots(e,24):r==="6hour"?this.fillMissing6HourSlots(e,28):this.fillMissingDailySlots(e,this.activeUptimeFilter)}fillMissingDailySlots(e,r){let a=new Date,p=new Map;for(let m of e){let x=m.date.substring(0,10);p.set(x,m)}let h=[];for(let m=r-1;m>=0;m--){let x=new Date(a);x.setDate(x.getDate()-m);let _=x.toISOString().substring(0,10);p.has(_)?h.push(p.get(_)):h.push({date:_,uptimePercent:0,totalChecks:0,successfulChecks:0,incidentCount:0})}return h}fillMissingHourlySlots(e,r){let a=new Date;a.setMinutes(0,0,0);let p=new Map;for(let m of e){let x=new Date(m.timestamp||m.date);x.setMinutes(0,0,0);let _=x.toISOString();p.set(_,m)}let h=[];for(let m=r-1;m>=0;m--){let x=new Date(a);x.setHours(x.getHours()-m);let _=x.toISOString();if(p.has(_))h.push(p.get(_));else{let D=x.toISOString().substring(0,10);h.push({date:D,timestamp:_,uptimePercent:0,totalChecks:0,successfulChecks:0,incidentCount:0})}}return h}fillMissing6HourSlots(e,r){let a=new Date,p=a.getHours(),h=Math.floor(p/6)*6;a.setHours(h,0,0,0);let m=new Map;for(let _ of e){let D=new Date(_.timestamp||_.date),y=Math.floor(D.getHours()/6)*6;D.setHours(y,0,0,0);let H=D.toISOString();m.set(H,_)}let x=[];for(let _=r-1;_>=0;_--){let D=new Date(a);D.setHours(D.getHours()-_*6);let y=D.toISOString();if(m.has(y))x.push(m.get(y));else{let H=D.toISOString().substring(0,10);x.push({date:H,timestamp:y,uptimePercent:0,totalChecks:0,successfulChecks:0,incidentCount:0})}}return x}processResponseTimesData(e){let r=this.activeResponseFilter,a=this.fillMissingHours(e||[],r);if(!e||e.length===0){this.responseHistory=a.map(h=>({time:new Date(h.timestamp),value:0})),this.responseChartOptions=this.buildResponseChartOptions(a),this.avgResponseTime=0,this.minResponseTime=0,this.maxResponseTime=0,this.p50ResponseTime=0,this.p95ResponseTime=0,this.p99ResponseTime=0,this.uptimeHistory.length===0&&(this.hasData=!1);return}this.hasData=!0,this.responseHistory=a.map(h=>({time:new Date(h.timestamp),value:Math.round(h.responseTimeMs)}));let p=a.filter(h=>h.responseTimeMs>0).map(h=>Math.round(h.responseTimeMs));if(p.length>0){this.avgResponseTime=Math.round(p.reduce((m,x)=>m+x,0)/p.length),this.minResponseTime=Math.min(...p),this.maxResponseTime=Math.max(...p);let h=[...p].sort((m,x)=>m-x);this.p50ResponseTime=h[Math.floor(h.length*.5)]||0,this.p95ResponseTime=h[Math.floor(h.length*.95)]||0,this.p99ResponseTime=h[Math.floor(h.length*.99)]||0}else this.avgResponseTime=0,this.minResponseTime=0,this.maxResponseTime=0,this.p50ResponseTime=0,this.p95ResponseTime=0,this.p99ResponseTime=0;this.responseChartOptions=this.buildResponseChartOptions(a)}fillMissingHours(e,r){let a=new Date;a.setMinutes(0,0,0);let p=new Map;for(let m of e){let x=new Date(m.timestamp);x.setMinutes(0,0,0);let _=x.toISOString();p.set(_,m)}let h=[];for(let m=r-1;m>=0;m--){let x=new Date(a);x.setHours(x.getHours()-m);let _=x.toISOString();p.has(_)?h.push(p.get(_)):h.push({timestamp:_,responseTimeMs:0})}return h}setUptimeFilter(e){this.router.navigate([],{relativeTo:this.route,queryParams:{uptimeDays:e},queryParamsHandling:"merge"})}deferChartLoads(){this.chartLoadTimer!==null&&clearTimeout(this.chartLoadTimer),this.chartLoadTimer=setTimeout(()=>{this.chartLoadTimer=null,this.checkId&&(this.dispatchChartLoads(),this.cdr.markForCheck())}
1,0)}dispatchChartLoads(){this.dispatchUptimeHistoryLoad(),this.store.dispatch(et({checkId:this.checkId,hours:this.activeResponseFilter,requestToken:W()}))}dispatchUptimeHistoryLoad(){this.activeUptimeFilter===1?this.store.dispatch(le({checkId:this.checkId,days:0,hours:24,requestToken:W()})):this.store.dispatch(le({checkId:this.checkId,days:this.activeUptimeFilter,requestToken:W()}))}setResponseFilter(e){this.router.navigate([],{relativeTo:this.route,queryParams:{responseHours:e},queryParamsHandling:"merge"})}buildUptimeChartOptions(e,r="daily"){let a=e.map(h=>this.formatSlotLabel(h,r));return e.some(h=>h.failedChecks!==void 0)?this.buildStackedUptimeChartOptions(e,a,r):this.buildLegacyUptimeChartOptions(e,a)}buildStackedUptimeChartOptions(e,r,a="daily"){let h=e.map(y=>y.totalChecks===0?0:y.successfulChecks),m=e.map(y=>y.totalChecks===0?0:y.failedChecks??0),x=e.map(y=>y.totalChecks===0?0:y.maintenanceChecks??0),_=e.map(y=>y.totalChecks===0?0:y.pausedChecks??0),D=e.map(y=>y.totalChecks===0?5:0);return{grid:{left:50,right:16,top:16,bottom:48},legend:{data:["OK","Down","Wartung","Pause"],bottom:0,textStyle:{fontSize:11}},xAxis:{type:"category",data:r,axisLabel:{fontSize:10,color:U,rotate:a==="6hour"?30:0,interval:a==="hourly"||a==="6hour"?3:"auto"},axisLine:{show:!1},axisTick:{show:!1}},yAxis:{type:"value",min:0,axisLabel:{fontSize:10,color:U},splitLine:{lineStyle:{color:"#f3f4f6"}}},tooltip:{trigger:"axis",formatter:y=>{let H=y;if(!Array.isArray(H)||H.length===0)return"";let _t=H[0].dataIndex,I=e[_t];if(!I)return"";if(I.totalChecks===0)return`${this.formatTooltipHeader(I,a)}<br/>Keine Daten`;let Y=I.successfulChecks,he=I.failedChecks??0,me=I.maintenanceChecks??0,ge=I.pausedChecks??0,ue=I.totalChecks-me-ge,xt=ue>0?Math.round(Y/ue*1e3)/10:100,kt=I.totalChecks>0?Math.round(Y/I.totalChecks*1e3)/10:0,vt=I.totalChecks>0?Math.round(he/I.totalChecks*1e3)/10:0,$=this.formatTooltipHeader(I,a);return $+=`<br/>OK: ${Y} (${kt}%)`,$+=`<br/>Down: ${he} (${vt}%)`,$+=`<br/>Wartung: ${me}`,$+=`<br/>Pause: ${ge}`,$+=`<br/>Uptime: ${xt}% (exkl. Wartung/Pause)`,I.hasMaintenance&&I.maintenanceLabel&&($+=`<br/>Wartungs-Label: ${I.maintenanceLabel}`),I.hasPause&&($+="<br/>Check pausiert"),$}},series:[{name:"OK",type:"bar",stack:"uptime",data:h,itemStyle:{color:ae},barMaxWidth:20},{name:"Down",type:"bar",stack:"uptime",data:m,itemStyle:{color:oe},barMaxWidth:20},{name:"Wartung",type:"bar",stack:"uptime",data:x,itemStyle:{color:re},barMaxWidth:20},{name:"Pause",type:"bar",stack:"uptime",data:_,itemStyle:{color:ce},barMaxWidth:20},{name:"Keine Daten",type:"bar",stack:"uptime",data:D,itemStyle:{color:se},barMaxWidth:20,legendHoverLink:!1}],animation:!1}}buildLegacyUptimeChartOptions(e,r){let p=e.map(h=>({value:h.totalChecks===0?5:h.uptimePercent,itemStyle:{color:this.getUptimeBarColor(h),borderRadius:[2,2,0,0]}}));return{grid:{left:50,right:16,top:16,bottom:32},xAxis:{type:"category",data:r,axisLabel:{fontSize:10,color:U,rotate:0},axisLine:{show:!1},axisTick:{show:!1}},yAxis:{type:"value",min:0,max:100,axisLabel:{fontSize:10,color:U,formatter:"{value}%"},splitLine:{lineStyle:{color:"#f3f4f6"}}},tooltip:{trigger:"axis",formatter:h=>{let m=h;if(!Array.isArray(m)||m.length===0)return"";let x=m[0].dataIndex,_=e[x];if(!_)return"";if(_.totalChecks===0)return`${m[0].name}<br/>Keine Daten`;if(_.hasMaintenance)return`${m[0].name}<br/>Geplante Wartung: ${_.maintenanceLabel||"Maintenance"}<br/>${_.uptimePercent}% uptime`;if(_.hasPause)return`${m[0].name}<br/>Check pausiert<br/>${_.uptimePercent}% uptime`;let D=`${m[0].name}<br/>Uptime: ${_.uptimePercent}%`;return D+=`<br/>Total: ${_.totalChecks}, OK: ${_.successfulChecks}, Failed: ${_.totalChecks-_.successfulChecks}`,_.incidentCount>0&&(D+=`<br/>Incidents: ${_.incidentCount}`),D}},series:[{type:"bar",data:p,barMaxWidth:20}],animation:!1}}getUptimeBarColor(e){return e.hasMaintenance?re:e.hasPause?ce:e.totalChecks===0?se:e.uptimePercent===100?ae:e.uptimePercent===0?oe:Ye}buildResponseChartOptions(e){let r=e.map(h=>{let m=new Date(h.timestamp);return this.activeResponseFilter<=24?this.formatter.formatTime(m):this.formatter.formatDateTime(m,"medium")}),a=e.map(h=>h.responseTimeMs===0&&!h.isMaintenance&&!h.isPaused?null:Math.round(h.responseTimeMs)),p=[];for(let h=0;h<e.length;h++){let m=e[h];
1(m.isMaintenance||m.isPaused)&&p.push([{xAxis:r[h]},{xAxis:r[Math.min(h+1,r.length-1)]}])}return{grid:{left:50,right:16,top:16,bottom:32},xAxis:{type:"category",data:r,axisLabel:{fontSize:10,color:U,rotate:0},axisLine:{show:!1},axisTick:{show:!1}},yAxis:{type:"value",min:0,axisLabel:{fontSize:10,color:U,formatter:"{value}ms"},splitLine:{lineStyle:{color:"#f3f4f6"}}},tooltip:{trigger:"axis",formatter:h=>{let m=h;if(!Array.isArray(m)||m.length===0)return"";let x=m[0].dataIndex,_=e[x];return _?_.responseTimeMs===0&&!_.isMaintenance&&!_.isPaused?`${m[0].name}<br/>Keine Daten`:_.isMaintenance?`${m[0].name}<br/>Geplante Wartung<br/>${m[0].value}ms`:_.isPaused?`${m[0].name}<br/>Check pausiert<br/>${m[0].value}ms`:`${m[0].name}<br/>Avg: ${m[0].value}ms`:""}},series:[F({type:"line",data:a,connectNulls:!1,itemStyle:{color:G},lineStyle:{width:2,color:G},areaStyle:{color:G,opacity:.15},showSymbol:!1,smooth:!1},p.length>0?{markArea:{silent:!0,data:p}}:{})],animation:!1}}updateSslExpiryInfo(){if(!this.check||this.check.type!=="ssl"){this.sslExpiryInfo=null;return}this.check.certificateExpiresAt&&this.updateSslExpiryInfoFromDate(this.check.certificateExpiresAt)}updateSslExpiryInfoFromDate(e){let r=new Date(e);if(isNaN(r.getTime())){this.sslExpiryInfo=null;return}let a=new Date,p=Math.floor((r.getTime()-a.getTime())/864e5),h=this.getSslWarningLevel(p),m=this.getSslLevelLabel(h),_=Math.max(0,Math.min(100,p/90*100));this.sslExpiryInfo={expiresAt:r,daysRemaining:p,level:h,levelLabel:m,progressPercent:_}}getSslWarningLevel(e){return e<=0?"expired":e<=3||e<=7?"critical":e<=14?"urgent":e<=30?"warning":"ok"}getSslLevelLabel(e){switch(e){case"ok":return"Valid";case"warning":return"Plan Renewal";case"urgent":return"Prioritize Renewal";case"critical":return"Critical";case"expired":return"Expired";default:return"Unknown"}}updateDomainExpiryInfo(){if(!this.check||this.check.type!=="domain-expiry"){this.domainExpiryInfo=null;return}let e=this.check.config,r=e?.domain||"",a=e?.thresholdDays||30,p=null,h=null;if(this.check.certificateExpiresAt){let x=new Date(this.check.certificateExpiresAt);isNaN(x.getTime())||(h=Math.floor((x.getTime()-Date.now())/864e5),p=this.formatter.formatDate(x,"long"))}let m=p===null&&this.check.status==="up"&&!!this.check.lastCheckedAt;this.domainExpiryInfo={domain:r,expiresAt:p,daysRemaining:h,thresholdDays:a,level:this.getDomainExpiryLevel(h,a),rawError:null,expiryNotMonitorable:m}}updateDomainExpiryFromHistory(e){if(!this.domainExpiryInfo||!e||e.length===0||this.domainExpiryInfo.expiresAt||this.domainExpiryInfo.daysRemaining!==null||this.domainExpiryInfo.expiryNotMonitorable)return;let r=[...e].reverse().find(a=>a.error);if(r?.error){let a=this.parseDomainExpiryFromError(r.error);a?this.domainExpiryInfo=z(F({},this.domainExpiryInfo),{daysRemaining:a.daysRemaining,expiresAt:a.daysRemaining!==null?this.formatter.formatDate(new Date(Date.now()+a.daysRemaining*864e5),"long"):null,level:this.getDomainExpiryLevel(a.daysRemaining,this.domainExpiryInfo.thresholdDays),rawError:r.error}):this.domainExpiryInfo=z(F({},this.domainExpiryInfo),{rawError:r.error})}}parseDomainExpiryFromError(e){if(!e)return null;let r=e.match(/Domain (.+?) expires in (\d+) days/);if(r)return{domain:r[1],daysRemaining:parseInt(r[2],10)};let a=e.match(/Domain (.+?) has already expired \(expired (\d+) days ago\)/);return a?{domain:a[1],daysRemaining:-parseInt(a[2],10)}:null}getDomainExpiryLevel(e,r){return e===null?"ok":e<=0?"expired":e<=3||e<=7?"critical":e<=14?"urgent":e<=r?"warning":"ok"}dismissHistoryError(){this.historyError=""}
1getRegionTooltip(e){let r=`${e.region}: ${e.status}`;return e.latencyMs&&(r+=` (${e.latencyMs}ms)`),e.lastCheckAt&&(r+=` - Last check: ${this.formatRelativeTime(e.lastCheckAt)}`),r}hasApiMonitoringConfig(){return!!(this.check?.requestBody||this.parsedHeaders.length>0||this.parsedAssertions.length>0)}parseApiMonitoringData(){if(this.parsedHeaders=[],this.parsedAssertions=[],!!this.check){if(this.check.requestHeaders)try{let e=JSON.parse(this.check.requestHeaders);this.parsedHeaders=Object.entries(e).map(([r,a])=>({key:r,value:a}))}catch{}if(this.check.jsonPathAssertions)try{let e=JSON.parse(this.check.jsonPathAssertions);Array.isArray(e)&&(this.parsedAssertions=e)}catch{}}}getStatusIcon(e){switch(e){case"up":return"\u2714";case"down":return"\u2716";case"paused":return"\u23F8";case"degraded":return"\u26A0";default:return""}}getStatusBadgeClass(e){return e??"pending"}isStatusPending(e){return!e||e==="pending"}isHeartbeatWaitingForFirstPing(){let e=this.check;return e?.type==="heartbeat"&&e.status==="pending"&&!e.lastCheckedAt}getStatusLabel(e){return this.translationService.translate(`checks.status.${this.getStatusBadgeClass(e)}`)}getCheckTarget(){if(!this.check)return"";switch(this.check.type){case"http":case"keyword":return this.check.config.url||"";case"tcp":{let r=this.check.config;return`${r.host}:${r.port}`}case"ping":return this.check.config.host||"";case"dns":{let r=this.check.config;return r.recordType?`${r.hostname} (${r.recordType} Record)`:r.hostname}case"ssl":return this.check.config.hostname||"";case"domain-expiry":return this.check.config.domain||"";default:return""}}getHttpConfig(){return this.check?.type==="http"?this.check.config:null}getTcpConfig(){return this.check?.type==="tcp"?this.check.config:null}getPingConfig(){return this.check?.type==="ping"?this.check.config:null}getDnsConfig(){return this.check?.type==="dns"?this.check.config:null}getSslConfig(){return this.check?.type==="ssl"?this.check.config:null}getDomainExpiryConfig(){return this.check?.type==="domain-expiry"?this.check.config:null}getDisplayInterval(){return this.check?this.check.type==="ssl"?"Every 6 hours (fixed)":this.check.type==="domain-expiry"?"Daily (fixed)":this.formatInterval(this.check.interval):""}formatInterval(e){return e<60?`${e} seconds`:e<3600?`${Math.floor(e/60)} minute${e>=120?"s":""}`:`${Math.floor(e/3600)} hour${e>=7200?"s":""}`}formatRelativeTime(e){if(!e)return"Never";let a=Math.floor((new Date().getTime()-new Date(e).getTime())/1e3);return a<60?"Just now":a<3600?`${Math.floor(a/60)}m ago`:a<86400?`${Math.floor(a/3600)}h ago`:`${Math.floor(a/86400)}d ago`}formatDate(e){return this.formatter.formatDateTime(e,"medium")}formatDateLong(e){return this.formatter.formatDate(e,"long")}formatTime(e){return this.formatter.formatTime(e)}getBarHeight(e){return this.maxResponseTime===0?10:Math.max(10,e/this.maxResponseTime*100)}get autoChannels(){return this._autoChannelsKey===this.availableChannels?this._autoChannelsCache:(this._autoChannelsKey=this.availableChannels,this._autoChannelsCache=this.availableChannels.filter(e=>e.receiveAll&&e.enabled),this._autoChannelsCache)}get filteredCheckRoutings(){let e=this.autoChannels;if(this._filteredCheckRoutingsKey?.auto===e&&this._filteredCheckRoutingsKey?.routings===this.checkRoutings)return this._filteredCheckRoutingsCache;let r=new Set(e.map(a=>a.id));return this._filteredCheckRoutingsCache=this.checkRoutings.filter(a=>!r.has(a.channelId)),this._filteredCheckRoutingsKey={auto:e,routings:this.checkRoutings},this._filteredCheckRoutingsCache}get availableUnroutedChannels(){if(this._availableUnroutedChannelsKey?.channels===this.availableChannels&&this._availableUnroutedChannelsKey?.routings===this.checkRoutings)return this._availableUnroutedChannelsCache;let e=new Set(this.checkRoutings.map(r=>r.channelId));return this._availableUnroutedChannelsCache=this.availableChannels.filter(r=>r.enabled&&!r.receiveAll&&!e.has(r.id)),this._availableUnroutedChannelsKey={channels:this.availableChannels,routings:this.checkRoutings},this._availableUnroutedChannelsCache}updateCanEditNotifications(){this.canEditNotifications=this._canManageChecks&&this.canManageNotifications}loadNotificationRouting(){!this.checkId||!this.hasNotificationsView||(this.routingLoading=!0,this.routingError="",this.notificationChannelsService.getCheckRouting(this.checkId).pipe(b(this.checkSubscriptions$),b(this.destroy$)).subscribe({next:e=>{this.checkRoutings=e,this.routingLoading=!1},error:e=>{console.error("[CheckDetail] Failed to load check routing:",e),this.routingError="Routing data could not be loaded.",this.routingLoading=!1}}))}onNotificationsEnabledChange(e){this.check&&this.checksService.toggleNotifications(this.check.id,e).pipe(b(this.destroy$)).subscribe({next:r=>{this.setCheckNotificationsEnabled(r.notificationsEnabled),e&&this.checkRoutings.length===0&&!this.routingLoading&&this.loadNotificationRouting()},error:r=>{this.setCheckNotificationsEnabled(!e),console.error("[CheckDetail] Failed to toggle notifications:",r)}})}setCheckNotificationsEnabled(e){let r=this.check;r&&(this.check=z(F({},r),{notificationsEnabled:e}))}addRouting(e){let r=e.target,a=r.value;if(!a||!this.check)return;r.value="";let p=[...this.checkRoutings.map(h=>h.channelId),a];this.notificationChannelsService.updateCheckRouting(this.check.id,p).pipe(b(this.destroy$)).subscribe({next:h=>{this.checkRoutings=h},error:h=>{console.error("[CheckDetail] Failed to add routing:",h)}})}removeRouting(e){if(!this.check)return;let r=this.checkRoutings.filter(a=>a.channelId!==e).map(a=>a.channelId);this.notificationChannelsService.updateCheckRouting(this.check.id,r).pipe(b(this.destroy$)).subscribe({next:a=>{this.checkRoutings=a},error:a=>{console.error("[CheckDetail] Failed to remove routing:",a)}})}resetToAllChannels(){this.check&&this.notificationChannelsService.updateCheckRouting(this.check.id,[]).pipe(b(this.destroy$)).subscribe({next:e=>{this.checkRoutings=e,this.appNotificationService.success(this.translationService.translate("checks.detail.resetSuccess"))},error:e=>{console.error("[CheckDetail] Failed to reset routing:",e),this.appNotificationService.error(this.translationService.translate("checks.detail.resetError"))}})}getCheckMode(){return this.check?.mode||"active"}toggleMode(){if(!this.check)return;let e=this.getCheckMode()==="active"?"shadow":"active";if(e==="active"){this.showActivateConfirmDialog=!0;return}this.updateCheckMode(e)}confirmActivate(){this.showActivateConfirmDialog=!1,this.updateCheckMode("active")}cancelActivate(){this.showActivateConfirmDialog=!1}updateCheckMode(e){this.check&&(this.isModeUpdating=!0,this.modeUpdateError="",this.checksService.updateCheck(this.check.id,{mode:e}).pipe(b(this.destroy$)).subscribe({next:r=>{this.check=r,this.isModeUpdating=!1},error:r=>{console.error("[CheckDetail] Failed to update mode:",r),this.isModeUpdating=!1,this.modeUpdateError="Der Modus konnte nicht geaendert werden. Bitte versuche es erneut."}}))}dismissShadowBanner(){this.shadowBannerDismissed=!0;
1try{sessionStorage.setItem("mon_shadow_banner_dismissed_"+this.checkId,"true")}catch{}}loadShadowBannerState(){try{this.shadowBannerDismissed=sessionStorage.getItem("mon_shadow_banner_dismissed_"+this.checkId)==="true"}catch{this.shadowBannerDismissed=!1}}togglePause(){this.check&&(this.check.enabled?this.store.dispatch(Qe({id:this.check.id})):this.store.dispatch(Ze({id:this.check.id})))}retryLoadCheck(){this.error="",this.loading=!0,this.store.dispatch(j({id:this.checkId})),this.dispatchChartLoads()}confirmDelete(){this.showDeleteModal=!0}cancelDelete(){this.showDeleteModal=!1}deleteCheck(){this.check&&(this.store.dispatch(Xe({id:this.check.id})),this.showDeleteModal=!1)}static{this.\u0275fac=function(r){return new(r||i)}}static{this.\u0275cmp=Ce({type:i,selectors:[["mon-check-detail"]],features:[xe([Je()])],decls:37,vars:41,consts:[["data-testid","check-detail-page",1,"check-detail"],[1,"page-header"],[1,"back-link",3,"routerLink"],[1,"header-row"],[1,"header-content"],[1,"status-row"],["role","img",1,"status-badge",3,"ngClass","title"],["aria-hidden","true",1,"pending-dots"],["data-testid","shadow-mode-badge",1,"shadow-badge",2,"background","#f3e8ff","color","#7c3aed","border","1px solid #ddd6fe","border-radius","9999px","padding","0.125rem 0.625rem","font-size","0.75rem","font-weight","500","margin-left","0.5rem"],[1,"subtitle"],[1,"type-badge"],["data-testid","status-pages-badge",1,"status-pages-badge",3,"title"],[1,"header-actions"],["data-testid","activate-mode-btn",1,"btn-primary",2,"min-width","100px",3,"disabled"],["data-testid","shadow-mode-btn",1,"btn-secondary",2,"min-width","100px",3,"disabled"],[1,"btn-secondary",3,"click","monReadonly"],[1,"btn-secondary",3,"routerLink","monReadonly"],[1,"btn-danger",3,"click","monReadonly"],[3,"retry","loading","error","hasData","loadingMessage"],[1,"detail-content"],[1,"modal-overlay"],["data-testid","activate-mode-btn",1,"btn-primary",2,"min-width","100px",3,"click","disabled"],["data-testid","shadow-mode-btn",1,"btn-secondary",2,"min-width","100px",3,"click","disabled"],["data-testid","paused-banner",1,"paused-banner"],["data-testid","shadow-info-banner",2,"background","#f5f3ff","border","1px solid #ddd6fe","border-radius","8px","padding","0.75rem 1rem","color","#5b21b6","font-size","0.8125rem","margin-bottom","1rem","display","flex","align-items","flex-start","gap","0.75rem"],["data-testid","mode-update-error",2,"margin-bottom","1rem","padding","0.75rem 1rem","background","#fee2e2","border","1px solid #fecaca","border-radius","6px","color","#dc2626","font-size","0.875rem"],["data-testid","activate-confirm-dialog",1,"modal-overlay"],["data-testid","history-error-banner",1,"error-banner"],["data-testid","heartbeat-waiting-banner",1,"heartbeat-waiting-banner"],["data-testid","stats-row","kendoTooltip","","filter","[title]","position","top",1,"stats-row"],[1,"stat-card"],[1,"stat-label"],[1,"stat-value","status"],["data-testid","shadow-no-incident-hint",2,"font-size","0.75rem","color","#6b7280","font-style","italic","margin-top","0.25rem"],["monGlossary","response_time"],["data-testid","response-time-stat",1,"stat-value"],["monGlossary","uptime"],["data-testid","uptime-stat",1,"stat-value"],["data-testid","uptime-shadow-hint",2,"font-size","0.6875rem","color","#7c3aed","margin-top","0.125rem"],[1,"stat-value","small"],[1,"stat-card",3,"title"],["data-testid","p95-stat",1,"stat-value"],[1,"unit"],["data-testid","region-status-card",1,"card"],["data-testid","ssl-certificate-card","kendoTooltip","","filter","[title]","position","top",1,"card"],["data-testid","ssl-waiting-card",1,"card"],["data-testid","domain-expiry-card",1,"card"],["kendoTooltip","","filter","[title]","position","top",1,"card"],[1,"card-header"],["data-testid","uptime-time-filter",1,"time-filter-group"],[1,"time-filter-btn",3,"active"],[1,"card-body"],["data-testid","chart-loading",1,"chart-loading"],["data-testid","empty-uptime-chart",1,"empty-chart"],["data-testid","response-time-filter",1,"time-filter-group"],["data-testid","chart-loading-response",1,"chart-loading"],["data-testid","empty-response-chart",1,"empty-chart"],[1,"grid-2"],[1,"card"],[1,"config-list"],[1,"config-row"],[1,"config-label"],[1,"config-value"],["data-testid","assertions-detail-card",1,"card"],[1,"view-all",3,"routerLink","queryParams"],[1,"empty-state"],["data-testid","incident-list",1,"incident-list"],["data-testid","notification-routing-section",1,"card"],["data-testid","refresh-indicator",1,"refresh-indicator"],[1,"paused-icon"],[1,"paused-content"],[1,"btn-primary","btn-sm",3,"click","monReadonly"],[2,"flex","1"],["data-testid","dismiss-shadow-banner",2,"background","none","border","none","color","#7c3aed","font-size","1.125rem","cursor","pointer","padding","0","line-height","1",3,"click"],[1,"modal",2,"max-width","420px",3,"click"],[1,"modal-header"],[1,"close-btn",3,"click"],[1,"modal-body"],[1,"modal-footer"],["data-testid","activate-cancel-btn",1,"btn-secondary",3,"click"],["data-testid","activate-confirm-btn",1,"btn-primary",3,"click"],[1,"error-banner-icon"],[1,"error-banner-text"],["data-testid","dismiss-error-banner",1,"error-banner-close",3,"click"],["aria-hidden","true",1,"heartbeat-waiting-icon"],[1,"heartbeat-waiting-content"],[1,"btn-secondary","btn-sm",3,"routerLink"],[1,"region-badges"],["data-testid","region-badge",1,"region-badge",3,"class","title"],["data-testid","region-badge",1,"region-badge",3,"title"],[1,"region-dot"],[1,"region-name"],[1,"region-latency"],["monGlossary","ssl_certificate"],[1,"certificate-status"],[1,"cert-info-grid"],[1,"cert-info-item"],[1,"cert-info-label"],["data-testid","ssl-expiry-date",1,"cert-info-value"],["data-testid","ssl-days-remaining",1,"cert-info-value"],["data-testid","ssl-level-badge",1,"cert-level-badge"],[1,"cert-progress-bar"],[1,"cert-progress"],[1,"empty-chart"],[1,"domain-status"],["data-testid","domain-expiry-domain",1,"config-value","mono"],["data-testid","domain-expiry-date",1,"config-value"],["data-testid","domain-expiry-not-monitorable",1,"domain-expiry-notice"],["data-testid","domain-expiry-days",1,"config-value"],[1,"notice-badge"],[1,"notice-hint"],[1,"time-filter-btn",3,"click"],[1,"spinner-small"],[1,"hint"],["echarts","","data-testid","uptime-echart",1,"echart-container",3,"options","merge"],[1,"uptime-legend"],[1,"legend-item"],[1,"dot","up"],[1,"dot","partial"],[1,"dot","down"],[1,"dot","maintenance"],[1,"dot","paused"],["data-testid","uptime-summary-stats",1,"chart-stats"],[1,"chart-stat"],[1,"label"],[1,"value"],["monGlossary","p50"],["monGlossary","p95"],["monGlossary","p99"],["echarts","","data-testid","response-echart",1,"echart-container",3,"options","merge"],[1,"chart-stats"],[1,"config-value","mono"],[1,"config-value","mono",2,"max-width","300px","overflow","hidden","text-overflow","ellipsis","white-space","nowrap"],[1,"tag"],[1,"config-label","mono"],[1,"empty-icon"],[1,"incident-item"],[1,"incident-status"],[1,"incident-details"],[1,"incident-title"],[1,"incident-time"],[1,"incident-duration"],["data-testid","notifications-enabled-toggle",1,"notification-toggle"],[1,"toggle-switch"],["type","checkbox","data-testid","notifications-enabled-input",3,"ngModelChange","ngModel","disabled"],[1,"toggle-slider"],[1,"toggle-label"],["data-testid","notifications-disabled",1,"routing-disabled"],["data-testid","routing-loading",1,"chart-loading"],["data-testid","routing-error",1,"routing-error"],["data-testid","auto-channels-section",1,"auto-channels-section"],[1,"channel-chips","auto-chips"],["data-testid","auto-channel-chip",1,"channel-chip","chip-auto"],[1,"n
1o-channels-hint"],["data-testid","assigned-channels-section",1,"assigned-channels-section"],["data-testid","no-assigned-channels",1,"all-channels-info"],["data-testid","routed-channels",1,"routed-channels"],["data-testid","add-channel-select",1,"add-channel"],[1,"chip-text"],[1,"channel-chips","assigned-chips"],["data-testid","channel-chip",1,"channel-chip","chip-assigned"],["data-testid","reset-routing-btn",1,"btn-link"],["data-testid","remove-routing-btn",1,"chip-remove"],["data-testid","remove-routing-btn",1,"chip-remove",3,"click"],["data-testid","reset-routing-btn",1,"btn-link",3,"click"],[1,"channel-select",3,"change"],["value",""],[3,"value"],[1,"modal-overlay",3,"click"],[1,"modal",3,"click"],[1,"warning"],[1,"btn-secondary",3,"click"],[1,"btn-danger",3,"click"]],template:function(r,a){r&1&&(o(0,"div",0)(1,"div",1)(2,"a",2),s(3),c(4,"translate"),n(),o(5,"div",3)(6,"div",4)(7,"div",5)(8,"span",6),f(9,It,4,0,"span",7)(10,wt,1,1),n(),o(11,"h1"),s(12),n(),f(13,Ot,3,3,"span",8),n(),o(14,"p",9)(15,"span",10),s(16),c(17,"uppercase"),n(),f(18,Tt,3,8,"span",11),s(19),n()(),o(20,"div",12),f(21,Rt,4,6,"button",13),f(22,Bt,4,6,"button",14),o(23,"button",15),S("click",function(){return a.togglePause()}),s(24),c(25,"translate"),c(26,"translate"),n(),o(27,"a",16),s(28),c(29,"translate"),n(),o(30,"button",17),S("click",function(){return a.confirmDelete()}),s(31),c(32,"translate"),n()()()(),o(33,"mon-connection-state",18),c(34,"translate"),S("retry",function(){return a.retryLoadCheck()}),n(),f(35,qi,121,90,"div",19),f(36,Yi,26,19,"div",20),n()),r&2&&(t(2),P("routerLink",a.routes.CHECKS),t(),k("\u2190 ",l(4,26,"checks.detail.backToChecks")),t(5),P("ngClass",a.getStatusBadgeClass(a.check==null?null:a.check.status))("title",a.getStatusLabel(a.check==null?null:a.check.status)),V("aria-label",a.getStatusLabel(a.check==null?null:a.check.status)),t(),C(a.isStatusPending(a.check==null?null:a.check.status)?9:10),t(3),d(a.check==null?null:a.check.name),t(),C(a.getCheckMode()==="shadow"?13:-1),t(3),d(l(17,28,a.check==null?null:a.check.type)),t(2),C(a.statusPageCount>0?18:-1),t(),k(" ",a.getCheckTarget()," "),t(2),C(a.shadowModeUiEnabled&&a.getCheckMode()==="shadow"?21:-1),t(),C(a.shadowModeUiEnabled&&a.getCheckMode()==="active"?22:-1),t(),P("monReadonly","checks.manage"),t(),k(" ",a.check!=null&&a.check.enabled?l(25,30,"checks.pause"):l(26,32,"checks.resume")," "),t(3),P("routerLink",ke(40,yt))("monReadonly","checks.manage"),t(),d(l(29,34,"checks.detail.edit")),t(2),P("monReadonly","checks.manage"),t(),k(" ",l(32,36,"checks.detail.delete")," "),t(2),P("loading",a.loading)("error",a.error)("hasData",!!a.check)("loadingMessage",l(34,38,"checks.detail.loadingMessage")),t(2),C(!a.loading&&!a.error&&a.check?35:-1),t(),C(a.showDeleteModal?36:-1))},dependencies:[Me,Se,Le,Re,Be,we,Oe,Te,De,Ve,ze,We,Ke,je,Ge,ye,He],styles:['.check-detail[_ngcontent-%COMP%]{max-width:1200px}.page-header[_ngcontent-%COMP%]{margin-bottom:2rem}.back-link[_ngcontent-%COMP%]{display:inline-block;margin-bottom:.5rem;color:#6b7280;text-decoration:none;font-size:.875rem}.back-link[_ngcontent-%COMP%]:hover{color:var(--mon-primary-color, #3b82f6)}.header-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:flex-start;gap:1rem}.status-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75rem}.status-badge[_ngcontent-%COMP%]{width:36px;height:36px;flex:0 0 36px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:1.25rem;font-weight:700;line-height:1;border:1px solid transparent}.status-badge.up[_ngcontent-%COMP%]{background:#d1fae5;color:#059669}.status-badge.down[_ngcontent-%COMP%]{background:#fee2e2;color:#dc2626}.status-badge.degraded[_ngcontent-%COMP%], .status-badge.paused[_ngcontent-%COMP%]{background:#fef3c7;color:#d97706}.status-badge.pending[_ngcontent-%COMP%]{background:#f3f4f6;color:#6b7280;border-color:#e5e7eb}.pending-dots[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:3px}.pending-dots[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{width:4px;height:4px;border-radius:50%;background:currentColor;opacity:.55;animation:_ngcontent-%COMP%_status-dot-pulse 1.2s ease-in-out infinite}.pending-dots[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(2){animation-delay:.15s}.pending-dots[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(3){animation-delay:.3s}@keyframes _ngcontent-%COMP%_status-dot-pulse{0%,80%,to{opacity:.35;transform:translateY(0)}40%{opacity:1;transform:translateY(-2px)}}@media(prefers-reduced-motion:reduce){.pending-dots[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{animation:none}}.header-content[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:#1f2937}.subtitle[_ngcontent-%COMP%]{margin:.5rem 0 0;color:#6b7280;font-size:.875rem;display:flex;align-items:center;gap:.5rem}.type-badge[_ngcontent-%COMP%]{padding:.125rem .5rem;background:#e0e7ff;color:#4f46e5;border-radius:4px;font-size:.625rem;font-weight:600}.status-pages-badge[_ngcontent-%COMP%]{padding:.125rem .5rem;background:#dcfce7;color:#166534;border-radius:4px;font-size:.625rem;font-weight:500;cursor:default}.header-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}.btn-primary[_ngcontent-%COMP%], .btn-secondary[_ngcontent-%COMP%], .btn-danger[_ngcontent-%COMP%]{padding:.5rem 1rem;border-radius:6px;font-size:.875rem;cursor:pointer;text-decoration:none;display:inline-block}.btn-primary[_ngcontent-%COMP%]{background:var(--mon-primary-color, #3b82f6);color:#fff;border:none}.btn-sm[_ngcontent-%COMP%]{padding:.375rem .75rem;font-size:.8125rem}.btn-secondary[_ngcontent-%COMP%]{background:#fff;color:#374151;border:1px solid #d1d5db}.btn-secondary[_ngcontent-%COMP%]:hover{background:#f9fafb}.btn-danger[_ngcontent-%COMP%]{background:#fff;color:#dc2626;border:1px solid #fecaca}.btn-danger[_ngcontent-%COMP%]:hover{background:#fee2e2}.spinner-small[_ngcontent-%COMP%]{width:20px;height:20px;border:2px solid #e5e7eb;border-top-color:var(--mon-primary-color, #3b82f6);border-radius:50%;animation:_ngcontent-%COMP%_spin .8s linear infinite;display:inline-block}@keyframes _ngcontent-%COMP%_spin{to{transform:rotate(360deg)}}.paused-banner[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;padding:1rem 1.25rem;background:#fef3c7;border:1px solid #fcd34d;border-radius:8px;margin-bottom:1.5rem}.paused-icon[_ngcontent-%COMP%]{font-size:1.5rem;flex-shrink:0}.paused-content[_ngcontent-%COMP%]{flex:1}.paused-content[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{display:block;color:#92400e;margin-bottom:.25rem}.paused-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;font-size:.875rem;color:#78350f}.error-banner[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75rem;padding:.75rem 1rem;background:#fef2f2;border:1px solid #fecaca;border-radius:8px;margin-bottom:1.5rem}.error-banner-icon[_ngcontent-%COMP%]{font-size:1.25rem;color:#dc2626;flex-shrink:0}.error-banner-text[_ngcontent-%COMP%]{flex:1;font-size:.875rem;color:#991b1b}.error-banner-close[_ngcontent-%COMP%]{background:none;border:none;font-size:1.25rem;color:#991b1b;cursor:pointer;padding:0;line-height:1}.error-banner-close[_ngcontent-%COMP%]:hover{color:#7f1d1d}.heartbeat-waiting-banner[_ngcontent-%COMP%]{display:flex;align-items:flex-start;gap:1rem;padding:1rem 1.25rem;background:#eff6ff;border:1px solid #bfdbfe;border-radius:8px;margin-bottom:1.5rem}.heartbeat-waiting-icon[_ngcontent-%COMP%]{width:28px;height:28px;flex:0 0 28px;border-radius:50%;display:flex;align-items:center;justify-content:center;background:#dbeafe;color:#1d4ed8;font-weight:700;font-size:.9375rem;line-height:1}.heartbeat-waiting-content[_ngcontent-%COMP%]{flex:1}.heartbeat-waiting-content[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{display:block;color:#1e3a8a;margin-bottom:.25rem}.heartbeat-waiting-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;font-size:.875rem;color:#1e40af;line-height:1.5}.stats-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(5,1fr);gap:1rem;margin-bottom:1.5rem}.stat-card[_ngcontent-%COMP%]{background:#fff;border-radius:12px;padding:1.25rem;box-shadow:0 1px 3px #0000001a}.stat-label[_ngcontent-%COMP%]{font-size:.75rem;color:#6b7280;text-transform:uppercase;letter-spacing:.05em;margin-bottom:.5rem}.stat-value[_ngcontent-%COMP%]{font-size:1.5rem;font-weight:700;color:#1f2937}.stat-value.small[_ngcontent-%COMP%]{font-size:1rem}.stat-value.status.up[_ngcontent-%COMP%]{color:#059669}.stat-value.status.down[_ngcontent-%COMP%]{color:#dc2626}.stat-value.status.paused[_ngcontent-%COMP%]{color:#d97706}.stat-value[_ngcontent-%COMP%] .unit[_ngcontent-%COMP%]{font-size:.875rem;font-weight:400;color:#6b7280}.region-badges[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.75rem}.region-badge[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:.5rem 1rem;border-radius:8px;font-size:.875rem;background:#f9fafb;border:1px solid #e5e7eb}.region-badge.up[_ngcontent-%COMP%]{background:#ecfdf5;border-color:#a7f3d0}.region-badge.down[_ngcontent-%COMP%]{background:#fef2f2;border-color:#fecaca}.region-badge.unknown[_ngcontent-%COMP%]{background:#f9fafb;border-color:#e5e7eb}.region-dot[_ngcontent-%COMP%]{width:8px;height:8px;border-radius:50%}.region-dot.up[_ngcontent-%COMP%]{background:#059669}.region-dot.down[_ngcontent-%COMP%]{background:#dc2626}.region-dot.unknown[_ngcontent-%COMP%]{background:#9ca3af}
1.region-name[_ngcontent-%COMP%]{font-weight:500;color:#374151}.region-latency[_ngcontent-%COMP%]{color:#6b7280;font-size:.75rem}.card[_ngcontent-%COMP%]{background:#fff;border-radius:12px;box-shadow:0 1px 3px #0000001a;margin-bottom:1.5rem}.card-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;padding:1rem 1.25rem;border-bottom:1px solid #e5e7eb}.card-header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:1rem;font-weight:600;color:#1f2937}.view-all[_ngcontent-%COMP%]{font-size:.875rem;color:var(--mon-primary-color, #3b82f6);text-decoration:none}.view-all[_ngcontent-%COMP%]:hover{text-decoration:underline}.card-body[_ngcontent-%COMP%]{padding:1.25rem}.chart-loading[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;gap:.75rem;padding:2rem 1rem;color:#6b7280;font-size:.875rem}.certificate-status[_ngcontent-%COMP%]{padding:.5rem 0}.cert-info-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem;margin-bottom:1rem}.cert-info-item[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.cert-info-label[_ngcontent-%COMP%]{font-size:.75rem;color:#6b7280;text-transform:uppercase;letter-spacing:.05em}.cert-info-value[_ngcontent-%COMP%]{font-size:1rem;font-weight:600;color:#1f2937}.cert-level-badge[_ngcontent-%COMP%]{display:inline-block;padding:.25rem .75rem;border-radius:9999px;font-size:.8125rem;font-weight:600}.cert-level-badge.ok[_ngcontent-%COMP%]{background:#d1fae5;color:#065f46}.cert-level-badge.warning[_ngcontent-%COMP%]{background:#fef3c7;color:#92400e}.cert-level-badge.urgent[_ngcontent-%COMP%]{background:#ffedd5;color:#9a3412}.cert-level-badge.critical[_ngcontent-%COMP%]{background:#fee2e2;color:#991b1b}.cert-level-badge.expired[_ngcontent-%COMP%]{background:#1f2937;color:#fecaca}.cert-progress-bar[_ngcontent-%COMP%]{height:8px;background:#e5e7eb;border-radius:4px;overflow:hidden}.cert-progress[_ngcontent-%COMP%]{height:100%;border-radius:4px;transition:width .3s ease}.cert-progress.ok[_ngcontent-%COMP%]{background:#059669}.cert-progress.warning[_ngcontent-%COMP%]{background:#d97706}.cert-progress.urgent[_ngcontent-%COMP%]{background:#ea580c}.cert-progress.critical[_ngcontent-%COMP%]{background:#dc2626}.cert-progress.expired[_ngcontent-%COMP%]{background:#1f2937}.domain-status[_ngcontent-%COMP%]{padding:.5rem 0}.domain-expiry-notice[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem;margin-top:.75rem;padding:.75rem;border:1px solid #bfdbfe;background:#eff6ff;border-radius:6px}.domain-expiry-notice[_ngcontent-%COMP%] .notice-badge[_ngcontent-%COMP%]{align-self:flex-start;font-size:.75rem;font-weight:600;color:#1d4ed8;background:#dbeafe;padding:.125rem .5rem;border-radius:9999px}.domain-expiry-notice[_ngcontent-%COMP%] .notice-hint[_ngcontent-%COMP%]{font-size:.8125rem;color:#475569}.uptime-chart[_ngcontent-%COMP%]{display:flex;gap:2px;height:32px;margin-bottom:.75rem}.uptime-bar[_ngcontent-%COMP%]{flex:1;border-radius:4px}.uptime-bar.up[_ngcontent-%COMP%]{background:#059669}.uptime-bar.partial[_ngcontent-%COMP%]{background:#d97706}.uptime-bar.down[_ngcontent-%COMP%]{background:#dc2626}.uptime-legend[_ngcontent-%COMP%]{display:flex;gap:1.5rem;justify-content:center}.legend-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.375rem;font-size:.75rem;color:#6b7280}.dot[_ngcontent-%COMP%]{width:10px;height:10px;border-radius:2px}.dot.up[_ngcontent-%COMP%]{background:#059669}.dot.partial[_ngcontent-%COMP%]{background:#d97706}.dot.down[_ngcontent-%COMP%]{background:#dc2626}.echart-container[_ngcontent-%COMP%]{width:100%;height:200px;margin-bottom:.75rem}.time-filter-group[_ngcontent-%COMP%]{display:flex;gap:.25rem;background:#f3f4f6;border-radius:6px;padding:2px}.time-filter-btn[_ngcontent-%COMP%]{padding:.25rem .625rem;font-size:.75rem;border:none;background:transparent;color:#6b7280;border-radius:4px;cursor:pointer;font-weight:500;transition:all .15s ease}.time-filter-btn[_ngcontent-%COMP%]:hover{color:#374151}.time-filter-btn.active[_ngcontent-%COMP%]{background:#fff;color:#1f2937;box-shadow:0 1px 2px #0000001a}.dot.maintenance[_ngcontent-%COMP%]{background:#60a5fa}.dot.paused[_ngcontent-%COMP%]{background:#9ca3af}.chart-stats[_ngcontent-%COMP%]{display:flex;justify-content:center;gap:2rem;padding-top:.75rem;border-top:1px solid #f3f4f6}.chart-stat[_ngcontent-%COMP%]{font-size:.875rem}.chart-stat[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:#6b7280}.chart-stat[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:600;color:#1f2937}.grid-2[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(2,1fr);gap:1.5rem}.grid-2[_ngcontent-%COMP%] .card[_ngcontent-%COMP%]{margin-bottom:0}.config-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.75rem}.config-row[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:.5rem 0;border-bottom:1px solid #f3f4f6}.config-row[_ngcontent-%COMP%]:last-child{border-bottom:none}.config-label[_ngcontent-%COMP%]{color:#6b7280;font-size:.875rem}.config-value[_ngcontent-%COMP%]{color:#1f2937;font-size:.875rem;font-weight:500}.config-value.mono[_ngcontent-%COMP%]{font-family:monospace;font-size:.8125rem}.config-value.ok[_ngcontent-%COMP%]{color:#059669}.config-value.warning[_ngcontent-%COMP%]{color:#d97706}.config-value.urgent[_ngcontent-%COMP%]{color:#ea580c}.config-value.critical[_ngcontent-%COMP%]{color:#dc2626}.config-value.expired[_ngcontent-%COMP%]{color:#991b1b}.tag[_ngcontent-%COMP%]{display:inline-block;padding:.125rem .375rem;background:#f3f4f6;border-radius:4px;font-size:.75rem;margin-left:.25rem}.empty-chart[_ngcontent-%COMP%]{text-align:center;padding:2rem 1rem;color:#9ca3af}.empty-chart[_ngcontent-%COMP%] .hint[_ngcontent-%COMP%]{font-size:.75rem;margin-top:.25rem}.empty-state[_ngcontent-%COMP%]{text-align:center;padding:2rem 1rem;color:#6b7280}.empty-icon[_ngcontent-%COMP%]{font-size:2rem;opacity:.5;display:block;margin-bottom:.5rem}.empty-state[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}.incident-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.75rem}.incident-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75rem;padding:.5rem 0;border-bottom:1px solid #f3f4f6}.incident-item[_ngcontent-%COMP%]:last-child{border-bottom:none}.incident-status[_ngcontent-%COMP%]{width:32px;height:32px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:.875rem}.incident-status.ongoing[_ngcontent-%COMP%]{background:#fee2e2;color:#dc2626}.incident-status.resolved[_ngcontent-%COMP%]{background:#d1fae5;color:#059669}.incident-details[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column}.incident-title[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:#1f2937}
1.incident-time[_ngcontent-%COMP%], .incident-duration[_ngcontent-%COMP%]{font-size:.75rem;color:#6b7280}.refresh-indicator[_ngcontent-%COMP%]{text-align:center;padding:1rem;font-size:.75rem;color:#9ca3af}.modal-overlay[_ngcontent-%COMP%]{position:fixed;inset:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:1000}.modal[_ngcontent-%COMP%]{background:#fff;border-radius:12px;width:100%;max-width:400px;box-shadow:0 20px 25px -5px #0000001a}.modal-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;padding:1rem 1.25rem;border-bottom:1px solid #e5e7eb}.modal-header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0;font-size:1.125rem;color:#1f2937}.close-btn[_ngcontent-%COMP%]{background:none;border:none;font-size:1.5rem;color:#9ca3af;cursor:pointer;padding:0;line-height:1}.close-btn[_ngcontent-%COMP%]:hover{color:#6b7280}.modal-body[_ngcontent-%COMP%]{padding:1.25rem}.modal-body[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0 0 .75rem;color:#374151}.modal-body[_ngcontent-%COMP%] .warning[_ngcontent-%COMP%]{color:#dc2626;font-size:.875rem}.modal-footer[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.75rem;padding:1rem 1.25rem;border-top:1px solid #e5e7eb;background:#f9fafb;border-radius:0 0 12px 12px}.modal-footer[_ngcontent-%COMP%] .btn-danger[_ngcontent-%COMP%]{background:#dc2626;color:#fff;border:none}.notification-toggle[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75rem;margin-bottom:1rem}.toggle-switch[_ngcontent-%COMP%]{position:relative;display:inline-block;width:40px;height:22px;flex-shrink:0}.toggle-switch[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{opacity:0;width:0;height:0}.toggle-slider[_ngcontent-%COMP%]{position:absolute;cursor:pointer;inset:0;background:#d1d5db;border-radius:22px;transition:background .2s ease}.toggle-slider[_ngcontent-%COMP%]:before{content:"";position:absolute;width:16px;height:16px;left:3px;bottom:3px;background:#fff;border-radius:50%;transition:transform .2s ease}.toggle-switch[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:checked + .toggle-slider[_ngcontent-%COMP%]{background:#059669}.toggle-switch[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:checked + .toggle-slider[_ngcontent-%COMP%]:before{transform:translate(18px)}.toggle-switch[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:disabled + .toggle-slider[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.toggle-label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:#374151}.routing-disabled[_ngcontent-%COMP%]{padding:.75rem 1rem;background:#f9fafb;border:1px solid #e5e7eb;border-radius:8px;color:#6b7280;font-size:.875rem}.routing-disabled[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}.routing-error[_ngcontent-%COMP%]{padding:.75rem 1rem;background:#fef2f2;border:1px solid #fecaca;border-radius:6px;color:#dc2626;font-size:.875rem;margin-bottom:.75rem}.all-channels-info[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;margin-bottom:.75rem}.badge[_ngcontent-%COMP%]{display:inline-block;padding:.25rem .75rem;border-radius:9999px;font-size:.8125rem;font-weight:600;width:fit-content}.badge-success[_ngcontent-%COMP%]{background:#d1fae5;color:#065f46}.all-channels-info[_ngcontent-%COMP%] .hint[_ngcontent-%COMP%]{font-size:.8125rem;color:#6b7280;margin:0}.routed-channels[_ngcontent-%COMP%]{margin-bottom:.75rem}.channel-chips[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.5rem;margin-bottom:.75rem}.channel-chip[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;padding:.375rem .75rem;background:#e0e7ff;border:1px solid #c7d2fe;border-radius:9999px;font-size:.8125rem;color:#3730a3}.chip-text[_ngcontent-%COMP%]{font-weight:500}.chip-remove[_ngcontent-%COMP%]{background:none;border:none;font-size:1rem;color:#6366f1;cursor:pointer;padding:0;line-height:1;font-weight:700}.chip-remove[_ngcontent-%COMP%]:hover{color:#dc2626}.btn-link[_ngcontent-%COMP%]{background:none;border:none;color:var(--mon-primary-color, #3b82f6);font-size:.8125rem;cursor:pointer;padding:0;text-decoration:underline}.btn-link[_ngcontent-%COMP%]:hover{color:#1d4ed8}.add-channel[_ngcontent-%COMP%]{margin-top:.75rem}.channel-select[_ngcontent-%COMP%]{padding:.5rem .75rem;border:1px solid #d1d5db;border-radius:6px;font-size:.875rem;background:#fff;color:#374151;min-width:220px;cursor:pointer}.channel-select[_ngcontent-%COMP%]:focus{outline:none;border-color:var(--mon-primary-color, #3b82f6);box-shadow:0 0 0 2px #3b82f626}.auto-channels-section[_ngcontent-%COMP%]{margin-bottom:16px;padding-bottom:16px;border-bottom:1px solid #e0e0e0}
1.auto-channels-section[_ngcontent-%COMP%] h4[_ngcontent-%COMP%], .assigned-channels-section[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:.875rem;font-weight:600;color:#374151}.chip-auto[_ngcontent-%COMP%]{background-color:#f0f0f0;font-style:italic;cursor:default;color:#6b7280;border-color:#d1d5db}.chip-assigned[_ngcontent-%COMP%]{background-color:#e8f5e9;cursor:default;color:#1b5e20;border-color:#a5d6a7}.chip-assigned[_ngcontent-%COMP%] .chip-remove[_ngcontent-%COMP%]{cursor:pointer;color:#388e3c}.chip-assigned[_ngcontent-%COMP%] .chip-remove[_ngcontent-%COMP%]:hover{color:#d32f2f}.no-channels-hint[_ngcontent-%COMP%]{color:#999;font-style:italic;font-size:.8125rem}@media(max-width:1024px){.stats-row[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)}.grid-2[_ngcontent-%COMP%], .cert-info-grid[_ngcontent-%COMP%]{grid-template-columns:1fr}}@media(max-width:640px){.stats-row[_ngcontent-%COMP%]{grid-template-columns:1fr}.header-row[_ngcontent-%COMP%]{flex-direction:column}.header-actions[_ngcontent-%COMP%]{width:100%;justify-content:flex-start}.heartbeat-waiting-banner[_ngcontent-%COMP%]{flex-direction:column}}'],changeDetection:0})}}return i})();export{Nn as CheckDetailComponent};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.