summaryrefslogtreecommitdiffstats
path: root/src/web/gui/v2/7487.db63c95c27d973a07d9b.chunk.js
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/web/gui/v2/7487.db63c95c27d973a07d9b.chunk.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/web/gui/v2/7487.db63c95c27d973a07d9b.chunk.js b/src/web/gui/v2/7487.db63c95c27d973a07d9b.chunk.js
new file mode 100644
index 000000000..cbc15d0f9
--- /dev/null
+++ b/src/web/gui/v2/7487.db63c95c27d973a07d9b.chunk.js
@@ -0,0 +1 @@
+!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="6e15794f-c21d-4dbd-b39f-a55646c86750",e._sentryDebugIdIdentifier="sentry-dbid-6e15794f-c21d-4dbd-b39f-a55646c86750")}catch(e){}}();var _global="undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:{};_global.SENTRY_RELEASE={id:"30b1ba65cc8722be7e184f4a401fb43e6b21634d"},(self.webpackChunkcloud_frontend=self.webpackChunkcloud_frontend||[]).push([[7487],{18686:(e,t,n)=>{n.d(t,{A:()=>l});var a=n(96540),o=n(83199),r=n(47731);const l=e=>{let{children:t}=e;return(0,r.J)()?a.createElement(o.Layer,{full:!0},a.createElement(o.Flex,{width:"100%",background:"mainBackground","data-testid":"alertView-mobileContainer"},t)):t}},29848:(e,t,n)=>{n.d(t,{Hs:()=>c,c0:()=>l,ly:()=>d,pp:()=>i});n(62953);var a=n(47444);const o=(0,a.eU)({key:"spaceKeyAtom",default:0}),r=(0,a.eU)({key:"roomViewLoading",default:!0}),l=()=>(0,a.vc)(o),d=()=>{const[e,t]=(0,a.L4)(o);return()=>t(e+1)},c=()=>(0,a.vc)(r),i=()=>(0,a.L4)(r)},7356:(e,t,n)=>{n.r(t),n.d(t,{default:()=>d});var a=n(96540),o=n(47767),r=n(41122),l=n(18686);const d=e=>{let{spaceId:t,roomId:n,nodeName:d}=e;const{alertId:c}=(0,o.g)();return a.createElement(l.A,null,a.createElement(r.A,{alertId:c,spaceId:t,roomId:n,nodeName:d,isWebview:!0}))}},41122:(e,t,n)=>{n.d(t,{A:()=>_});var a=n(96540),o=n(83199),r=n(64118),l=n(28738),d=n(47731),c=n(69765),i=n(11164),s=n(43407),u=n(5871),m=n(52768),f=n(47767),g=n(27467),p=n(47762),v=n(8711);const y=(0,v.default)(o.Flex).attrs({alignItems:"center"}).withConfig({displayName:"styled__StyledButtonContainer",componentId:"sc-1glv09p-0"})(["position:sticky;bottom:0;"]);var h=n(38966);const I=(0,n(92155).A)(o.Button),E=e=>{let{disabled:t,nodeId:n,alertId:r,context:l,lastStatusChange:d,onClose:c,isLoading:i,small:s=!1,testid:u="alertDetailsModal"}=e;const m=(0,f.Zp)(),v=(0,p.Zl)(n),E=(0,a.useCallback)((()=>{c&&c(),m(v,r?{state:{alertId:r}}:{state:{contextToGo:l}})}),[v,r]),b=(0,g.rI)(),w=(0,a.useCallback)((()=>{const e=1e3*d;b({highlight:{after:e-6e4,before:e},correlation:!0}),E()}),[d,l,E,r]);return a.createElement(y,{justifyContent:"end",gap:2},a.createElement(o.Flex,{gap:2,justifyContent:"end"},a.createElement(I,{small:s,label:"Run correlations",onClick:w,flavour:"hollow",isLoading:i,width:s?"112px":"170px","data-testid":"".concat(u,"-runCorrelations-button"),"data-ga":"alert-modal::click-run-correlations::alerts-view",payload:{action:"Run correlations",alertId:r,nodeId:n}}),a.createElement(I,{small:s,label:"Go to chart",onClick:E,isLoading:i,disabled:i||t,width:s?"112px":"150px","data-testid":"".concat(u,"-goToNode-button"),"data-ga":"alert-modal::click-goto-chart::alerts-view",payload:{action:"Go to chart",alertId:r,nodeId:n}}),a.createElement(h.A,{alertId:r,nodeId:n,isLoading:i,small:s,"data-testid":"".concat(u,"-edit-alert-button")})))},b=(0,a.memo)(E);var w=n(7660),x=n(40267);const C=e=>{let{alertId:t,context:n,name:r,nodeId:l,status:c,lastStatusChange:i,fullyLoaded:s,isWebview:u}=e;const m=(0,d.J)(),f=m?o.H4:o.H0;return a.createElement(o.Flex,{column:!0,gap:4},a.createElement(o.Flex,{justifyContent:"between"},a.createElement(o.Flex,{alignItems:"center",gap:2},a.createElement(x.A,{margin:m?null:[.5,0,0],flavour:c,"data-testid":"alertView-statusPill"},c),a.createElement(f,{"data-testid":"alertView-alertName"},r)),!1),a.createElement(o.Flex,{justifyContent:"between",alignItems:"center"},a.createElement(w.A,{alertId:t}),!u&&s&&!m&&a.createElement(b,{lastStatusChange:i,alertId:t,context:n,name:r,nodeId:l,small:!0,testid:"alertView"})))};var A=n(68831),S=n(63314);const k=v.default.img.withConfig({displayName:"sc-404__Illustration",componentId:"sc-4w81fg-0"})(["height:35%;width:35%;"]),N=v.default.div.withConfig({displayName:"sc-404__ButtonContainer",componentId:"sc-4w81fg-1"})(["margin:",";"],(0,o.getSizeBy)(4)),L=()=>{const e="".concat(A.A.assetsBaseURL,"/img/no-nodes-room.svg");return a.createElement(S.DL,null,a.createElement(o.Flex,{column:!0,alignItems:"center",justifyItems:"center",justifyContent:"center",height:"100%",width:"100%",padding:[0,0,"10%"]},a.createElement(k,{src:e,alt:"Unreachable alert",title:"Unreachable alert"}),a.createElement(o.H3,null,"We couldn't find the alert"),a.createElement(o.Text,null,"This can be a temporary problem of that specific alert."),a.createElement(N,null,a.createElement(o.Button,{label:"Retry",icon:"reload"}))))};var R=n(4974),T=n(73865),D=n(85686);const V=e=>{let{children:t}=e;return a.createElement(o.Flex,{background:"modalHeaderBackground",height:12,flex:!1,gap:4,padding:[0,2,0,4],alignItems:"center"},a.createElement(o.Icon,{name:"logo_s",color:"success",width:"23px"}),t)},_=e=>{let{alertId:t,spaceId:n,roomId:f,isWebview:g,nodeName:p}=e;const v=(0,c.XA)("name"),{isNodeRestricted:y}=(0,T.A)(),{fullyLoaded:h=!1,fullyLoading:I=!0,info:E,units:b,lastStatusChangeValue:w,lastStatusChange:x,context:A,instance:k,name:N,nodeId:_,status:F,lastUpdated:j,value:B}=(0,r.JL)(t);(0,r.yk)(t,{spaceId:n,roomId:f});const U=(0,m.J4)(B,b),M=(0,m.J4)(w,b),O=(0,d.J)();return _&&y(_)?a.createElement(S.Ay,{feature:"AlertDetailsViewRestricted"},a.createElement(D.A,null)):a.createElement(S.Ay,{feature:"AlertDetailsView"},a.createElement(o.Flex,{column:!0,width:O?"100%":{max:280},padding:O?null:[0,0,10],background:O?"modalBackground":null},!g&&O&&a.createElement(V,null,a.createElement(o.Flex,{column:!0},a.createElement(o.H6,{color:"textLite"},"ROOM"),a.createElement(o.Text,{"data-testid":"alertView-mobile-roomName"},v))),a.createElement(o.Flex,{column:!0,padding:O?[3]:[0],overflow:O?"auto":"visible",gap:3},a.createElement(C,{alertId:t,context:A,status:F,name:N,nodeId:_,lastStatusChange:x,fullyLoaded:h,isWebview:g}),h?null:I?a.createElement(l.A,{title:"Loading alert..."}):a.createElement(L,null),h&&E&&a.createElement(a.Fragment,null,a.createElement(s.A,{iconName:"documentation"},"Alert Description"),a.createElement(o.Text,{"data-testid":"alertView-info"},E),a.createElement(R.A,{alertId:t})),h&&a.createElement(i.A,{id:t,context:A,instance:k,formattedLastValue:U,formattedLastStatusChangeValue:M,lastStatusChange:x,lastUpdated:j,isFormattedValueLoaded:h,nodeId:_,status:F,testid:"alertView",spaceId:n,roomId:f}),h&&a.createElement(u.A,{id:t,nodeName:p,testid:"alertView"})),O&&a.createElement(o.Box,{position:"sticky",padding:[4],background:"modalBackground",bottom:0,border:{side:"top",color:"border"}},a.createElement(o.TextSmall,null,"In order to ",a.createElement(o.TextSmall,{strong:!0},"Run Correlations")," or"," ",a.createElement(o.TextSmall,{strong:!0},"View the Chart")," you will have to visit this alert from its' dedicated page on a desktop device."))))}},20378:(e,t,n)=>{n.d(t,{Ay:()=>f,OS:()=>u,Q8:()=>m});n(62953);var a=n(96540),o=n(47444),r=n(3914),l=n(22292),d=n(79731),c=n(9224);const i=(0,o.Iz)({key:"userAccessAtom",default:{loaded:!1,loading:!1,userStatus:"notLoggedIn",userNodeStatus:"noAccess",nodeId:null,spaceId:null,roomIds:[],error:""}}),s=(0,o.Iz)({key:"checkUserAccess",default:()=>1}),u=()=>{var e;const t=null===(e=window.localNetdataRegistry)||void 0===e?void 0:e.mg,n=(0,o.lZ)(s(t));return(0,a.useCallback)((()=>n((e=>e+1))),[t])},m=()=>{var e;const t=null===(e=window.localNetdataRegistry)||void 0===e?void 0:e.mg;return(0,o.L4)(i({machineGuid:t}))},f=()=>{var e;const t=(0,r.dg)(),n=null===(e=window.localNetdataRegistry)||void 0===e?void 0:e.mg,[i,u]=(0,o.L4)(s(n)),[f,g]=m(n),{loading:p}=f,v=(0,l.uW)("isAnonymous");return(0,a.useEffect)((()=>{!p&&n&&t&&!v&&(g((e=>({loading:!0,nodeId:null,spaceId:null,roomIds:[],...e}))),(0,c.az)(n).then((e=>{let{data:t}=e;g({loading:!1,loaded:!0,...t,error:""})})).catch((e=>{var t;const n=null===e||void 0===e||null===(t=e.response)||void 0===t?void 0:t.data;g({loading:!1,loaded:!0,error:(0,d.o)(null===n||void 0===n?void 0:n.errorMsgKey)||(null===n||void 0===n?void 0:n.errorMessage)||"Something went wrong",userStatus:"notLoggedIn",userNodeStatus:"noAccess",nodeId:null,spaceId:null,roomIds:[]})})))}),[n,i,t,v,p]),{...f,checkAgain:u}}},84428:(e,t,n)=>{var a=n(78227)("iterator"),o=!1;try{var r=0,l={next:function(){return{done:!!r++}},return:function(){o=!0}};l[a]=function(){return this},Array.from(l,(function(){throw 2}))}catch(d){}e.exports=function(e,t){try{if(!t&&!o)return!1}catch(d){return!1}var n=!1;try{var r={};r[a]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch(d){}return n}},87290:(e,t,n)=>{var a=n(50516),o=n(19088);e.exports=!a&&!o&&"object"==typeof window&&"object"==typeof document},50516:e=>{e.exports="object"==typeof Deno&&Deno&&"object"==typeof Deno.version},19088:(e,t,n)=>{var a=n(24475),o=n(44576);e.exports="process"===o(a.process)},10916:(e,t,n)=>{var a=n(24475),o=n(80550),r=n(94901),l=n(92796),d=n(33706),c=n(78227),i=n(87290),s=n(50516),u=n(96395),m=n(77388),f=o&&o.prototype,g=c("species"),p=!1,v=r(a.PromiseRejectionEvent),y=l("Promise",(function(){var e=d(o),t=e!==String(o);if(!t&&66===m)return!0;if(u&&(!f.catch||!f.finally))return!0;if(!m||m<51||!/native code/.test(e)){var n=new o((function(e){e(1)})),a=function(e){e((function(){}),(function(){}))};if((n.constructor={})[g]=a,!(p=n.then((function(){}))instanceof a))return!0}return!t&&(i||s)&&!v}));e.exports={CONSTRUCTOR:y,REJECTION_EVENT:v,SUBCLASSING:p}},90537:(e,t,n)=>{var a=n(80550),o=n(84428),r=n(10916).CONSTRUCTOR;e.exports=r||!o((function(e){a.all(e).then(void 0,(function(){}))}))},96167:(e,t,n)=>{var a=n(46518),o=n(69565),r=n(79306),l=n(36043),d=n(1103),c=n(72652);a({target:"Promise",stat:!0,forced:n(90537)},{allSettled:function(e){var t=this,n=l.f(t),a=n.resolve,i=n.reject,s=d((function(){var n=r(t.resolve),l=[],d=0,i=1;c(e,(function(e){var r=d++,c=!1;i++,o(n,t,e).then((function(e){c||(c=!0,l[r]={status:"fulfilled",value:e},--i||a(l))}),(function(e){c||(c=!0,l[r]={status:"rejected",reason:e},--i||a(l))}))})),--i||a(l)}));return s.error&&i(s.value),n.promise}})},33436:(e,t,n)=>{function a(e,{target:t=document.body}={}){if("string"!==typeof e)throw new TypeError(`Expected parameter \`text\` to be a \`string\`, got \`${typeof e}\`.`);const n=document.createElement("textarea"),a=document.activeElement;n.value=e,n.setAttribute("readonly",""),n.style.contain="strict",n.style.position="absolute",n.style.left="-9999px",n.style.fontSize="12pt";const o=document.getSelection(),r=o.rangeCount>0&&o.getRangeAt(0);t.append(n),n.select(),n.selectionStart=0,n.selectionEnd=e.length;let l=!1;try{l=document.execCommand("copy")}catch{}return n.remove(),r&&(o.removeAllRanges(),o.addRange(r)),a&&a.focus(),l}n.d(t,{A:()=>a})},14123:(e,t,n)=>{function a(e){return t=>{const n=(e?Math[e]:Math.trunc)(t);return 0===n?0:n}}n.d(t,{u:()=>a})},25733:(e,t,n)=>{n.d(t,{z:()=>o});var a=n(2642);function o(e,t){const n=(0,a.a)(e),o=(0,a.a)(t),r=n.getTime()-o.getTime();return r<0?-1:r>0?1:r}},31826:(e,t,n)=>{n.d(t,{k:()=>s});var a=n(96519),o=n(82695),r=n(14123),l=n(40215),d=n(25733),c=n(2940),i=n(2642);function s(e,t,n){const s=(0,o.q)(),u=n?.locale??s.locale??a.c,m=(0,d.z)(e,t);if(isNaN(m))throw new RangeError("Invalid time value");const f=Object.assign({},n,{addSuffix:n?.addSuffix,comparison:m});let g,p;m>0?(g=(0,i.a)(t),p=(0,i.a)(e)):(g=(0,i.a)(e),p=(0,i.a)(t));const v=(0,r.u)(n?.roundingMethod??"round"),y=p.getTime()-g.getTime(),h=y/c.Cg,I=(y-((0,l.G)(p)-(0,l.G)(g)))/c.Cg,E=n?.unit;let b;if(b=E||(h<1?"second":h<60?"minute":h<c.F6?"hour":I<c.Nw?"day":I<c.Ks?"month":"year"),"second"===b){const e=v(y/1e3);return u.formatDistance("xSeconds",e,f)}if("minute"===b){const e=v(h);return u.formatDistance("xMinutes",e,f)}if("hour"===b){const e=v(h/60);return u.formatDistance("xHours",e,f)}if("day"===b){const e=v(I/c.F6);return u.formatDistance("xDays",e,f)}if("month"===b){const e=v(I/c.Nw);return 12===e&&"month"!==E?u.formatDistance("xYears",1,f):u.formatDistance("xMonths",e,f)}{const e=v(I/c.Ks);return u.formatDistance("xYears",e,f)}}}}]); \ No newline at end of file