2 lines
74 KiB
JavaScript
2 lines
74 KiB
JavaScript
"use strict";(self.webpackChunkportal_ui=self.webpackChunkportal_ui||[]).push([[1182],{23804:function(e,t,i){i(72791);var n=i(11135),a=i(25787),l=i(61889),r=i(80184);t.Z=(0,a.Z)((function(e){return(0,n.Z)({root:{border:"1px solid #E2E2E2",borderRadius:2,backgroundColor:"#FBFAFA",paddingLeft:25,paddingTop:31,paddingBottom:21,paddingRight:30},leftItems:{fontSize:16,fontWeight:"bold",marginBottom:15,display:"flex",alignItems:"center","& .min-icon":{marginRight:15,height:28,width:38}},helpText:{fontSize:16,paddingLeft:5}})}))((function(e){var t=e.classes,i=e.iconComponent,n=e.title,a=e.help;return(0,r.jsx)("div",{className:t.root,children:(0,r.jsxs)(l.ZP,{container:!0,children:[(0,r.jsxs)(l.ZP,{item:!0,xs:12,className:t.leftItems,children:[i,n]}),(0,r.jsx)(l.ZP,{item:!0,xs:12,className:t.helpText,children:a})]})})}))},63856:function(e,t,i){var n=i(1413),a=(i(72791),i(11135)),l=i(25787),r=i(64554),o=i(61889),s=i(36151),d=i(27197),c=i(32686),x=i(23814),u=i(80705),p=i(85090),f=i(15900),h=i(80184),m=function(){return(0,h.jsx)(r.Z,{sx:{display:"flex",alignItems:"center","& .min-icon":{width:"10px",height:"10px"}},children:(0,h.jsx)(f.Q2V,{})})};t.Z=(0,l.Z)((function(e){return(0,a.Z)((0,n.Z)((0,n.Z)((0,n.Z)({},x.OR),x.bN),{},{syncButton:{"&.MuiButton-root .MuiButton-iconSizeMedium > *:first-of-type":{fontSize:18}},schedulerIcon:{opacity:.4,fontSize:10,"& svg":{width:18,height:18}},selectorLabel:{color:"#9D9E9D",fontWeight:"bold",whiteSpace:"nowrap",marginLeft:10,fontSize:12}}))}))((function(e){var t=e.classes,i=e.timeStart,n=e.setTimeStart,a=e.timeEnd,l=e.setTimeEnd,x=e.triggerSync,f=e.label,g=void 0===f?"Filter:":f,v=e.startLabel,j=void 0===v?"Start Time:":v,b=e.endLabel,y=void 0===b?"End Time:":b;return(0,h.jsx)(o.ZP,{item:!0,xs:12,sx:{"& .filter-date-input-label, .end-time-input-label":{display:"none"},"& .MuiInputBase-adornedEnd.filter-date-date-time-input":{width:"100%",border:"1px solid #eaeaea",paddingLeft:"8px",paddingRight:"8px",borderRadius:"1px"},"& .MuiInputAdornment-root button":{height:"20px",width:"20px",marginRight:"5px"},"& .filter-date-input-wrapper":{height:"30px",width:"100%","& .MuiTextField-root":{height:"30px",width:"90%","& input.Mui-disabled":{color:"#000000",WebkitTextFillColor:"#101010"}}}},children:(0,h.jsxs)(r.Z,{sx:{display:"grid",height:{md:"40px",xs:"auto"},alignItems:"center",gridTemplateColumns:{md:"auto 2fr auto",sm:"1fr"},padding:{md:"0",xs:" 5px"},gap:"5px"},children:[(0,h.jsx)(r.Z,{sx:{fontSize:"14px",fontWeight:500,marginRight:"5px"},children:g}),(0,h.jsxs)(r.Z,{sx:{display:"grid",height:{md:"40px",xs:"auto"},border:{md:"1px solid #eaeaea"},alignItems:"center",gridTemplateColumns:{md:"1fr 1fr",sm:"1fr"},gap:"8px",paddingLeft:"8px",paddingRight:"8px"},children:[(0,h.jsxs)(r.Z,{sx:{display:"grid",height:"30px",alignItems:"center",gridTemplateColumns:{xs:"12px auto 1fr"},gap:"5px"},children:[(0,h.jsx)(r.Z,{sx:{display:"flex",alignItems:"center","& .min-icon":{width:"10px",height:"10px",fill:"#B4B5B4"}},children:(0,h.jsx)(d.Z,{className:"min-icon"})}),(0,h.jsx)(r.Z,{sx:{fontSize:"12px",marginLeft:"8px"},children:j}),(0,h.jsx)(r.Z,{children:(0,h.jsx)(u.Z,{value:i,onChange:n,id:"stTime",classNamePrefix:"filter-date-",forFilterContained:!0,noInputIcon:!0,openPickerIcon:m})})]}),(0,h.jsxs)(r.Z,{sx:{display:"grid",height:"30px",alignItems:"center",gridTemplateColumns:{xs:"12px auto 1fr"},gap:"5px"},children:[(0,h.jsx)(r.Z,{sx:{display:"flex",alignItems:"center","& .min-icon":{width:"10px",height:"10px",fill:"#B4B5B4"}},children:(0,h.jsx)(c.Z,{className:"min-icon"})}),(0,h.jsx)(r.Z,{sx:{fontSize:"12px",marginLeft:"8px"},children:y}),(0,h.jsx)(r.Z,{children:(0,h.jsx)(u.Z,{value:a,onChange:l,id:"endTime",classNamePrefix:"filter-date-",forFilterContained:!0,noInputIcon:!0,openPickerIcon:m})})]})]}),x&&(0,h.jsx)(r.Z,{sx:{alignItems:"flex-end",display:"flex",justifyContent:"flex-end",marginRight:"35px"},children:(0,h.jsx)(s.Z,{type:"button",variant:"contained",color:"primary",onClick:x,endIcon:(0,h.jsx)(p.Z,{}),className:t.syncButton,children:"Sync"})})]})})}))},80705:function(e,t,i){var n=i(1413),a=i(72791),l=i(27391),r=i(61889),o=i(30829),s=i(20068),d=i(49979),c=i(69783),x=i(71652),u=i(63466),p=i(27197),f=i(11135),h=i(25787),m=i(84570),g=i(23814),v=i(33976),j=i(80184);t.Z=(0,h.Z)((function(e){return(0,f.Z)((0,n.Z)((0,n.Z)({dateSelectorOverride:{height:40,border:"#EAEDEE 1px solid",marginLeft:15,backgroundColor:"#fff",padding:"0 16px",borderRadius:5,"&.MuiInput-underline:hover:not(.Mui-disabled):before":{borderBottom:0},"&:hover":{borderColor:"#000","&:before, &:after":{borderColor:"transparent",borderBottom:0}},"&:before, &:after":{borderColor:"transparent",borderBottom:0},"& input":{fontSize:12,fontWeight:600,color:"#393939"}},dateSelectorFilterOverride:{width:180,height:42,marginLeft:20,padding:0,borderRadius:5,"&.MuiInput-underline:hover:not(.Mui-disabled):before":{borderBottom:0},"&:hover":{"&:before, &:after":{borderColor:"transparent",borderBottom:0}},"&:before, &:after":{borderColor:"transparent",borderBottom:0},"& input":{fontSize:12,fontWeight:"bold",color:"#081C42"},"@media (max-width: 900px)":{width:103}},dateSelectorFormOverride:{width:"100%",maxWidth:840},parentDateOverride:{flexGrow:1},textBoxContainer:{flexGrow:1},openListIcon:{color:"#9D9E9D",width:8,marginTop:2},paperOverride:{"& .MuiCalendarPicker-root":{padding:"0 22px","& > div":{padding:0,"& > div > div.PrivatePickersFadeTransitionGroup-root:first-of-type":{color:"#0A224C",fontWeight:"bold"},"& > div > div.PrivatePickersFadeTransitionGroup-root:last-of-type":{color:"#9D9E9D","& + button.MuiButtonBase-root":{color:"#9D9E9D"}},"& > div:nth-child(2)":{"& > div":{width:0},"& > button.MuiButtonBase-root":{color:"#0A224C"}}}},"& .MuiTypography-root.MuiTypography-caption":{width:26,height:26,margin:5,color:"#BCBCBC",fontSize:10},"& button.MuiPickersDay-root":{fontWeight:"bold",width:26,height:26,margin:5,textAlign:"center","&.Mui-selected":{backgroundColor:e.palette.primary.main,color:"#fff"}},"& div.MuiPickersDay-hiddenDaySpacingFiller":{width:26,height:26,margin:5},"& div.PrivatePickersSlideTransition-root":{minHeight:240},"& div.MuiCalendarPicker-viewTransitionContainer":{borderTop:"#F0F3F5 1px solid"},"& .MuiClockPicker-arrowSwitcher":{marginRight:10,marginTop:-1,"& > div":{width:0},"& > button.MuiButtonBase-root":{color:"#0A224C"},"& + div > div":{width:255,height:255,backgroundColor:"#fff",marginTop:30,marginBottom:14,border:"#F0F3F5 3px solid","& > div:nth-child(2)":{backgroundColor:"#B4B5B4",width:12,height:12,"&::before":{content:"' '",width:35,height:35,display:"block",position:"absolute",border:"#F0F3F5 3px solid",top:-12,left:-12,borderRadius:"100%"}},"& > div:nth-child(3)":{backgroundColor:"#B4B5B4",width:4},"& > div:last-of-type":{marginTop:15,"& > span":{color:"#0A224C","&.Mui-selected":{color:"#fff"},"&[aria-label='1 hours'], &[aria-label='2 hours'], &[aria-label='3 hours'], &[aria-label='4 hours'], &[aria-label='5 hours'], &[aria-label='6 hours'], &[aria-label='7 hours'], &[aria-label='8 hours'], &[aria-label='9 hours'], &[aria-label='10 hours'], &[aria-label='11 hours'], &[aria-label='12 hours']":{fontWeight:"bold",fontSize:20,marginTop:-1}}}}}}},g.YI),g.Hr))}))((function(e){var t=e.value,i=e.onChange,f=e.classes,h=e.forSearchBlock,g=void 0!==h&&h,b=e.forFilterContained,y=void 0!==b&&b,Z=e.label,C=e.tooltip,w=void 0===C?"":C,S=e.required,E=e.id,N=e.disabled,T=void 0!==N&&N,F=e.noInputIcon,I=void 0!==F&&F,A=e.classNamePrefix,k=void 0===A?"":A,L=e.openPickerIcon,B={};I||(B={startAdornment:(0,j.jsx)(u.Z,{position:"start",children:(0,j.jsx)(p.Z,{})})}),y&&(B={endAdornment:(0,j.jsx)(u.Z,{position:"end",children:(0,j.jsx)(v.Z,{className:f.openListIcon})})});var R="".concat(k,"date-time-input ").concat(g?f.dateSelectorOverride:""," ").concat(y&&!g?f.dateSelectorFilterOverride:""),W=g?f.parentDateOverride:f.dateSelectorFormOverride,D=(0,j.jsx)(x._,{dateAdapter:c.Z,children:(0,j.jsx)(d.x,{value:t,onChange:i,InputProps:(0,n.Z)((0,n.Z)({},B),{},{className:R}),components:{OpenPickerIcon:L},label:"",className:W,disabled:T,renderInput:function(e){return(0,j.jsx)(l.Z,(0,n.Z)((0,n.Z)({id:E,variant:"standard"},e),{},{disabled:!0}))},ampm:!1,PopperProps:{className:f.paperOverride}})});if(g)return D;var z=y?"":f.fieldContainer;return(0,j.jsx)(a.Fragment,{children:(0,j.jsxs)(r.ZP,{item:!0,xs:12,className:"".concat(z," ").concat(k,"input-field-container "),children:[""!==Z&&(0,j.jsxs)(o.Z,{htmlFor:E,className:"".concat(f.inputLabel," ").concat(k,"input-label"),children:[(0,j.jsxs)("span",{children:[Z,S?"*":""]}),""!==w&&(0,j.jsx)("div",{className:f.tooltipContainer,children:(0,j.jsx)(s.Z,{title:w,placement:"top-start",children:(0,j.jsx)("div",{className:f.tooltip,children:(0,j.jsx)(m.Z,{})})})})]}),(0,j.jsx)("div",{className:"".concat(f.textBoxContainer," ").concat(k,"input-wrapper "),children:D})]})})}))},56028:function(e,t,i){var n=i(29439),a=i(1413),l=i(72791),r=i(60364),o=i(13400),s=i(55646),d=i(5574),c=i(65661),x=i(39157),u=i(11135),p=i(25787),f=i(23814),h=i(81551),m=i(29823),g=i(28057),v=i(87995),j=i(80184);t.Z=(0,p.Z)((function(e){return(0,u.Z)((0,a.Z)((0,a.Z)({},f.Qw),{},{content:{padding:25,paddingBottom:0},customDialogSize:{width:"100%",maxWidth:765}},f.sN))}))((function(e){var t=e.onClose,i=e.modalOpen,u=e.title,p=e.children,f=e.classes,b=e.wideLimit,y=void 0===b||b,Z=e.noContentPadding,C=e.titleIcon,w=void 0===C?null:C,S=(0,h.TL)(),E=(0,l.useState)(!1),N=(0,n.Z)(E,2),T=N[0],F=N[1],I=(0,r.v9)((function(e){return e.system.modalSnackBar}));(0,l.useEffect)((function(){S((0,v.MK)(""))}),[S]),(0,l.useEffect)((function(){if(I){if(""===I.message)return void F(!1);"error"!==I.type&&F(!0)}}),[I]);var A=y?{classes:{paper:f.customDialogSize}}:{maxWidth:"lg",fullWidth:!0},k="";return I&&(k=I.detailedErrorMsg,(""===I.detailedErrorMsg||I.detailedErrorMsg.length<5)&&(k=I.message)),(0,j.jsxs)(d.Z,(0,a.Z)((0,a.Z)({open:i,classes:f},A),{},{scroll:"paper",onClose:function(e,i){"backdropClick"!==i&&t()},className:f.root,children:[(0,j.jsxs)(c.Z,{className:f.title,children:[(0,j.jsxs)("div",{className:f.titleText,children:[w," ",u]}),(0,j.jsx)("div",{className:f.closeContainer,children:(0,j.jsx)(o.Z,{"aria-label":"close",id:"close",className:f.closeButton,onClick:t,disableRipple:!0,size:"small",children:(0,j.jsx)(m.Z,{})})})]}),(0,j.jsx)(g.Z,{isModal:!0}),(0,j.jsx)(s.Z,{open:T,className:f.snackBarModal,onClose:function(){F(!1),S((0,v.MK)(""))},message:k,ContentProps:{className:"".concat(f.snackBar," ").concat(I&&"error"===I.type?f.errorSnackBar:"")},autoHideDuration:I&&"error"===I.type?1e4:5e3}),(0,j.jsx)(x.Z,{className:Z?"":f.content,children:p})]}))}))},31300:function(e,t,i){i(72791);var n=i(64554),a=i(15900),l=i(80184);t.Z=function(e){var t=e.onlineCount,i=void 0===t?0:t,r=e.offlineCount,o=void 0===r?0:r,s=e.icon,d=void 0===s?null:s,c=e.label,x=void 0===c?"":c,u=e.okStatusText,p=void 0===u?"Online":u,f=e.notOkStatusText,h=void 0===f?"Offline":f;return(0,l.jsx)(n.Z,{sx:{fontFamily:"Lato,sans-serif",color:"#07193E",maxWidth:"321px",display:"flex",marginLeft:"auto",marginRight:"auto",cursor:"default"},children:(0,l.jsxs)(n.Z,{sx:{flex:1,display:"flex",padding:{sm:"0 8px 0 8px",xs:"0 10px 0 10px"}},children:[(0,l.jsxs)(n.Z,{sx:{flex:1,display:"flex",flexFlow:"column"},children:[(0,l.jsx)(n.Z,{sx:{fontSize:"16px",fontWeight:600},children:x}),(0,l.jsxs)(n.Z,{sx:{display:"flex",alignItems:"center",gap:"5px",justifyContent:"space-between",paddingBottom:{md:"0px",xs:"10px"},fontSize:{xl:"55px",lg:"50px",md:"45px",xs:"35px"},flexFlow:"row",fontWeight:600,"& .stat-text":{color:"#696969",fontSize:"12px",marginTop:"8px"},"& .stat-value":{textAlign:"center",height:"50px"},"& .min-icon":{marginRight:"8px",marginTop:"8px",height:"10px",width:"10px"}},children:[(0,l.jsxs)(n.Z,{children:[(0,l.jsx)(n.Z,{className:"stat-value",children:i}),(0,l.jsxs)(n.Z,{sx:{display:"flex",alignItems:"center",marginTop:"5px","& .min-icon":{fill:"#4CCB92"}},children:[(0,l.jsx)(a.J$M,{}),(0,l.jsx)("div",{className:"stat-text",children:p})]})]}),(0,l.jsxs)(n.Z,{children:[(0,l.jsx)(n.Z,{className:"stat-value",children:o}),(0,l.jsxs)(n.Z,{sx:{display:"flex",alignItems:"center",marginTop:"8px","& .min-icon":{fill:"#C83B51"}},children:[(0,l.jsx)(a.J$M,{})," ",(0,l.jsx)("div",{className:"stat-text",children:h})]})]})]})]}),(0,l.jsx)(n.Z,{sx:{width:"20px",height:"20px",marginTop:"8px",maxWidth:"26px","& .min-icon":{width:"16px",height:"16px"}},children:d})]})})}},879:function(e,t,i){i.d(t,{D_:function(){return r},Et:function(){return a},GJ:function(){return l},yh:function(){return n}});var n={RED:"#C83B51",GREEN:"#4CCB92",YELLOW:"#E7A219"},a=function(e,t){return e<=t/2?n.RED:2!==t&&e===t/2+1?n.YELLOW:e===t?n.GREEN:void 0},l=function(e){switch(e){case"offline":return n.RED;case"online":return n.GREEN;default:return n.YELLOW}},r=function(e,t){return e<=t/2?n.RED:e===t/2+1?n.YELLOW:e===t?n.GREEN:void 0}},21182:function(e,t,i){i.r(t),i.d(t,{default:function(){return mt}});var n,a=i(29439),l=i(1413),r=i(72791),o=i(26181),s=i.n(o),d=i(93433),c=i(60364),x=i(61889),u=i(11135),p=i(25787),f=i(64554),h=i(23814);!function(e){e.singleValue="singleValue",e.linearGraph="linearGraph",e.areaGraph="areaGraph",e.barChart="barChart",e.pieChart="pieChart",e.singleRep="singleRep",e.simpleWidget="simpleWidget"}(n||(n={}));var m=i(45248),g=i(51846),v=i(82332),j=i(15900),b=i(80184),y=["#C4D4E9","#DCD1EE","#D1EEE7","#EEDED1","#AAF38F","#F9E6C5","#C83B51","#F4CECE","#D6D6D6"],Z=function(e){return(0,m.v1)(e,"ns")},C=function(e){return parseInt(e).toString(10)},w=[{id:1,title:"Uptime",data:"N/A",type:n.simpleWidget,widgetIcon:(0,b.jsx)(j.oNq,{}),labelDisplayFunction:m.v1},{id:50,title:"Capacity",data:[],dataOuter:[{name:"outer",value:100}],widgetConfiguration:{outerChart:{colorList:["#9c9c9c"],innerRadius:0,outerRadius:0,startAngle:0,endAngle:0},innerChart:{colorList:y,innerRadius:20,outerRadius:50,startAngle:90,endAngle:-200}},type:n.pieChart,innerLabel:"N/A",labelDisplayFunction:m.ae},{id:51,title:"Usable Capacity",data:[],dataOuter:[{name:"outer",value:100}],widgetConfiguration:{outerChart:{colorList:["#9c9c9c"],innerRadius:0,outerRadius:0,startAngle:0,endAngle:0},innerChart:{colorList:y,innerRadius:20,outerRadius:50,startAngle:90,endAngle:-200}},type:n.pieChart,innerLabel:"N/A",labelDisplayFunction:m.ae},{id:68,title:"Data Usage Growth",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.areaGraph,yAxisFormatter:m.ae,xAxisFormatter:m.Ue},{id:52,title:"Object size distribution",data:[],widgetConfiguration:[{dataKey:"a",color:"#2781B0",background:{fill:"#EEF1F4"},greatestColor:"#081C42"}],customStructure:[{originTag:"LESS_THAN_1024_B",displayTag:"Less than 1024B"},{originTag:"BETWEEN_1024_B_AND_1_MB",displayTag:"Between 1024B and 1MB"},{originTag:"BETWEEN_1_MB_AND_10_MB",displayTag:"Between 1MB and 10MB"},{originTag:"BETWEEN_10_MB_AND_64_MB",displayTag:"Between 10MB and 64MB"},{originTag:"BETWEEN_64_MB_AND_128_MB",displayTag:"Between 64MB and 128MB"},{originTag:"BETWEEN_128_MB_AND_512_MB",displayTag:"Between 128MB and 512MB"},{originTag:"GREATER_THAN_512_MB",displayTag:"Greater than 512MB"}],type:n.barChart},{id:66,title:"Buckets",data:[],innerLabel:"N/A",type:n.singleRep,color:"#0071BC",fillColor:"#ADD5E0"},{id:44,title:"Objects",data:[],innerLabel:"N/A",type:n.singleRep,color:"#0071BC",fillColor:"#ADD5E0"},{id:63,title:"API Data Received Rate",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000",strokeWidth:3}],type:n.linearGraph,xAxisFormatter:m.Ue,yAxisFormatter:m.ae},{id:61,title:"Total Open FDs",data:[],innerLabel:"N/A",type:n.singleRep,color:"#22B573",fillColor:"#A6E8C4"},{id:62,title:"Total Goroutines",data:[],innerLabel:"N/A",type:n.singleRep,color:"#F7655E",fillColor:"#F4CECE"},{id:77,title:"Node CPU Usage",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:C,xAxisFormatter:m.Ue},{id:60,title:"API Request Rate",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:C,xAxisFormatter:m.Ue},{id:70,title:"API Data Sent Rate",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,xAxisFormatter:m.Ue,yAxisFormatter:m.ae},{id:17,title:"Internode Data Transfer",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:m.ae,xAxisFormatter:m.Ue},{id:73,title:"Node IO",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:m.ae,xAxisFormatter:m.Ue},{id:80,title:"Time Since Last Heal Activity",data:"N/A",type:n.simpleWidget,widgetIcon:(0,b.jsx)(g.Z,{}),labelDisplayFunction:Z},{id:81,title:"Time Since Last Scan Activity",data:"N/A",type:n.simpleWidget,widgetIcon:(0,b.jsx)(v.Z,{}),labelDisplayFunction:Z},{id:71,title:"API Request Error Rate",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,xAxisFormatter:m.Ue},{id:76,title:"Node Memory Usage",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,xAxisFormatter:m.Ue,yAxisFormatter:m.ae},{id:74,title:"Drive Used Capacity",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,xAxisFormatter:m.Ue,yAxisFormatter:m.ae},{id:82,title:"Drives Free Inodes",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,disableYAxis:!0,xAxisFormatter:m.Ue},{id:11,title:"Node Syscalls",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:C,xAxisFormatter:m.Ue},{id:8,title:"Node File Descriptors",data:[],widgetConfiguration:[{dataKey:"",keyLabel:"",lineColor:"#000",fillColor:"#000"}],type:n.linearGraph,yAxisFormatter:C,xAxisFormatter:m.Ue},{id:500,mergedPanels:[{id:53,title:"Online",data:"N/A",type:n.singleValue},{id:69,title:"Offline",data:"N/A",type:n.singleValue}],title:"Servers"},{id:501,mergedPanels:[{id:9,title:"Online",data:"N/A",type:n.singleValue},{id:78,title:"Offline",data:"N/A",type:n.singleValue}],title:"Drives"},{id:502,mergedPanels:[{id:65,title:"Upload",data:"N/A",type:n.singleValue,labelDisplayFunction:m.ae},{id:64,title:"Download",data:"N/A",type:n.singleValue,labelDisplayFunction:m.ae}],title:"Network"}],S=function(e,t){if(0===e.length)return["","0"];if("mean"===t){var i=e.reduce((function(e,t){return e+parseFloat(t[1])}),0);return["",Math.floor(i/e.length).toString()]}var n=e.sort((function(e,t){return e[0]-t[0]}));return n[n.length-1]},E=function(e,t){if(!e)return t;var i=e.type;switch(t.type){case n.singleValue:case n.simpleWidget:if("stat"===i||"singlestat"===i){var a=s()(e,"targets[0].result[0].values",[]);null===a&&(a=[]);var r=s()(e,"options.reduceOptions.calcs[0]","lastNotNull"),o=S(a,r),d=t.labelDisplayFunction?t.labelDisplayFunction(o[1]):o[1];return(0,l.Z)((0,l.Z)({},t),{},{data:d})}break;case n.pieChart:if("gauge"===i){var c=s()(e,"options.reduceOptions.calcs[0]","lastNotNull"),x=s()(e,"targets",[]).filter((function(e){return null!==e})),u=x.map((function(e){var t=(e.result&&Array.isArray(e.result)?e.result:[]).map((function(t){var i=s()(t,"values",[]),n=Object.keys(t.metric),a=i.sort((function(e,t){return parseInt(e[0][1])-parseInt(t[0][1])})),l=t.metric[n[0]],r=a[a.length-1];return{name:l,value:parseInt(r[1]),legend:e.legendFormat}}));return t})),p=x[0].result&&x[0].result.length>0?x[0].result[0].values:[],f=S(p,c),h=t.labelDisplayFunction?t.labelDisplayFunction(f[1]):f[1];return(0,l.Z)((0,l.Z)({},t),{},{data:u,innerLabel:h})}break;case n.linearGraph:case n.areaGraph:if("graph"===i){var g=s()(e,"targets",[]);null===g&&(g=[]);var v=[],j=[];g.forEach((function(e,t){var i=s()(e,"result",[]),n=e.legendFormat;null===i&&(i=[]),i.forEach((function(e){var i=function(e,t){var i=Object.keys(e),n=new RegExp("{{(".concat(i.join("|"),")}}"),"g"),a=t.replace(n,(function(t){var i=t.replace(/({{|}})/g,"");return e[i]})),l=(a.match(/{{/g)||[]).length,r=(a.match(/}}/g)||[]).length,o=a.replace(/{{(.*?)}}/g,"");return l===r&&0!==l&&0!==r&&(i.forEach((function(t){a=a.replace(t,e[t])})),o=a),o}(e.metric,n),a="key_".concat(t).concat(i);v.push({dataKey:a,keyLabel:i,lineColor:"",fillColor:""});var l=s()(e,"values",[]);null===l&&(l=[]),l.forEach((function(e){var t=j.findIndex((function(t){return t.name===e[0]}));if(-1===t){var i={name:e[0]};i[a]=e[1],j.push(i)}else j[t][a]=e[1]}))}))}));var b=v.sort((function(e,t){return e.keyLabel<t.keyLabel?-1:e.keyLabel>t.keyLabel?1:0})).map((function(e,t){return(0,l.Z)((0,l.Z)({},e),{},{lineColor:y[t]||(0,m.C5)(e.keyLabel),fillColor:y[t]||(0,m.C5)(e.keyLabel)})})),Z=j.sort((function(e,t){return e.name-t.name}));return(0,l.Z)((0,l.Z)({},t),{},{widgetConfiguration:b,data:Z})}break;case n.barChart:if("bargauge"===i){var C=s()(e,"targets[0].result",[]);null===C&&(C=[]);var w=function(e,t){return e[0]-t[0]},E=[];return E=t.customStructure?t.customStructure.map((function(e){var t=C.find((function(t){var i=Object.keys(t.metric);return t.metric[i[0]]===e.originTag})),i=s()(t,"values",[]).sort(w),n=i[i.length-1]||["","0"];return{name:e.displayTag,a:parseInt(n[1])}})):C.map((function(e){var t=Object.keys(e.metric),i=e.metric[t[0]],n=s()(e,"values",[]).sort(w),a=n[n.length-1]||["","0"];return{name:i,a:parseInt(a[1])}})),(0,l.Z)((0,l.Z)({},t),{},{data:E})}break;case n.singleRep:if("stat"===i){var N=s()(e,"targets[0].result[0].values",[]);null===N&&(N=[]);var T=s()(e,"options.reduceOptions.calcs[0]","lastNotNull"),F=S(N,T),I=N.sort((function(e,t){return e[0]-t[0]})),A=[];1===I.length&&A.push({value:0}),I.forEach((function(e){A.push({value:parseInt(e[1])})}));var k=t.labelDisplayFunction?t.labelDisplayFunction(F[1]):F[1];return(0,l.Z)((0,l.Z)({},t),{},{data:A,innerLabel:k})}}return t},N=function(e){var t=e.split(" "),i=function(){var t=e;return isNaN(parseFloat(e))||(t=(0,m.nk)(parseFloat(e))),(0,b.jsx)(r.Fragment,{children:t})};return 2!==t.length?i():m.Dl.includes(t[1])?(0,b.jsxs)("span",{className:"commonValue",children:[t[0],(0,b.jsx)("span",{className:"unitText",children:t[1]})]}):i()},T=i(19847),F=i(81207),I=i(72455),A=i(18073),k=i(43896),L=(0,I.Z)({tabRoot:{height:"40px",borderBottom:"1px solid #eaeaea"},root:{width:"120px",backgroundColor:"transparent",paddingTop:0,paddingBottom:0,fontSize:"14px",fontWeight:600,color:"#07193E",height:"40px"},selected:{"&.MuiTab-selected":{backgroundColor:"#F6F7F7 !important"},"&.MuiTab-wrapper":{color:"#07193E",fontWeight:600}},indicator:{background:"transparent linear-gradient(90deg, #072B4E 0%, #081C42 100%) 0% 0% no-repeat padding-box;",height:2},scroller:{maxWidth:1185,position:"relative","&::after":{content:'" "',backgroundColor:"#EEF1F4",height:2,width:"100%",display:"block"}}}),B=function(e){var t=e.selectedTab,i=e.onChange,n=e.tabOptions,a=L();return(0,b.jsx)(r.Fragment,{children:(0,b.jsx)(A.Z,{indicatorColor:"primary",textColor:"primary","aria-label":"cluster-tabs",variant:"scrollable",scrollButtons:"auto",value:t,onChange:function(e,t){i(t)},classes:{root:a.tabRoot,indicator:a.indicator,scroller:a.scroller},children:n.map((function(e,t){var i={label:e.label};return e.value&&(i=(0,l.Z)((0,l.Z)({},i),{},{value:e.value})),e.disabled&&(i=(0,l.Z)((0,l.Z)({},i),{},{disabled:e.disabled})),(0,r.createElement)(k.Z,(0,l.Z)((0,l.Z)({},i),{},{classes:{root:a.root,selected:a.selected},id:"simple-tab-".concat(t),"aria-controls":"simple-tabpanel-".concat(t),key:"tab-".concat(t,"-").concat(e.label)}))}))})})},R=i(19913),W=i(38725),D=i(90466),z=i(12891),P=i(24714),M=i(41048),O=i(35667),G=i(95193),U=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)({},h.Rp))}))((function(e){var t=e.active,i=e.payload,n=e.label,a=e.barChartConfiguration,l=e.classes;return t?(0,b.jsxs)("div",{className:l.customTooltip,children:[(0,b.jsx)("div",{className:l.timeStampTitle,children:n}),i&&i.map((function(e,t){return(0,b.jsxs)("div",{className:l.labelContainer,children:[(0,b.jsx)("div",{className:l.labelColor,style:{backgroundColor:a[t].color}}),(0,b.jsx)("div",{className:l.itemValue,children:(0,b.jsx)("span",{className:l.valueContainer,children:e.value})})]},"pltiem-".concat(t,"-").concat(n))}))]}):null})),_=i(29598),K=i(72401),V=i(64119),H=i(71080),$=i(81551),Y=function(e){var t=e.panelItem,i=(0,$.TL)();return(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",gap:"10px","& .link-text":{color:"#2781B0",fontSize:"12px",fontWeight:600},"& .zoom-graph-icon":{backgroundColor:"transparent",border:0,padding:0,cursor:"pointer","& svg":{color:"#D0D0D0",height:16},"&:hover":{"& svg":{color:"#404143"}}}},children:[(0,b.jsx)("a",{href:"void:(0);",rel:"noreferrer noopener",className:"link-text",onClick:function(e){e.preventDefault(),i((0,H.xG)(t))},children:"Expand Graph"}),(0,b.jsx)("button",{onClick:function(){i((0,H.xG)(t))},className:"zoom-graph-icon",children:(0,b.jsx)(V.Z,{})})]})},J=i(87995),q=function(e){var t=e.y,i=e.payload;return(0,b.jsx)("text",{width:50,fontSize:"69.7%",textAnchor:"start",fill:"#333",transform:"translate(5,".concat(t,")"),fontWeight:400,dy:3,children:i.value})},Q=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)({},h.NP),{},{loadingAlign:{width:"100%",paddingTop:"15px",textAlign:"center",margin:"auto"}}))}))((function(e){var t=e.classes,i=e.title,n=e.panelItem,l=e.timeStart,o=e.timeEnd,s=e.propLoading,d=e.apiPrefix,c=e.zoomActivated,x=void 0!==c&&c,u=(0,$.TL)(),p=(0,r.useState)(!0),f=(0,a.Z)(p,2),h=f[0],m=f[1],g=(0,r.useState)([]),v=(0,a.Z)(g,2),j=v[0],y=v[1],Z=(0,r.useState)(null),C=(0,a.Z)(Z,2),w=C[0],S=C[1];(0,r.useEffect)((function(){s&&m(!0)}),[s]),(0,r.useEffect)((function(){if(h){var e=0;if(null!==l&&null!==o){var t=o.unix()-l.unix(),i=Math.floor(t/60);e=i<1?15:i}F.Z.invoke("GET","/api/v1/".concat(d,"/info/widgets/").concat(n.id,"/?step=").concat(e,"&").concat(null!==l?"&start=".concat(l.unix()):"").concat(null!==l&&null!==o?"&":"").concat(null!==o?"end=".concat(o.unix()):"")).then((function(e){var t=E(e,n);y(t.data),S(t),m(!1)})).catch((function(e){u((0,J.Ih)(e)),m(!1)}))}}),[h,n,o,l,u,d]);var N=w?w.widgetConfiguration:[],T=0,I=0;if(1===N.length){var A=N[0];j.forEach((function(e,t){e[A.dataKey]>I&&(I=e[A.dataKey],T=t)}))}var k=(0,_.Z)(),L=(0,G.Z)(k.breakpoints.up("md"));return(0,b.jsxs)("div",{className:x?"":t.singleValueContainer,children:[!x&&(0,b.jsxs)("div",{className:t.titleContainer,children:[i," ",(0,b.jsx)(Y,{panelItem:n})]}),h&&(0,b.jsx)("div",{className:t.loadingAlign,children:(0,b.jsx)(K.Z,{})}),!h&&(0,b.jsx)("div",{className:x?t.zoomChartCont:t.contentContainer,children:(0,b.jsx)(R.h,{width:"99%",children:(0,b.jsxs)(W.v,{data:j,layout:"vertical",barCategoryGap:1,children:[(0,b.jsx)(D.K,{type:"number",hide:!0}),(0,b.jsx)(z.B,{dataKey:"name",type:"category",interval:0,tick:(0,b.jsx)(q,{}),tickLine:!1,axisLine:!1,width:150,hide:!L,style:{fontSize:"12px",fontWeight:100}}),N.map((function(e){return(0,b.jsx)(P.$,{dataKey:e.dataKey,fill:e.color,background:e.background,barSize:x?25:12,children:1===N.length?(0,b.jsx)(r.Fragment,{children:j.map((function(t,i){return(0,b.jsx)(M.b,{fill:i===T?e.greatestColor:e.color},"chart-bar-".concat(i.toString()))}))}):null},"bar-".concat(e.dataKey))})),(0,b.jsx)(O.u,{cursor:{fill:"rgba(255, 255, 255, 0.3)"},content:(0,b.jsx)(U,{barChartConfiguration:N})})]})})})]})})),X=i(37762),ee=i(28265),te=i(82839),ie=i(18602),ne=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)({},h.Rp))}))((function(e){var t=e.active,i=e.payload,n=e.label,a=e.linearConfiguration,l=e.yAxisFormatter,r=e.classes;return t?(0,b.jsxs)("div",{className:r.customTooltip,children:[(0,b.jsx)("div",{className:r.timeStampTitle,children:(0,m.Ue)(n,!0)}),i&&i.map((function(e,t){return(0,b.jsxs)("div",{className:r.labelContainer,children:[(0,b.jsx)("div",{className:r.labelColor,style:{backgroundColor:a[t].lineColor}}),(0,b.jsx)("div",{className:r.itemValue,children:(0,b.jsxs)("span",{className:r.valueContainer,children:[a[t].keyLabel,":"," ",l(e.value)]})})]},"lbPl-".concat(t,"-").concat(a[t].keyLabel))}))]}):null})),ae=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)({},h.NP),{},{verticalAlignment:{flexDirection:"column"},chartCont:{position:"relative",height:140,width:"100%"},legendChart:{display:"flex",flexDirection:"column",flex:"0 1 auto",maxHeight:130,margin:0,overflowY:"auto",position:"relative",textAlign:"center",width:"100%",justifyContent:"flex-start",color:"#404143",fontWeight:"bold",fontSize:12},loadingAlign:{width:40,height:40,textAlign:"center",margin:"15px auto"}}))}))((function(e){var t=e.classes,i=e.title,n=e.timeStart,l=e.timeEnd,o=e.propLoading,s=e.panelItem,d=e.apiPrefix,c=e.hideYAxis,x=void 0!==c&&c,u=e.areaWidget,p=void 0!==u&&u,h=e.yAxisFormatter,m=void 0===h?function(e){return e}:h,g=e.xAxisFormatter,v=void 0===g?function(e){return e}:g,j=e.zoomActivated,y=void 0!==j&&j,Z=(0,$.TL)(),C=(0,r.useState)(!0),w=(0,a.Z)(C,2),S=w[0],N=w[1],T=(0,r.useState)([]),I=(0,a.Z)(T,2),A=I[0],k=I[1],L=(0,r.useState)(0),B=(0,a.Z)(L,2),W=B[0],P=B[1],M=(0,r.useState)(null),U=(0,a.Z)(M,2),V=U[0],H=U[1];(0,r.useEffect)((function(){o&&N(!0)}),[o]),(0,r.useEffect)((function(){if(S){var e=0;if(null!==n&&null!==l){var t=l.unix()-n.unix(),i=Math.floor(t/60);e=i<1?15:i}F.Z.invoke("GET","/api/v1/".concat(d,"/info/widgets/").concat(s.id,"/?step=").concat(e,"&").concat(null!==n?"&start=".concat(n.unix()):"").concat(null!==n&&null!==l?"&":"").concat(null!==l?"end=".concat(l.unix()):"")).then((function(e){var t=E(e,s);k(t.data),H(t),N(!1);var i,n=0,a=(0,X.Z)(t.data);try{for(a.s();!(i=a.n()).done;){var l=i.value;for(var r in l)if("name"!==r){var o=parseInt(l[r]);isNaN(o)&&(o=0),n<o&&(n=o)}}}catch(d){a.e(d)}finally{a.f()}P(n)})).catch((function(e){Z((0,J.Ih)(e)),N(!1)}))}}),[S,s,l,n,Z,d]);var q=Math.floor(A.length/5),Q=V?null===V||void 0===V?void 0:V.widgetConfiguration:[],ae=function(e){var t=e.cx,i=e.cy;return e.index%3!==0?null:(0,b.jsx)("circle",{cx:t,cy:i,r:3,strokeWidth:0,fill:"#07264A"})},le=(0,_.Z)(),re=(0,G.Z)(le.breakpoints.up("md"));return(0,b.jsxs)(f.Z,{className:y?"":t.singleValueContainer,children:[!y&&(0,b.jsxs)("div",{className:t.titleContainer,children:[i," ",(0,b.jsx)(Y,{panelItem:s})]}),(0,b.jsxs)(f.Z,{sx:y?{flexDirection:"column"}:{height:"100%",display:"grid",gridTemplateColumns:{md:"1fr 1fr",sm:"1fr"}},style:p?{gridTemplateColumns:"1fr"}:{},children:[S&&(0,b.jsx)(K.Z,{className:t.loadingAlign}),!S&&(0,b.jsxs)(r.Fragment,{children:[(0,b.jsx)("div",{className:y?t.zoomChartCont:t.chartCont,children:(0,b.jsx)(R.h,{width:"99%",children:(0,b.jsxs)(ee.T,{data:A,margin:{top:5,right:20,left:x?20:5,bottom:0},children:[p&&(0,b.jsx)("defs",{children:(0,b.jsxs)("linearGradient",{id:"colorUv",x1:"0",y1:"0",x2:"0",y2:"1",children:[(0,b.jsx)("stop",{offset:"0%",stopColor:"#2781B0",stopOpacity:1}),(0,b.jsx)("stop",{offset:"100%",stopColor:"#ffffff",stopOpacity:0}),(0,b.jsx)("stop",{offset:"95%",stopColor:"#ffffff",stopOpacity:.8})]})}),(0,b.jsx)(te.q,{strokeDasharray:p?"2 2":"5 5",strokeWidth:1,strokeOpacity:1,stroke:"#eee0e0",vertical:!p}),(0,b.jsx)(D.K,{dataKey:"name",tickFormatter:function(e){return v(e)},interval:q,tick:{fontSize:"68%",fontWeight:"normal",color:"#404143"},tickCount:10,stroke:"#082045"}),(0,b.jsx)(z.B,{type:"number",domain:[0,1.1*W],hide:x,tickFormatter:function(e){return m(e)},tick:{fontSize:"68%",fontWeight:"normal",color:"#404143"},stroke:"#082045"}),Q.map((function(e,t){return(0,b.jsx)(ie.u,{type:"monotone",dataKey:e.dataKey,isAnimationActive:!1,stroke:p?"#D7E5F8":e.lineColor,fill:p?"url(#colorUv)":e.fillColor,fillOpacity:p?.65:0,strokeWidth:p?0:3,strokeLinecap:"round",dot:!!p&&(0,b.jsx)(ae,{})},"area-".concat(e.dataKey,"-").concat(t.toString()))})),(0,b.jsx)(O.u,{content:(0,b.jsx)(ne,{linearConfiguration:Q,yAxisFormatter:m}),wrapperStyle:{zIndex:5e3}})]})})}),!p&&(0,b.jsxs)(r.Fragment,{children:[y&&(0,b.jsxs)(r.Fragment,{children:[(0,b.jsx)("strong",{children:"Series"}),(0,b.jsx)("br",{}),(0,b.jsx)("br",{})]}),re&&(0,b.jsx)("div",{className:t.legendChart,children:Q.map((function(e,i){return(0,b.jsxs)("div",{className:t.singleLegendContainer,children:[(0,b.jsx)("div",{className:t.colorContainer,style:{backgroundColor:e.lineColor}}),(0,b.jsx)("div",{className:t.legendLabel,children:e.keyLabel})]},"legend-".concat(e.keyLabel,"-").concat(i.toString()))}))})]})]})]})]})})),le=i(73909),re=i(21041),oe=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)({},h.NP),{},{loadingAlign:{width:"100%",paddingTop:"15px",textAlign:"center",margin:"auto"},pieChartLabel:{fontSize:60,color:"#07193E",fontWeight:"bold",width:"100%","& .unitText":{color:"#767676",fontSize:12}},chartContainer:{width:"100%",height:140}}))}))((function(e){var t=e.classes,i=e.title,n=e.panelItem,l=e.timeStart,o=e.timeEnd,d=e.propLoading,c=e.apiPrefix,x=(0,$.TL)(),u=(0,r.useState)(!0),p=(0,a.Z)(u,2),f=p[0],h=p[1],m=(0,r.useState)([]),g=(0,a.Z)(m,2),v=g[0],j=g[1],y=(0,r.useState)([]),Z=(0,a.Z)(y,2),C=Z[0],w=Z[1],S=(0,r.useState)(null),T=(0,a.Z)(S,2),I=T[0],A=T[1];(0,r.useEffect)((function(){d&&h(!0)}),[d]),(0,r.useEffect)((function(){if(f){var e=0;if(null!==l&&null!==o){var t=o.unix()-l.unix(),i=Math.floor(t/60);e=i<1?15:i}F.Z.invoke("GET","/api/v1/".concat(c,"/info/widgets/").concat(n.id,"/?step=").concat(e,"&").concat(null!==l?"&start=".concat(l.unix()):"").concat(null!==l&&null!==o?"&":"").concat(null!==o?"end=".concat(o.unix()):"")).then((function(e){var t=E(e,n);j(t.data),w(t.dataOuter),A(t),h(!1)})).catch((function(e){x((0,J.Ih)(e)),h(!1)}))}}),[f,n,o,l,x,c]);var k=I?I.widgetConfiguration:[],L=null===I||void 0===I?void 0:I.innerLabel,B=s()(k,"innerChart.colorList",[]),W=s()(k,"outerChart.colorList",[]);return(0,b.jsxs)("div",{className:t.singleValueContainer,children:[(0,b.jsx)("div",{className:t.titleContainer,children:i}),f&&(0,b.jsx)("div",{className:t.loadingAlign,children:(0,b.jsx)(K.Z,{})}),!f&&(0,b.jsxs)("div",{className:t.contentContainer,children:[(0,b.jsx)("span",{className:t.pieChartLabel,children:L&&N(L)}),(0,b.jsx)("div",{className:t.chartContainer,children:(0,b.jsx)(R.h,{width:"99%",children:(0,b.jsxs)(le.u,{margin:{top:5,bottom:5},children:[C&&(0,b.jsx)(re.b,{data:C,cx:"50%",cy:"50%",dataKey:"value",innerRadius:s()(k,"outerChart.innerRadius",0),outerRadius:s()(k,"outerChart.outerRadius","80%"),startAngle:s()(k,"outerChart.startAngle",0),endAngle:s()(k,"outerChart.endAngle",360),fill:"#201763",children:C.map((function(e,t){return(0,b.jsx)(M.b,{fill:"undefined"===typeof W[t]?"#393939":W[t]},"cellOuter-".concat(t))}))}),v&&(0,b.jsx)(re.b,{data:v,dataKey:"value",cx:"50%",cy:"50%",innerRadius:s()(k,"innerChart.innerRadius",0),outerRadius:s()(k,"innerChart.outerRadius","80%"),startAngle:s()(k,"innerChart.startAngle",0),endAngle:s()(k,"innerChart.endAngle",360),fill:"#201763",children:v.map((function(e,t){return(0,b.jsx)(M.b,{fill:"undefined"===typeof B[t]?"#393939":B[t]},"cell-".concat(t))}))})]})})})]})]})})),se=(0,c.$j)(null,{setErrorSnackMessage:J.Ih}),de=(0,p.Z)((function(e){return(0,u.Z)({mainWidgetContainer:{display:"inline-flex",color:"#072A4D",alignItems:"center"},icon:{color:"#072A4D",fill:"#072A4D",marginRight:5,marginLeft:12},widgetLabel:{fontWeight:"bold",textTransform:"uppercase",marginRight:10},widgetValue:{marginRight:25}})}))(se((function(e){var t=e.classes,i=e.iconWidget,n=e.title,l=e.panelItem,o=e.timeStart,s=e.timeEnd,d=e.propLoading,c=e.apiPrefix,x=e.renderFn,u=(0,$.TL)(),p=(0,r.useState)(!0),f=(0,a.Z)(p,2),h=f[0],m=f[1],g=(0,r.useState)(""),v=(0,a.Z)(g,2),j=v[0],y=v[1];return(0,r.useEffect)((function(){d&&m(!0)}),[d]),(0,r.useEffect)((function(){if(h){var e=0;if(null!==o&&null!==s){var t=s.unix()-o.unix(),i=Math.floor(t/60);e=i<1?15:i}F.Z.invoke("GET","/api/v1/".concat(c,"/info/widgets/").concat(l.id,"/?step=").concat(e,"&").concat(null!==o?"&start=".concat(o.unix()):"").concat(null!==o&&null!==s?"&":"").concat(null!==s?"end=".concat(s.unix()):"")).then((function(e){var t=E(e,l);y(t.data),m(!1)})).catch((function(e){u((0,J.Ih)(e)),m(!1)}))}}),[h,l,s,o,u,c]),x?x({valueToRender:j,loading:h,title:n,id:l.id,iconWidget:i}):(0,b.jsxs)(r.Fragment,{children:[h&&(0,b.jsx)("div",{className:t.loadingAlign,children:(0,b.jsx)(K.Z,{})}),!h&&(0,b.jsxs)("span",{className:t.mainWidgetContainer,children:[(0,b.jsx)("span",{className:t.icon,children:i||null}),(0,b.jsxs)("span",{className:t.widgetLabel,children:[n,": "]}),(0,b.jsx)("span",{className:t.widgetValue,children:j})]})]})}))),ce=function(e){var t=e.children;return(0,b.jsx)(f.Z,{sx:{border:"1px solid #f1f1f1",borderRadius:"3px",padding:{md:"15px",xs:"5px"},height:{md:"136px",xs:"auto"},maxWidth:{sm:"100%"}},children:t})},xe=i(20068),ue=function(e){var t=e.value,i=e.label,n=void 0===i?"":i,a=e.icon,l=void 0===a?null:a,r=e.loading,o=void 0!==r&&r;return(0,b.jsx)(f.Z,{sx:{fontFamily:"Lato,sans-serif",color:"#07193E",maxWidth:"300px",display:"flex",marginLeft:"auto",marginRight:"auto",cursor:"default",position:"relative",width:"100%"},children:(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",width:"100%",padding:{sm:"0 8px 0 8px",xs:"0 10px 0 10px"}},children:[(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",flexFlow:"column",marginTop:"12px",zIndex:10,overflow:"hidden"},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"16px",fontWeight:600},children:n}),(0,b.jsx)(xe.Z,{title:t,placement:"bottom",enterDelay:500,children:(0,b.jsx)(f.Z,{sx:{fontSize:{xl:"55px",lg:"50px",md:"36px",sm:"35px",xs:"35px"},fontWeight:600,overflow:"hidden",textOverflow:"ellipsis",maxWidth:{md:187,xs:200},flexFlow:{md:"row",xs:"column"}},children:t})})]}),(0,b.jsx)(f.Z,{sx:{display:"flex",flexFlow:"column",alignItems:"center",justifyContent:"flex-start",marginTop:"8px",maxWidth:"26px","& .min-icon":{width:"16px",height:"16px"}},children:o?(0,b.jsx)(K.Z,{style:{width:"16px",height:"16px"}}):l})]})})},pe=function(e){var t=e.title,i=e.value,n=e.loading;return(0,b.jsx)(ue,{label:t,icon:(0,b.jsx)(j.wNb,{}),value:i,loading:n})},fe=function(e){var t=e.title,i=e.value,n=e.loading;return(0,b.jsx)(ue,{label:t,icon:(0,b.jsx)(j.xpX,{}),value:i,loading:n})},he=(0,c.$j)(null,{setErrorSnackMessage:J.Ih})((function(e){var t=e.title,i=e.panelItem,n=e.timeStart,l=e.timeEnd,o=e.propLoading,s=e.apiPrefix,d=(0,$.TL)(),c=(0,r.useState)(!0),x=(0,a.Z)(c,2),u=x[0],p=x[1],f=(0,r.useState)(null),h=(0,a.Z)(f,2),g=h[0],v=h[1];(0,r.useEffect)((function(){o&&p(!0)}),[o]),(0,r.useEffect)((function(){if(u){var e=0;if(null!==n&&null!==l){var t=l.unix()-n.unix(),a=Math.floor(t/60);e=a<1?15:a}F.Z.invoke("GET","/api/v1/".concat(s,"/info/widgets/").concat(i.id,"/?step=").concat(e,"&").concat(null!==n?"&start=".concat(n.unix()):"").concat(null!==n&&null!==l?"&":"").concat(null!==l?"end=".concat(l.unix()):"")).then((function(e){var t=E(e,i);v(t),p(!1)})).catch((function(e){d((0,J.Ih)(e)),p(!1)}))}}),[u,i,l,n,d,s]);var j="";if(g){var y=parseInt(g.innerLabel||"0");j=isNaN(y)?"0":(0,m.nk)(y)}var Z;return 66===(Z=i.id)?(0,b.jsx)(ce,{children:(0,b.jsx)(pe,{loading:u,title:t,value:g?j:""})}):44===Z?(0,b.jsx)(ce,{children:(0,b.jsx)(fe,{loading:u,title:t,value:g?j:""})}):null})),me=(0,c.$j)(null,{setErrorSnackMessage:J.Ih}),ge=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)({},h.NP),{},{loadingAlign:{width:"100%",textAlign:"center",margin:"auto"},metric:{fontSize:60,lineHeight:1,color:"#07193E",fontWeight:700},titleElement:{fontSize:10,color:"#767676",fontWeight:700},containerAlignment:{display:"flex",height:140,flexDirection:"column",justifyContent:"center","& .unitText":{color:"#767676",fontSize:12}}}))}))(me((function(e){var t=e.title,i=e.panelItem,n=e.timeStart,l=e.timeEnd,o=e.propLoading,s=e.classes,d=e.apiPrefix,c=e.renderFn,x=(0,$.TL)(),u=(0,r.useState)(!0),p=(0,a.Z)(u,2),f=p[0],h=p[1],m=(0,r.useState)(""),g=(0,a.Z)(m,2),v=g[0],j=g[1];(0,r.useEffect)((function(){o&&h(!0)}),[o]),(0,r.useEffect)((function(){if(f){var e=0;if(null!==n&&null!==l){var t=l.unix()-n.unix(),a=Math.floor(t/60);e=a<1?15:a}F.Z.invoke("GET","/api/v1/".concat(d,"/info/widgets/").concat(i.id,"/?step=").concat(e,"&").concat(null!==n?"&start=".concat(n.unix()):"").concat(null!==n&&null!==l?"&":"").concat(null!==l?"end=".concat(l.unix()):"")).then((function(e){var t=E(e,i);j(t.data),h(!1)})).catch((function(e){x((0,J.Ih)(e)),h(!1)}))}}),[f,i,l,n,x,d]);var y=N(v);return c?c({valueToRender:y,loading:f,title:t,id:i.id}):(0,b.jsxs)("div",{className:s.containerAlignment,children:[f&&(0,b.jsx)("div",{className:s.loadingAlign,children:(0,b.jsx)(K.Z,{})}),!f&&(0,b.jsxs)(r.Fragment,{children:[(0,b.jsx)("div",{className:s.metric,children:N(v)}),(0,b.jsx)("div",{className:s.titleElement,children:t})]})]})}))),ve=function(e){var t=e.value,i=e.timeStart,n=e.timeEnd,l=e.propLoading,o=e.apiPrefix,s=(0,$.TL)(),d=(0,r.useState)(!0),c=(0,a.Z)(d,2),x=c[0],u=c[1],p=(0,r.useState)(0),h=(0,a.Z)(p,2),g=h[0],v=h[1],y=(0,r.useState)(0),Z=(0,a.Z)(y,2),C=Z[0],w=Z[1],S=(0,r.useState)(0),N=(0,a.Z)(S,2),T=N[0],I=N[1],A=(0,r.useState)(0),k=(0,a.Z)(A,2),L=k[0],B=k[1];(0,r.useEffect)((function(){l&&u(!0)}),[l]),(0,r.useEffect)((function(){if(x){var e=0;if(null!==i&&null!==n){var a=n.unix()-i.unix(),l=Math.floor(a/60);e=l<1?15:l}F.Z.invoke("GET","/api/v1/".concat(o,"/info/widgets/").concat(t.id,"/?step=").concat(e,"&").concat(null!==i?"&start=".concat(i.unix()):"").concat(null!==i&&null!==n?"&":"").concat(null!==n?"end=".concat(n.unix()):"")).then((function(e){var i=E(e,t),n=0,a=0,l=0;i.data.forEach((function(e){e.forEach((function(e){switch(e.legend){case"Total Usable":n+=e.value;break;case"Used Space":a+=e.value;break;case"Usable Free":l+=e.value}}))}));var r=Math.round(l/n*100);v(l),w(r),I(a),B(n),u(!1)})).catch((function(e){s((0,J.Ih)(e)),u(!1)}))}}),[x,t,n,i,s,o]);var R=(0,m.Am)(T,!0,!1),W=[{value:g,color:"#D6D6D6",label:"Usable Available Space"},{value:T,color:(0,m.hn)(T,L),label:"Used Space"}];return(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",alignItems:"center",flexFlow:{sm:"row",xs:"column"}},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"16px",fontWeight:600,alignSelf:{xs:"flex-start"}},children:"Capacity"}),(0,b.jsxs)(f.Z,{sx:{position:"relative",width:110,height:110,marginLeft:{sm:"auto",xs:""}},children:[(0,b.jsxs)(f.Z,{sx:{position:"absolute",display:"flex",flexFlow:"column",alignItems:"center",top:"50%",left:"50%",transform:"translate(-50%, -50%)",fontWeight:"bold",color:"#000",fontSize:12},children:["".concat(C,"%"),(0,b.jsx)("br",{}),(0,b.jsx)(f.Z,{sx:{color:"#8F9090",fontSize:"10px",display:"flex",flexFlow:"column",alignItems:"center",textAlign:"center"},children:"Free"})]}),(0,b.jsx)(le.u,{width:110,height:110,children:(0,b.jsx)(re.b,{data:W,cx:"50%",cy:"50%",dataKey:"value",outerRadius:50,innerRadius:40,startAngle:-70,endAngle:360,animationDuration:1,children:W.map((function(e,t){return(0,b.jsx)(M.b,{fill:e.color},"cellCapacity-".concat(t))}))})})]}),(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",marginLeft:{sm:"auto",xs:""}},children:[(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{color:"#5E5E5E",fontWeight:"bold",fontSize:"14px"},children:"Used:"}),(0,b.jsxs)(f.Z,{sx:{display:"flex","& .value":{fontSize:"50px",fontFamily:"Lato",fontWeight:600,alignSelf:"flex-end",lineHeight:1},"& .unit":{color:"#5E5E5E",fontWeight:"bold",fontSize:"14px",marginLeft:"12px",alignSelf:"flex-end"}},children:[(0,b.jsx)("div",{className:"value",children:R.total}),(0,b.jsx)("div",{className:"unit",children:R.unit})]}),(0,b.jsx)(f.Z,{sx:{marginTop:"5px","& .value":{color:"#5E5E5E",fontWeight:"bold",fontSize:"14px",textAlign:"right"}},children:(0,b.jsxs)("div",{className:"value",children:["Of: ",(0,m.l5)(L)]})})]}),(0,b.jsx)(f.Z,{sx:{marginLeft:"15px",height:"100%",display:"flex",alignItems:"flex-start"},children:(0,b.jsx)(f.Z,{children:x?(0,b.jsx)(K.Z,{style:{width:"26px",height:"26px"}}):(0,b.jsx)(j.rHZ,{})})})]})]})},je=function(e){var t=e.icon,i=e.label,n=e.value,a=e.loading,l=void 0!==a&&a;return(0,b.jsxs)(f.Z,{sx:{display:"grid",alignItems:"center",gap:"8px",height:"33px",paddingLeft:"15px",gridTemplateColumns:{xs:"20px 1.5fr .5fr 20px"},background:"#EBF9EE","& .min-icon":{height:"12px",width:"12px",fill:"#4CCB92"},"& .ok-icon":{height:"8px",width:"8px",fill:"#4CCB92",color:"#4CCB92"}},className:"dashboard-time-stat-item",children:[l?(0,b.jsx)(K.Z,{style:{width:10,height:10}}):t,(0,b.jsx)(f.Z,{sx:{fontSize:"12px",color:"#4CCB92",fontWeight:600},children:i}),(0,b.jsx)(f.Z,{sx:{fontSize:"12px",color:"#4CCB92"},children:n}),"n/a"!==n?(0,b.jsx)(j.tmp,{className:"ok-icon"}):null]})},be=function(e){var t=e.valueToRender,i=void 0===t?"":t,n=e.loading,a=void 0!==n&&n,l=e.iconWidget,r=void 0===l?null:l;return(0,b.jsx)(f.Z,{sx:{display:"flex",height:"47px",borderRadius:"2px","& .dashboard-time-stat-item":{height:"100%",width:"100%"}},children:(0,b.jsx)(je,{loading:a,icon:r,label:(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{display:{md:"inline",xs:"none"}},children:"Time since last"})," ","Heal Activity"]}),value:i})})},ye=function(e){var t=e.valueToRender,i=void 0===t?"":t,n=e.loading,a=void 0!==n&&n,l=e.iconWidget,r=void 0===l?null:l;return(0,b.jsx)(f.Z,{sx:{display:"flex",height:"47px",borderRadius:"2px","& .dashboard-time-stat-item":{height:"100%",width:"100%"}},children:(0,b.jsx)(je,{loading:a,icon:r,label:(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{display:{md:"inline",xs:"none"}},children:"Time since last"})," ","Scan Activity"]}),value:i})})},Ze=function(e){var t=e.valueToRender,i=void 0===t?"":t,n=e.loading,a=void 0!==n&&n,l=e.iconWidget,r=void 0===l?null:l;return(0,b.jsx)(f.Z,{sx:{display:"flex",height:"47px",borderRadius:"2px","& .dashboard-time-stat-item":{height:"100%",width:"100%"}},children:(0,b.jsx)(je,{loading:a,icon:r,label:(0,b.jsx)(f.Z,{children:"Uptime"}),value:i})})},Ce=function(e,t,i,a,l){var r=arguments.length>5&&void 0!==arguments[5]&&arguments[5];switch(e.type){case n.singleValue:return(0,b.jsx)(ge,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,apiPrefix:l});case n.simpleWidget:var o,s=null;return 80===e.id?s=be:81===e.id?s=ye:1===e.id&&(s=Ze),[80,81,1].includes(e.id)&&(o=function(e){var t=e.valueToRender,i=e.loading,n=e.title,a=e.id,l=e.iconWidget;return(0,b.jsx)(s,{valueToRender:t,loading:i,title:n,id:a,iconWidget:l})}),(0,b.jsx)(de,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,apiPrefix:l,iconWidget:e.widgetIcon,renderFn:o});case n.pieChart:return 50===e.id?(0,b.jsx)(ce,{children:(0,b.jsx)(ve,{value:e,timeStart:t,timeEnd:i,propLoading:a,apiPrefix:l})}):(0,b.jsx)(oe,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,apiPrefix:l});case n.linearGraph:case n.areaGraph:return(0,b.jsx)(ae,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,hideYAxis:e.disableYAxis,xAxisFormatter:e.xAxisFormatter,yAxisFormatter:e.yAxisFormatter,apiPrefix:l,areaWidget:e.type===n.areaGraph,zoomActivated:r});case n.barChart:return(0,b.jsx)(Q,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,apiPrefix:l,zoomActivated:r});case n.singleRep:var d=e.fillColor?e.fillColor:e.color;return(0,b.jsx)(he,{title:e.title,panelItem:e,timeStart:t,timeEnd:i,propLoading:a,color:e.color,fillColor:d,apiPrefix:l});default:return null}},we=i(56028),Se=function(e){var t=e.value,i=e.modalOpen,n=e.timeStart,a=e.timeEnd,l=e.apiPrefix,o=(0,$.TL)();return t?(0,b.jsx)(we.Z,{title:t.title,onClose:function(){o((0,H.jv)())},modalOpen:i,wideLimit:!1,noContentPadding:!0,children:(0,b.jsx)(r.Fragment,{children:Ce(t,n,a,!0,l,!0)})}):null},Ee=i(63856),Ne=[{sx:{minWidth:0,display:"grid",gridTemplateColumns:{md:"1fr 1fr 1fr 1fr",sm:"1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:66},{componentId:44},{componentId:500},{componentId:501}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:{md:"1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:50},{componentId:502}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:{md:"1fr 1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:80},{componentId:81},{componentId:1}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:{sm:"1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:68},{componentId:52}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:{sm:"1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:63},{componentId:70}]}],Te=[{sx:{display:"grid",gridTemplateColumns:"1fr",gap:"30px"},columns:[{componentId:60}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:{sm:"1fr 1fr",xs:"1fr"},gap:"30px"},columns:[{componentId:71,sx:{flex:1,width:"50%",flexShrink:0}},{componentId:17,sx:{flex:1,width:"50%",flexShrink:0}}]},{sx:{display:"grid",gridTemplateColumns:"1fr",gap:"30px"},columns:[{componentId:73}]}],Fe=[{sx:{display:"grid",minWidth:0,gridTemplateColumns:"1fr 1fr",gap:"30px"},columns:[{componentId:76},{componentId:77}]},{sx:{display:"grid",minWidth:0,gridTemplateColumns:"1fr 1fr",gap:"30px"},columns:[{componentId:82},{componentId:74}]}],Ie=[{sx:{display:"grid",minWidth:0,gridTemplateColumns:"1fr 1fr",gap:"30px"},columns:[{componentId:11},{componentId:8}]}],Ae=function(e){var t=e.children;return(0,b.jsx)(f.Z,{sx:{display:"grid",gridTemplateColumns:"1fr",gap:"30px"},children:t})},ke=i(57621),Le=i(9585),Be=i(43504),Re=(0,I.Z)({root:{backgroundColor:"#fff",padding:0},title:(0,l.Z)({},h.NP.titleContainer),content:{maxWidth:"100%"}}),We=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)({},h.NP),{},{cardRoot:(0,l.Z)((0,l.Z)({},h.NP.singleValueContainer),{},{"&.MuiPaper-root":{borderRadius:10}}),metricText:{fontSize:70,lineHeight:1.1,color:"#07193E",fontWeight:"bold"},unitText:{fontSize:10,color:"#767676",fontWeight:"normal"},subHearderContainer:{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center"},subMessage:{fontSize:10,color:"#767676","&.bold":{fontWeight:"bold"}},headerContainer:{display:"flex",justifyContent:"space-between"},viewAll:{fontSize:10,color:"#C83B51",textTransform:"capitalize","& a, & a:hover, & a:visited, & a:active":{color:"#C83B51"}},extraMargin:{margin:"10px 20px 10px 0"}}))}))((function(e){var t=e.title,i=e.metricValue,n=e.metricUnit,a=e.subMessage,l=e.moreLink,o=e.rightComponent,s=e.extraMargin,d=void 0!==s&&s,c=e.classes,x=Re(),u=function(){return(0,b.jsx)(r.Fragment,{children:(0,b.jsxs)("div",{className:c.subHearderContainer,children:[(0,b.jsxs)("div",{className:c.leftSide,children:[(0,b.jsx)("div",{children:(0,b.jsxs)("span",{className:c.metricText,children:[i,(0,b.jsx)("span",{className:c.unitText,children:n})]})}),a&&(0,b.jsx)("div",{className:"".concat(c.subMessage," ").concat(a.fontWeight?a.fontWeight:""),children:a.message})]}),(0,b.jsx)("div",{className:c.rightSide,children:o})]})})},p=function(){return(0,b.jsx)(r.Fragment,{children:(0,b.jsxs)("div",{className:c.headerContainer,children:[(0,b.jsx)("span",{className:c.title,children:t}),l&&(0,b.jsx)(r.Fragment,{children:(0,b.jsx)("span",{className:c.viewAll,children:(0,b.jsx)(Be.rU,{to:l,children:"View All"})})})]})})};return(0,b.jsx)(r.Fragment,{children:(0,b.jsx)(ke.Z,{className:"".concat(c.cardRoot," ").concat(d?c.extraMargin:""),children:""!==i&&(0,b.jsx)(Le.Z,{title:(0,b.jsx)(p,{}),subheader:(0,b.jsx)(r.Fragment,{children:(0,b.jsx)(u,{})}),classes:{root:x.root,title:x.title,content:x.content}})})})})),De=function(e){var t=e.title,i=e.leftComponent,n=e.rightComponent;return(0,b.jsx)(r.Fragment,{children:(0,b.jsx)(We,{title:t,metricValue:i,rightComponent:n})})},ze=function(e){var t=e.panelItem,i=e.timeStart,n=e.timeEnd,l=e.propLoading,o=e.apiPrefix,s=e.statLabel,d=(0,$.TL)(),c=(0,r.useState)(!0),x=(0,a.Z)(c,2),u=x[0],p=x[1],h=(0,r.useState)(""),m=(0,a.Z)(h,2),g=m[0],v=m[1];return(0,r.useEffect)((function(){l&&p(!0)}),[l]),(0,r.useEffect)((function(){if(u){var e=0;if(null!==i&&null!==n){var a=n.unix()-i.unix(),l=Math.floor(a/60);e=l<1?15:l}F.Z.invoke("GET","/api/v1/".concat(o,"/info/widgets/").concat(t.id,"/?step=").concat(e,"&").concat(null!==i?"&start=".concat(i.unix()):"").concat(null!==i&&null!==n?"&":"").concat(null!==n?"end=".concat(n.unix()):"")).then((function(e){var i=E(e,t);v(i.data),p(!1)})).catch((function(e){d((0,J.Ih)(e)),p(!1)}))}}),[u,t,n,i,d,o]),u?(0,b.jsx)(f.Z,{sx:{width:"100%",paddingTop:"5px",textAlign:"center",margin:"auto"},children:(0,b.jsx)(K.Z,{style:{width:12,height:12}})}):(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{className:"stat-value",children:g}),s]})},Pe=function(e){var t=e.statItemLeft,i=void 0===t?null:t,n=e.statItemRight,a=void 0===n?null:n,l=e.icon,r=void 0===l?null:l,o=e.label,s=void 0===o?"":o;return(0,b.jsx)(f.Z,{sx:{fontFamily:"Lato,sans-serif",color:"#07193E",maxWidth:"321px",display:"flex",marginLeft:"auto",marginRight:"auto",cursor:"default"},children:(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",padding:{sm:"0 8px 0 8px",xs:"0 10px 0 10px"}},children:[(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",flexFlow:"column"},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"16px",fontWeight:600},children:s}),(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",gap:"5px",justifyContent:"space-between",paddingBottom:{md:"0px",xs:"10px"},fontSize:{xl:"55px",lg:"50px",md:"45px",xs:"35px"},flexFlow:"row",fontWeight:600,"& .stat-text":{color:"#696969",fontSize:"12px",marginTop:"8px"},"& .stat-value":{textAlign:"center",height:"50px"},"& .min-icon":{marginRight:"8px",marginTop:"8px",height:"10px",width:"10px"}},children:[i,a]})]}),(0,b.jsx)(f.Z,{sx:{width:"20px",height:"20px",marginTop:"8px",maxWidth:"26px","& .min-icon":{width:"16px",height:"16px"}},children:r})]})})},Me=function(e){var t=e.info,i=e.timeStart,n=e.timeEnd,l=e.loading,r=e.apiPrefix,o=t.mergedPanels,s=void 0===o?[]:o,d=t.id,c=(0,a.Z)(s,2),x=c[0],u=c[1],p=(0,b.jsx)(ze,{panelItem:x,timeStart:i,timeEnd:n,propLoading:l,apiPrefix:r,statLabel:(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",marginTop:"5px","& .min-icon":{fill:"#4CCB92"}},children:[(0,b.jsx)(j.J$M,{}),(0,b.jsx)("div",{className:"stat-text",children:"Online"})]})}),h=(0,b.jsx)(ze,{panelItem:u,timeStart:i,timeEnd:n,propLoading:l,apiPrefix:r,statLabel:(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",marginTop:"5px","& .min-icon":{fill:"#C83B51"}},children:[(0,b.jsx)(j.J$M,{}),(0,b.jsx)("div",{className:"stat-text",children:"Offline"})]})}),m=null,g="";return 500===d?(m=(0,b.jsx)(j.SBZ,{}),g="Servers"):501===d&&(m=(0,b.jsx)(j.FU8,{}),g="Drives"),(0,b.jsx)(Pe,{statItemLeft:p,statItemRight:h,icon:m,label:g})},Oe=function(e){var t=e.value,i=e.loading;return(0,b.jsxs)(f.Z,{children:[(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",marginTop:"10px",gap:"10px","& .min-icon":{height:"15px",width:"15px",fill:"#4ccb92"}},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"18px",color:"#696969"},children:"GET"}),i?(0,b.jsx)(K.Z,{style:{width:"15px",height:"15px"}}):(0,b.jsx)(j.vUj,{})]}),(0,b.jsx)(f.Z,{sx:{fontSize:"50px",fontFamily:"Lato",fontWeight:600},children:t})]})},Ge=function(e){var t=e.value,i=e.loading;return(0,b.jsxs)(f.Z,{children:[(0,b.jsxs)(f.Z,{sx:{display:"flex",gap:"10px",alignItems:"center",marginTop:"10px","& .min-icon":{height:"15px",width:"15px",fill:"#2781b0"}},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"18px",color:"#696969",fontWeight:"normal"},children:"PUT"}),i?(0,b.jsx)(K.Z,{style:{width:"15px",height:"15px"}}):(0,b.jsx)(j.Uxq,{})]}),(0,b.jsx)(f.Z,{sx:{fontSize:"50px",fontFamily:"Lato",fontWeight:600},children:t})]})},Ue=function(e){var t=e.value,i=e.timeStart,n=e.timeEnd,l=e.propLoading,r=e.apiPrefix,o=t.mergedPanels,s=void 0===o?[]:o,d=(0,a.Z)(s,2),c=d[0],x=d[1],u=(0,b.jsx)(ge,{title:t.title,panelItem:c,timeStart:i,timeEnd:n,propLoading:l,apiPrefix:r,renderFn:function(e){var t=e.valueToRender,i=e.loading,n=e.title,a=e.id;return(0,b.jsx)(Ge,{value:t,loading:i,title:n,id:a})}}),p=(0,b.jsx)(ge,{title:t.title,panelItem:x,timeStart:i,timeEnd:n,propLoading:l,apiPrefix:r,renderFn:function(e){var t=e.valueToRender,i=e.loading,n=e.title,a=e.id;return(0,b.jsx)(Oe,{value:t,loading:i,title:n,id:a})}});return(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",alignItems:"center",flexFlow:{sm:"row",xs:"column"},gap:"15px","& .unitText":{fontSize:"14px",color:"#5E5E5E",marginLeft:"5px"}},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"16px",fontWeight:600},children:"Network"}),(0,b.jsx)(f.Z,{sx:{position:"relative",width:110,height:110,marginLeft:{sm:"auto",xs:""}},children:(0,b.jsx)(f.Z,{sx:{position:"absolute",display:"flex",flexFlow:"column",alignItems:"center",top:"50%",left:"50%",transform:"translate(-50%, -50%)",fontWeight:"bold",color:"#000",fontSize:12},children:p})}),(0,b.jsx)(f.Z,{sx:{display:"flex",alignItems:"center",marginLeft:{sm:"auto",xs:""}},children:(0,b.jsx)(f.Z,{sx:{display:"flex",alignItems:"center","& .value":{fontSize:"50px",fontFamily:"Lato"},"& .unit":{color:"#5E5E5E",fontSize:"18px",marginLeft:"12px",marginTop:"10px"}},children:u})}),(0,b.jsx)(f.Z,{sx:{marginLeft:"15px",height:"100%",display:"flex",alignItems:"flex-start","& .min-icon":{height:"15px",width:"15px"}},children:(0,b.jsx)(j.QBB,{})})]})},_e=function(e){var t=e.info,i=e.timeStart,n=e.timeEnd,l=e.loading,r=e.apiPrefix,o=t.mergedPanels,s=void 0===o?[]:o,d=t.title,c=void 0===d?"":d,x=t.id,u=(0,a.Z)(s,2),p=u[0],f=u[1];return[500,501].includes(x)?(0,b.jsx)(ce,{children:(0,b.jsx)(Me,{info:t,timeStart:i,timeEnd:n,loading:l,apiPrefix:r})}):502===x?(0,b.jsx)(ce,{children:(0,b.jsx)(Ue,{apiPrefix:r,timeEnd:n,timeStart:i,value:t,propLoading:l})}):(0,b.jsx)(De,{title:c,leftComponent:Ce(p,i,n,l,r),rightComponent:Ce(f,i,n,l,r)})},Ke=i(74794),Ve=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)((0,l.Z)((0,l.Z)({},h.OR),h.bN),{},{dashboardRow:{display:"flex",flexDirection:"row",justifyContent:"flex-start",flexWrap:"wrap"}}))}))((function(e){var t=e.apiPrefix,i=void 0===t?"admin":t,n=(0,$.TL)(),l=(0,c.v9)((function(e){return e.dashboard.zoom.openZoom})),o=(0,c.v9)((function(e){return e.dashboard.zoom.widgetRender})),s=(0,r.useState)(null),u=(0,a.Z)(s,2),p=u[0],h=u[1],m=(0,r.useState)(null),g=(0,a.Z)(m,2),v=g[0],j=g[1],y=(0,r.useState)(!0),Z=(0,a.Z)(y,2),C=Z[0],S=Z[1],N=(0,r.useState)(w),I=(0,a.Z)(N,2),A=I[0],k=I[1],L=(0,r.useState)(0),R=(0,a.Z)(L,2),W=R[0],D=R[1],z=(0,r.useCallback)((function(){var e=0;if(null!==p&&null!==v){var t=v.unix()-p.unix(),a=Math.floor(t/60);e=a<1?15:a}F.Z.invoke("GET","/api/v1/".concat(i,"/info?step=").concat(e,"&").concat(null!==p?"&start=".concat(p.unix()):"").concat(null!==p&&null!==v?"&":"").concat(null!==v?"end=".concat(v.unix()):"")).then((function(e){if(e.widgets){var t=(i=e.widgets,w.map((function(e){var t=i.find((function(t){return t.title.toLowerCase().trim()===e.title.toLowerCase().trim()}));return E(t,e)})));k(t)}else n((0,J.Ih)({errorMessage:"Widget information could not be retrieved at this time. Please try again",detailedError:""}));var i;S(!1)})).catch((function(e){n((0,J.Ih)(e)),S(!1)}))}),[p,v,n,i]);(0,r.useEffect)((function(){C&&z()}),[C,z]);var P=function(e){return e.reduce((function(e,t,n){var a=t.columns,l=(void 0===a?[]:a).map((function(e,t){var a;return function(e,t){return(0,b.jsx)(r.Fragment,{children:e?(0,b.jsx)(r.Fragment,{children:e.mergedPanels?(0,b.jsx)(_e,{info:e,timeStart:p,timeEnd:v,loading:C,apiPrefix:i}):Ce(e,p,v,C,i)}):null},"widget-".concat(t))}((a=e.componentId,A.find((function(e){return e.id===a}))),"".concat(n,"-").concat(t))})),o=(0,b.jsx)(f.Z,{sx:t.sx,children:l},"layout-row-".concat(n));return[].concat((0,d.Z)(e),[o])}),[])};return(0,b.jsxs)(Ke.Z,{children:[l&&(0,b.jsx)(Se,{modalOpen:l,timeStart:p,timeEnd:v,widgetRender:0,value:o,apiPrefix:i}),(0,b.jsx)(x.ZP,{item:!0,xs:12,children:(0,b.jsx)(B,{selectedTab:W,onChange:function(e){D(e)},tabOptions:[{label:"Usage"},{label:"Traffic"},{label:"Resources"}]})}),(0,b.jsxs)(x.ZP,{item:!0,xs:12,sx:{paddingTop:"20px"},children:[(0,b.jsx)(f.Z,{sx:{marginBottom:"20px"},children:(0,b.jsx)(Ee.Z,{timeStart:p,setTimeStart:h,timeEnd:v,setTimeEnd:j,triggerSync:function(){S(!0)}})}),(0,b.jsx)(T.x,{index:0,value:W,children:(0,b.jsx)(Ae,{children:A.length?P(Ne):null})}),(0,b.jsx)(T.x,{index:1,value:W,children:(0,b.jsx)(Ae,{children:A.length?P(Te):null})}),(0,b.jsx)(T.x,{index:2,value:W,children:(0,b.jsxs)(Ae,{children:[A.length?P(Fe):null,(0,b.jsx)("h2",{style:{margin:0,borderBottom:"1px solid #dedede"},children:"Advanced"}),A.length?P(Ie):null]})})]})]})})),He=i(32291),$e=i(40986),Ye=i(23804),Je=i(31300),qe=i(98444),Qe=i.n(qe),Xe=i(79834),et=i(90493),tt=i(76278),it=i(56125),nt=i(879),at=function(e){var t=e.label,i=void 0===t?"":t,n=e.value,a=void 0===n?"":n,l=e.statusColor,r=void 0===l?"":l,o=e.hasStatus,s=void 0!==o&&o;return(0,b.jsx)(f.Z,{sx:{alignItems:"baseline",padding:"5px",display:"flex",gap:"5px"},children:(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"center",flexFlow:"column","& .stat-text":{color:"#5E5E5E",fontSize:"12px"},"& .stat-value":{fontSize:"18px",color:"#07193E",display:"flex",fontWeight:500,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},children:[(0,b.jsxs)("div",{className:"stat-value",children:[a," ",(0,b.jsx)(f.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"center",flexFlow:"column",marginLeft:"5px",maxWidth:"40px","&:first-of-type(svg)":{fill:"#848484"}},children:s?(0,b.jsx)(f.Z,{sx:{marginRight:"0px",justifyContent:"center",alignItems:"center",textAlign:"center","& svg.min-icon":{fill:r,width:"10px",height:"10px"}},children:(0,b.jsx)(j.J$M,{})}):(0,b.jsx)(f.Z,{sx:{width:"12px",height:"12px"}})})]}),(0,b.jsx)("div",{className:"stat-text",children:i})]})})},lt=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)({},h.SJ))}))((function(e){var t=e.server,i=Object.keys(s()(t,"network",{})),n=i.length,a=t.drives?t.drives.length:0,l=i.reduce((function(e,i){return"online"===t.network[i]?e+1:e}),0),r=t.drives?t.drives.filter((function(e){return"ok"===e.state})).length:0;return(0,b.jsx)(f.Z,{sx:{display:"flex",alignItems:"flex-start",flexFlow:"column",flex:1},children:(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",padding:"3px",gap:"15px",justifyContent:"space-between",width:"100%",paddingLeft:"20px",flexFlow:{sm:"row",xs:"column"}},children:[(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,b.jsx)(f.Z,{sx:{fontWeight:600,textTransform:"none"},children:t.endpoint||""}),(null===t||void 0===t?void 0:t.state)&&(0,b.jsx)(f.Z,{sx:{marginLeft:"8px","& .min-icon":{fill:(0,nt.GJ)(t.state),height:"14px",width:"14px"}},children:(0,b.jsx)(j.J$M,{})})]}),(0,b.jsxs)(f.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"center",flex:"1.5",gap:{md:"5%",xs:"5%"}},children:[(0,b.jsx)(at,{statusColor:(0,nt.Et)(r,a),label:"Drives",hasStatus:!0,value:"".concat(r,"/").concat(a)}),(0,b.jsx)(at,{statusColor:(0,nt.D_)(l,n),label:"Network",hasStatus:!0,value:"".concat(l,"/").concat(n)}),(0,b.jsx)(at,{statusColor:"green",label:"Up time",value:null!==t&&void 0!==t&&t.uptime?(0,m.v1)(t.uptime):"N/A"})]}),(0,b.jsx)(at,{statusColor:"green",label:"",value:(0,b.jsxs)(f.Z,{sx:{background:"rgb(235, 236, 237)",color:"#000000",paddingLeft:"10px",paddingRight:"10px",borderRadius:"2px",fontSize:"12px",marginTop:"5px","& .label":{fontWeight:600,marginRight:"3px"}},children:[(0,b.jsx)("span",{className:"label",children:"Version:"}),t.version?t.version:"N/A"]})})]})})})),rt=function(e){switch(e){case"offline":return nt.yh.RED;case"ok":return nt.yh.GREEN;default:return nt.yh.YELLOW}},ot=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)({},h.SJ))}))((function(e){var t=e.drive,i=[{value:t.totalSpace-t.usedSpace,color:"#D6D6D6",label:"Free Space"},{value:t.usedSpace,color:(0,m.hn)(t.usedSpace,t.totalSpace),label:"Used Space"}];return(0,b.jsx)(f.Z,{sx:{display:"flex",flex:1,alignItems:"center",paddingBottom:"10px",padding:"20px",border:"1px solid #eaeaea"},children:(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column",marginLeft:"10px",flex:1},children:[(0,b.jsxs)(f.Z,{sx:{fontSize:"14px",fontWeight:400,display:"flex",alignItems:"center","& .min-icon":{marginRight:"10px",height:"10px",width:"10px",fill:rt(t.state),flexShrink:0},"& .drive-endpoint":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"normal",wordBreak:"break-all",marginRight:"8px",fontWeight:600,fontSize:{md:"16px",xs:"10px"}}},children:[(0,b.jsx)("div",{className:"drive-endpoint",children:t.endpoint||""}),t.state&&(0,b.jsx)(j.J$M,{})]}),(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",alignItems:"center",paddingLeft:"20px",marginTop:"10px",flexFlow:{sm:"row",xs:"column"},"& .info-label":{color:"#5E5E5E",fontSize:"12px",textAlign:"center"},"& .info-value":{fontSize:"18px",color:"#07193E",display:"flex",fontWeight:500,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},children:[(0,b.jsx)(f.Z,{sx:{flex:1},children:(0,b.jsxs)("div",{style:{position:"relative",width:110,height:110},children:[(0,b.jsx)("span",{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",fontWeight:"bold",color:"#000",fontSize:12},children:(0,m.l5)(t.usedSpace)}),(0,b.jsx)("div",{children:(0,b.jsx)(le.u,{width:110,height:110,children:(0,b.jsx)(re.b,{data:i,cx:"50%",cy:"50%",dataKey:"value",outerRadius:50,innerRadius:40,startAngle:-70,endAngle:360,animationDuration:1,children:i.map((function(e,t){return(0,b.jsx)(M.b,{fill:e.color},"cellCapacity-".concat(t))}))})})})]})}),(0,b.jsxs)(f.Z,{sx:{display:"flex",gap:"5%",alignItems:"center",flex:2,flexGrow:1},children:[(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column"},children:[(0,b.jsx)("div",{className:"info-value",children:(0,m.ae)(t.totalSpace?t.totalSpace.toString():"0")}),(0,b.jsx)("label",{className:"info-label",children:"Capacity"})]}),(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column"},children:[(0,b.jsx)("div",{className:"info-value",children:(0,m.ae)(t.usedSpace?t.usedSpace.toString():"0")}),(0,b.jsx)("label",{className:"info-label",children:"Used"})]}),(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column"},children:[(0,b.jsx)("div",{className:"info-value",children:(0,m.ae)(t.availableSpace?t.availableSpace.toString():"0")}),(0,b.jsx)("label",{className:"info-label",children:"Available"})]})]})]})]})})})),st=i(25183),dt=function(e){var t=e.data,i=r.useState(t.length>1?"":t[0].endpoint+"-0"),n=(0,a.Z)(i,2),l=n[0],o=n[1],s=function(e){o(e)};return(0,b.jsxs)(f.Z,{children:[(0,b.jsxs)(f.Z,{sx:{marginBottom:"10px"},children:["Servers (",t.length,")"]}),(0,b.jsx)(et.Z,{sx:{width:"100%",flex:1,padding:"0"},component:"nav","aria-labelledby":"nested-list-subheader",children:t.map((function(e,t){var i="".concat(e.endpoint,"-").concat(t),n=l===i;return(0,b.jsxs)(r.Fragment,{children:[(0,b.jsxs)(tt.Z,{disableRipple:!0,onClick:function(){s(n?"":i)},className:n?"expanded":"",sx:{display:"flex",alignItems:"center",justifyContent:"space-between",border:"1px solid #f1f1f1",padding:"3px 10px 3px 10px","&:hover":{background:"#bebbbb0d"}},children:[(0,b.jsx)(lt,{server:e,index:t}),(0,b.jsx)(f.Z,{sx:{height:"25px",width:"25px",background:"#FBFAFA",borderRadius:"2px","&:hover":{background:"#fafafa"},display:{md:"block",xs:"none"},"& .collapse-icon":{fill:"#494949","& g rect":{fill:"#ffffff"}},"& .expand-icon":{fill:"#494949","& rect":{fill:"#ffffff"}}},children:n?(0,b.jsx)(st.cg,{className:"collapse-icon"}):(0,b.jsx)(st.Ud,{className:"expand-icon"})})]}),n?(0,b.jsxs)(f.Z,{sx:{border:"1px solid #f1f1f1",borderTop:"0"},children:[(0,b.jsxs)(Xe.Z,{component:"div",sx:{paddingLeft:"30px"},children:["Drives (",e.drives.length,")"]},"".concat(t,"-drive-details")),(0,b.jsx)(it.Z,{in:n,timeout:"auto",unmountOnExit:!0,sx:{width:"100%",flex:1,display:"flex",padding:{md:"15px 30px",xs:"10px 10px"},"& .MuiCollapse-wrapperInner":{display:"flex",flexFlow:"column",gap:"15px"}},children:e.drives.map((function(e,t){return(0,b.jsx)(ot,{drive:e},"".concat(e.endpoint,"-").concat(t))}))})]},"".concat(e.endpoint,"-").concat(t)):null]},i)}))})]})},ct=function(e){var t=e.counterValue,i=e.label,n=void 0===i?"":i,a=e.icon,l=void 0===a?null:a,r=e.actions,o=void 0===r?null:r;e.loading;return(0,b.jsx)(f.Z,{sx:{fontFamily:"Lato,sans-serif",color:"#07193E",maxWidth:"300px",display:"flex",marginLeft:"auto",marginRight:"auto",cursor:"default",position:"relative",width:"100%"},children:(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",width:"100%",padding:{sm:"0 8px 0 8px",xs:"0 10px 0 10px"},position:"absolute"},children:[(0,b.jsxs)(f.Z,{sx:{flex:1,display:"flex",flexFlow:"column",marginTop:"8px",zIndex:10,overflow:"hidden"},children:[(0,b.jsx)(f.Z,{sx:{fontSize:"16px",fontWeight:600},children:n}),(0,b.jsx)(xe.Z,{title:t,placement:"bottom",enterDelay:500,children:(0,b.jsx)(f.Z,{sx:{fontSize:{xl:"55px",lg:"50px",md:"36px",sm:"35px",xs:"35px"},fontWeight:600,overflow:"hidden",textOverflow:"ellipsis",maxWidth:{md:187,xs:200},flexFlow:{md:"row",xs:"column"}},children:t})})]}),(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column",alignItems:"center",justifyContent:"flex-start",marginTop:"8px",maxWidth:"26px","& .min-icon":{width:"16px",height:"16px"}},children:[l,(0,b.jsx)(f.Z,{children:o})]})]})})},xt=function(e){var t=e.usageValue,i=e.total,n=e.unit,a=[{value:i,color:"#D6D6D6",label:"Free Space"},{value:t,color:"#073052",label:"Used Space"}];return(0,b.jsxs)(f.Z,{sx:{maxHeight:"110px",display:"flex",alignItems:"center",justifyContent:"space-between",fontSize:"19px",padding:"10px","& .unit-value":{fontSize:"50px",color:"#07193E"},"& .unit-type":{fontSize:"18px",color:"#5E5E5E",marginTop:"20px",marginLeft:"5px"},"& .usage-label":{display:"flex",alignItems:"center",fontSize:"16px",fontWeight:600,marginRight:"20px",marginTop:"-10px","& .min-icon":{marginLeft:"10px",height:16,width:16}}},children:[(0,b.jsxs)(f.Z,{children:[(0,b.jsx)("div",{className:"usage-label",children:(0,b.jsx)("span",{children:"Reported Usage"})}),(0,b.jsx)(xe.Z,{title:"".concat(t," Bytes"),children:(0,b.jsx)("label",{className:"unit-value",style:{fontWeight:600},children:i})}),(0,b.jsx)("label",{className:"unit-type",children:n})]}),(0,b.jsx)(f.Z,{children:(0,b.jsx)(f.Z,{sx:{flex:1},children:(0,b.jsx)("div",{style:{position:"relative",width:105,height:105,top:"-8px"},children:(0,b.jsx)("div",{children:(0,b.jsx)(le.u,{width:105,height:105,children:(0,b.jsx)(re.b,{data:a,cx:"50%",cy:"50%",dataKey:"value",outerRadius:45,innerRadius:35,startAngle:-70,endAngle:360,animationDuration:1,children:a.map((function(e,t){return(0,b.jsx)(M.b,{fill:e.color},"cellCapacity-".concat(t))}))})})})})})})]})},ut=i(40603),pt=i(56087),ft=function(e){var t=e.children;return(0,b.jsx)(f.Z,{sx:{border:"1px solid #f1f1f1",padding:{md:"15px",xs:"5px"},height:"136px",maxWidth:{sm:"100%"}},children:t})},ht=function(e){var t=e.usage,i=t&&t.usage?t.usage.toString():"0",n=function(e){return void 0===e?{total:"0",unit:"Mi"}:(0,m.Am)(e)}(i),a=t||{},l=a.lastScan,o=void 0===l?"n/a":l,s=a.lastHeal,c=void 0===s?"n/a":s,x=a.upTime,u=void 0===x?"n/a":x,p=function(e){return null!==e?e.servers.sort((function(e,t){var i=e.endpoint.toLowerCase(),n=t.endpoint.toLowerCase();return i<n?-1:i>n?1:0})):[]}(t||null),h=[];p.forEach((function(e){var t=e.drives.map((function(e){return e}));h=[].concat((0,d.Z)(h),(0,d.Z)(t))}));var g=Qe()(p,"state"),v=g.offline,y=void 0===v?[]:v,Z=g.online,C=void 0===Z?[]:Z,w=Qe()(h,"state"),S=w.offline,E=void 0===S?[]:S,N=w.ok,T=void 0===N?[]:N;return(0,b.jsx)(f.Z,{sx:{maxWidth:"1536px",margin:"auto"},children:(0,b.jsxs)(f.Z,{sx:{display:"grid",gridTemplateRows:"1fr",gridTemplateColumns:"1fr",gap:"27px",marginBottom:"40px",marginTop:"40px",marginLeft:"40px",marginRight:"40px"},children:[(0,b.jsxs)(f.Z,{children:[(null===t||void 0===t?void 0:t.prometheusNotReady)&&(0,b.jsx)(Ye.Z,{iconComponent:(0,b.jsx)(j.a$2,{}),title:"We can't retrieve advanced metrics at this time",help:(0,b.jsxs)(r.Fragment,{children:["MinIO Dashboard will display basic metrics as we couldn't connect to Prometheus successfully.",(0,b.jsx)("br",{})," ",(0,b.jsx)("br",{}),"Please try again in a few minutes. If the problem persists, you can review your configuration and confirm that Prometheus server is up and running."]})}),!(null!==t&&void 0!==t&&t.prometheusNotReady)&&(0,b.jsx)(Ye.Z,{iconComponent:(0,b.jsx)(j.a$2,{}),title:"We can\u2019t retrieve advanced metrics at this time.",help:(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{fontSize:"14px"},children:"MinIO Dashboard will display basic metrics as we couldn\u2019t connect to Prometheus successfully. Please try again in a few minutes. If the problem persists, you can review your configuration and confirm that Prometheus server is up and running."}),(0,b.jsx)(f.Z,{sx:{paddingTop:"20px",fontSize:"14px","& a":{color:function(e){return e.colors.link}}},children:(0,b.jsx)("a",{href:"https://docs.min.io/minio/baremetal/monitoring/metrics-alerts/collect-minio-metrics-using-prometheus.html?ref=con#minio-metrics-collect-using-prometheus",target:"_blank",rel:"noreferrer",children:"Read more about Prometheus on our Docs site."})})]})})]}),(0,b.jsxs)(f.Z,{sx:{display:"grid",gridTemplateColumns:"1fr",gap:"40px"},children:[(0,b.jsxs)(f.Z,{sx:{display:"grid",gridTemplateRows:"136px",gridTemplateColumns:{sm:"1fr 1fr 1fr",xs:"1fr"},gap:{md:"20px",xs:"20px"}},children:[(0,b.jsx)(ft,{children:(0,b.jsx)(ct,{label:"Buckets",icon:(0,b.jsx)(j.wNb,{}),counterValue:t?(0,m.nk)(t.buckets):0,actions:(0,b.jsx)(Be.rU,{to:pt.gA.BUCKETS,style:{textDecoration:"none",top:"40px",position:"relative",marginRight:"75px"},children:(0,b.jsx)(ut.Z,{tooltip:"Browse",onClick:function(){},text:"Browse",icon:(0,b.jsx)(j.LZ3,{}),color:"primary",variant:"outlined"})})})}),(0,b.jsx)(ft,{children:(0,b.jsx)(ct,{label:"Objects",icon:(0,b.jsx)(j.xpX,{}),counterValue:t?(0,m.nk)(t.objects):0})}),(0,b.jsx)(ft,{children:(0,b.jsx)(Je.Z,{onlineCount:C.length,offlineCount:y.length,label:"Servers",icon:(0,b.jsx)(j.SBZ,{})})}),(0,b.jsx)(ft,{children:(0,b.jsx)(Je.Z,{offlineCount:E.length,onlineCount:T.length,label:"Drives",icon:(0,b.jsx)(j.FU8,{})})}),(0,b.jsxs)(f.Z,{sx:{gridRowStart:"1",gridRowEnd:"3",gridColumnStart:"3",border:"1px solid #f1f1f1",padding:"15px",display:"grid",justifyContent:"stretch"},children:[(0,b.jsx)(xt,{usageValue:i,total:n.total,unit:n.unit}),(0,b.jsxs)(f.Z,{sx:{display:"flex",flexFlow:"column",gap:"14px"},children:[(0,b.jsx)(je,{icon:(0,b.jsx)(j.lnI,{}),label:(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{display:{md:"inline",xs:"none"}},children:"Time since last"})," ","Heal Activity"]}),value:c}),(0,b.jsx)(je,{icon:(0,b.jsx)(st.EY,{}),label:(0,b.jsxs)(f.Z,{children:[(0,b.jsx)(f.Z,{sx:{display:{md:"inline",xs:"none"}},children:"Time since last"})," ","Scan Activity"]}),value:o}),(0,b.jsx)(je,{icon:(0,b.jsx)(j.oNq,{}),label:"Uptime",value:u})]})]})]}),(0,b.jsx)(f.Z,{sx:{display:"grid",gridTemplateRows:"auto",gridTemplateColumns:"1fr",gap:"auto"},children:(0,b.jsx)(dt,{data:p})})]})]})})},mt=(0,p.Z)((function(e){return(0,u.Z)((0,l.Z)({},(0,h.Bz)(e.spacing(4))))}))((function(e){var t=e.classes,i=(0,$.TL)(),n=(0,r.useState)(!0),l=(0,a.Z)(n,2),o=l[0],d=l[1],c=(0,r.useState)(null),u=(0,a.Z)(c,2),p=u[0],f=u[1],h=(0,r.useCallback)((function(){F.Z.invoke("GET","/api/v1/admin/info").then((function(e){f(e),d(!1)})).catch((function(e){i((0,J.Ih)(e)),d(!1)}))}),[f,d,i]);(0,r.useEffect)((function(){o&&h()}),[o,h]);var m=s()(p,"widgets",null);return(0,b.jsxs)(r.Fragment,{children:[(0,b.jsx)(He.Z,{label:"Metrics"}),o?(0,b.jsx)(x.ZP,{container:!0,children:(0,b.jsx)(x.ZP,{item:!0,xs:12,className:t.container,children:(0,b.jsx)($e.Z,{})})}):(0,b.jsx)(r.Fragment,{children:null!==m?(0,b.jsx)(Ve,{}):(0,b.jsx)(ht,{usage:p})})]})}))},19847:function(e,t,i){i.d(t,{x:function(){return s}});var n=i(1413),a=i(45987),l=i(72791),r=i(80184),o=["children","value","index"],s=function(e){var t=e.children,i=e.value,s=e.index,d=(0,a.Z)(e,o);return(0,r.jsx)("div",(0,n.Z)((0,n.Z)({role:"tabpanel",hidden:i!==s,id:"simple-tabpanel-".concat(s),"aria-labelledby":"simple-tab-".concat(s),style:{marginTop:"5px"}},d),{},{children:i===s&&(0,r.jsx)(l.Fragment,{children:t})}))}}}]);
|
|
//# sourceMappingURL=1182.264ec55e.chunk.js.map
|