summaryrefslogtreecommitdiffstats
path: root/src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js')
-rw-r--r--src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js b/src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js
deleted file mode 100644
index 2b0194299f..0000000000
--- a/src/web/gui/v2/3564.7e7156bbbb89c8e2e618.chunk.js
+++ /dev/null
@@ -1 +0,0 @@
-!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]="6ec07544-fd94-4f9f-b2e9-8f2d0aebfa71",e._sentryDebugIdIdentifier="sentry-dbid-6ec07544-fd94-4f9f-b2e9-8f2d0aebfa71")}catch(e){}}();var _global="undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:{};_global.SENTRY_RELEASE={id:"67fcafa0e89723987481f6de299b5bd1fcd6618a"},(self.webpackChunkcloud_frontend=self.webpackChunkcloud_frontend||[]).push([[3564],{16512:function(e,t,n){n.d(t,{Q0:function(){return l},R4:function(){return m},TT:function(){return c},WL:function(){return d},Y:function(){return i},by:function(){return u},qY:function(){return r},rU:function(){return f},xL:function(){return s}});var a=n(71893),o=n(99113),l=a.default.img.withConfig({displayName:"styled__Illustration",componentId:"sc-1yhntgl-0"})(["margin:0 auto;"]),r=(0,a.default)(o.Text).withConfig({displayName:"styled__StyledText",componentId:"sc-1yhntgl-1"})(["display:block;"]),i=a.default.div.withConfig({displayName:"styled__TextHeader",componentId:"sc-1yhntgl-2"})(["margin-bottom:",";font-weight:700;"],(0,o.getSizeBy)(2)),d=a.default.div.withConfig({displayName:"styled__StaticCheckmarks",componentId:"sc-1yhntgl-3"})(["margin-top:",";margin-bottom:",";"],(0,o.getSizeBy)(2),(0,o.getSizeBy)(5)),c=a.default.div.withConfig({displayName:"styled__CheckmarkLine",componentId:"sc-1yhntgl-4"})(["display:flex;align-items:center;"]),s=(0,a.default)(o.Icon).withConfig({displayName:"styled__StyledIcon",componentId:"sc-1yhntgl-5"})(["margin-right:4px;height:18px;> use{fill:",";}"],(0,o.getColor)("primary")),u=(0,a.default)(s).withConfig({displayName:"styled__HelpIcon",componentId:"sc-1yhntgl-6"})(["vertical-align:middle;"]),m=a.default.div.withConfig({displayName:"styled__LearnMoreSection",componentId:"sc-1yhntgl-7"})(["margin-top:",";"],(0,o.getSizeBy)(4)),f=a.default.a.withConfig({displayName:"styled__Link",componentId:"sc-1yhntgl-8"})(["text-decoration:underline;color:",";&:visited{color:",";}"],(0,o.getColor)("success"),(0,o.getColor)("success"))},43564:function(e,t,n){n.r(t),n.d(t,{default:function(){return O}});var a=n(29439),o=n(67294),l=n(99113),r=n(46667),i=n(29748),d=n(5934),c=(n(92222),n(89250)),s=n(16645),u=n(7693),m=n(92903),f=n(62200),h=n(37518),b=n(74059),g=n(97723),y=n(87574),p=n(59112),w=n(16512),E=function(e){var t=e.onClose,n=(0,c.s0)(),r=(0,o.useState)(!1),i=(0,a.Z)(r,2),d=i[0],E=i[1],v=(0,o.useState)(""),C=(0,a.Z)(v,2),x=C[0],D=C[1],T=(0,b.OS)(),k=T.id,A=T.slug,_=(0,h.UL)(),S=(0,h.vf)(),L=(0,o.useCallback)((function(e){var a=e.slug;t(),n("/spaces/".concat(A,"/rooms/").concat(S,"/dashboards/").concat(a))}),[A,S]),I=(0,g.EW)(k,_,{onSuccess:L}),N=(0,o.useCallback)((function(){return I({name:x})}),[x]),M=x.length>0;return o.createElement(s.u6,{onClose:t},o.createElement(u.x,{onClose:t,title:"New Dashboard"},o.createElement(l.Button,{label:"Add",icon:"plus",onClick:N,"data-testid":"addNewDashboardModal-add-button"})),o.createElement(m.B,null,"Create new Dashboard"),o.createElement(s.TZ,null,o.createElement(p.Z,{value:x,label:"Name",onChange:function(e){D(e.target.value)},isValid:d,setIsValid:E,isDirty:M,instantFeedback:"all",onKeyDown:function(e){return e.keyCode===f.DV&&d&&N},"data-testid":"addNewDashboardModal-dashboardName-input",containerStyles:{flex:{grow:0,shrink:0},margin:[0,0,4,0]}}),o.createElement(w.qY,null,o.createElement(w.Y,null,"What you can do with Dashboards?"),"Combine all the metrics that matter to you, from all the nodes that matter to you, into one clean interface that helps you visually detect anomalies as they\u2019re happening. Building a new dashboard will only take a few minutes, and the metrics are always real-time."),o.createElement(w.WL,null,o.createElement(w.TT,null,o.createElement(w.xL,{name:"check"}),o.createElement(l.Text,null,"Add charts from your infrastructure")),o.createElement(w.TT,null,o.createElement(w.xL,{name:"check"}),o.createElement(l.Text,null,"Group information in a meaningful way")),o.createElement(w.R4,null,o.createElement(w.by,{name:"help"}),o.createElement(l.Text,null,"Learn more about Dashboards")," ",o.createElement(w.rU,{href:"https://learn.netdata.cloud/docs/cloud/visualize/dashboards",target:"_blank",rel:"noopener noreferrer"},"In our documentation"))),o.createElement(w.Q0,{src:y.X})))},v=n(78266),C=n(50308),x=n.n(C),D=(n(26699),n(32023),n(15861)),T=n(64687),k=n.n(T),A=(n(21249),n(57640),n(9924),n(41539),n(64211),n(2490),n(41874),n(34735)),_=function(e){var t=e.handleOpenAddDashboardModal,n=e.hasPermissionToAddDashboard,a=e.hasPermissionToDeleteDashboard,l=e.refetch,r=(0,h.Hm)("name"),i=(0,g.qN)(),c=(0,d.ie)(),s=(0,A.Z)(),u=s.hasLimitations,m=s.maxDashboards,f=function(){var e=(0,D.Z)(k().mark((function e(t,n){var a,o;return k().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=Array.isArray(t)?t:[t],o=a.map((function(e){return e.id})),e.next=4,i({ids:o},{onSuccess:n.resetRowSelection});case 4:l();case 5:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}(),b=(0,o.useMemo)((function(){return{delete:{confirmLabel:"Yes, delete",confirmationMessage:function(e){return o.createElement(o.Fragment,null,"You are about to delete ",o.createElement("strong",null,e.name)," from ",o.createElement("strong",null,r),".",o.createElement("br",null),"Are you sure you want to continue?")},confirmationTitle:function(e){return"Delete ".concat(e.name)},declineLabel:"Cancel",handleAction:f,tooltipText:"Delete dashboard",isVisible:a}}}),[a]),y=(0,o.useMemo)((function(){return{addEntry:{handleAction:t,isVisible:n,tooltipText:"Create dashboard",disabledTooltipText:"Your plan does not allow you to create more than ".concat(m," dashboards."),disabled:u&&c.length>=m},delete:{confirmLabel:"Yes, delete",confirmationMessage:function(e,t){return o.createElement(o.Fragment,null,"You are about to delete"," ",o.createElement("strong",null,t.length>1?"".concat(t.length," dashboards"):t[0].name)," ","from ",o.createElement("strong",null,r),".",o.createElement("br",null),"Are you sure you want to continue?")},confirmationTitle:function(){return"Delete"},disabledTooltipText:"Delete is disabled because you haven't selected dashboards",declineLabel:"Cancel",handleAction:f,tooltipText:"Delete dashboards",isVisible:a}}}));return{rowActions:a?b:[],bulkActions:[n,a].some(Boolean)?y:[]}},S=n(47133),L=n(82351),I=function(e){var t=new Date(e).toDateString().split(" "),n=(0,a.Z)(t,4),o=n[1],l=n[2],r=n[3];return"".concat(o," ").concat(l,", ").concat(r)},N=n(91008),M=function(e){var t=e.name;return o.createElement(l.Flex,{width:"300px",column:!0,gap:1},o.createElement(l.Text,{strong:!0},"Locked!"),o.createElement(l.Text,null,"The dashboard ",o.createElement(l.Text,{strong:!0},t)," is locked."),o.createElement(l.Text,null,"Your plan is limited to 1 dashboard. You can delete some dashboards or upgrade your plan for no limitations."))},F=function(e){var t,n=e.getValue,a=e.row,r="notAvailable"==(null===a||void 0===a||null===(t=a.original)||void 0===t?void 0:t.state),i=n();return r?o.createElement(L.Z,{content:o.createElement(M,{name:i}),align:"bottom",isBasic:!0},o.createElement(l.Flex,{alignItems:"center"},o.createElement(l.Text,null,i),o.createElement(l.Icon,{name:"padlock",height:"12px",color:"text"}))):o.createElement(N.Z,{as:"Link",to:a.original.slug},i)},Z=n(33335),V=function(e){var t=e.refetch,n=e.handleOpenAddDashboardModal,l=(0,o.useState)(),r=(0,a.Z)(l,2)[1],i=(0,d.ie)(),c=(0,S.QF)(i),s=(0,Z.gI)("dashboard:Create"),u=(0,Z.gI)("dashboard:Delete"),m=(0,o.useMemo)((function(){return[{id:"name",accessorKey:"name",header:"Name",cell:F},{id:"lastModified",accessorKey:"updatedAt",header:"Last modified",cell:function(e){var t=e.getValue;return I(t())}},{id:"createdAt",accessorKey:"createdAt",header:"Created",cell:function(e){var t=e.getValue;return I(t())}}]}),[]),f=_({dashboards:c,handleOpenAddDashboardModal:n,hasPermissionToAddDashboard:s,hasPermissionToDeleteDashboard:u,refetch:t});return{rowActions:f.rowActions,bulkActions:f.bulkActions,data:c,enableSelection:u,columns:m,enableSorting:!0,globalFilterFn:(0,o.useCallback)((function(e,t,n){var a=n.toLowerCase(),o=e.getValue("agent").toLowerCase(),l="".concat(I(e.getValue("lastModified")).toLowerCase()),r="".concat(I(e.getValue("createdAt")).toLowerCase());return o.includes(a)||l.includes(a)||r.includes(a)}),[]),setGlobalFilter:r}},Y=function(e){var t=e.refetch,n=void 0===t?x():t,a=e.handleOpenAddDashboardModal,r=V({refetch:n,handleOpenAddDashboardModal:a}),i=r.enableSelection,d=r.columns,c=r.data,s=r.rowActions,u=r.bulkActions,m=r.enableSorting,f=r.globalFilterFn,h=r.setGlobalFilter;return o.createElement(l.Table,{rowActions:s,enableSelection:i,data:c,dataColumns:d,bulkActions:u,enableSorting:m,globalFilterFn:f,onSearch:h,testPrefixCallback:function(e){return e.name}})},B=n(63346),O=function(){var e=(0,i.Z)(),t=(0,r.Z)(!1),n=(0,a.Z)(t,4),c=n[0],s=n[2],u=n[3];return(0,d.L)()?o.createElement(B.ZP,{feature:"DashboardOverview"},o.createElement(l.Flex,{position:"relative",width:"100%",height:"100%",flex:!0,column:!0,padding:[4]},o.createElement(Y,{refetch:e,handleOpenAddDashboardModal:s}),c&&o.createElement(E,{onClose:u}))):o.createElement(v.Z,{title:"Loading dashboards..."})}}}]); \ No newline at end of file