MOON
Server: Apache
System: Linux server1.studioinfinity.com.br 2.6.32-954.3.5.lve1.4.90.el6.x86_64 #1 SMP Tue Feb 21 12:26:30 UTC 2023 x86_64
User: artinside (517)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //proc/self/root/opt/netdata/netdata-web-files/v3/2003.6db8c3b0aa46cb13349f.chunk.js
try{!function(){var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},d=(new e.Error).stack;d&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[d]="4dd905e4-9f43-4f13-84c5-948bf53d2d12",e._sentryDebugIdIdentifier="sentry-dbid-4dd905e4-9f43-4f13-84c5-948bf53d2d12")}()}catch(e){}!function(){try{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{}).SENTRY_RELEASE={id:"876c8d00bbb6550831ec3bf04002c53f5c81bd78"}}catch(e){}}(),(self.webpackChunkcloud_frontend=self.webpackChunkcloud_frontend||[]).push([[2003],{92003:(e,d,t)=>{t.r(d),t.d(d,{Dropdown:()=>R,default:()=>B});var o=t(96540),a=t(33185),r=t(80689),n=t(43375),s=t(60602),i=t(29263),l=t(32788),c=t(41579),u=t(67294),p=t(92726),h=t(55093),b=t(15524),g=t(74848);const f=e=>(0,a.keyframes)(["from{border-color:",";border-width:2px;}to{border-color:",";border-width:1px;}"],(0,r.getColor)("primary")(e),(0,r.getColor)("textLite")(e)),m=(0,a.default)(r.Flex).withConfig({displayName:"dropArea__AnimatedFlex",componentId:"sc-vs4sjk-0"})(["animation:",";"],(e=>{let{animate:d}=e;return d?(0,a.css)([""," 0.15s linear infinite"],f):""})),x={},w=(0,o.memo)((e=>{let{item:d=x,itemProps:t=x}=e;const{id:o,name:a,isNew:s}=d,{overDashboardId:i}=t,{setNodeRef:l,isOver:c,over:u}=(0,n.zM)({id:o,data:{droppable:!0,dropArea:!0,dashboardId:o,onlyPointerWithin:!0}}),{processing:h,loading:b}=(0,p.fz)(o),f=h||b;return(0,g.jsx)(r.Flex,{padding:[2],flex:!0,background:i===o&&"successSemi",children:(0,g.jsx)(m,{alignItems:"center",justifyContent:"center",padding:[2],border:{side:"all",type:"dashed",color:c?"primary":"textLite"},round:!0,ref:l,width:"100%",height:15,animate:u?.id===o&&i!==o,children:f?(0,g.jsx)(r.Text,{color:"textLite",children:"Loading..."}):(0,g.jsxs)(r.TextBig,{color:i===o?"successText":"text",children:[s?"":(0,g.jsx)(g.Fragment,{children:"Add in "}),(0,g.jsx)(r.TextBig,{strong:!0,color:s?"primary":i===o?"successText":"text",children:a})]})})})})),y=((0,a.default)(r.Drop).attrs({align:{top:"bottom",left:"left"},animation:!0,backdrop:!0,column:!0,padding:[2,0],background:"dropdown",round:1,overflow:{vertical:"auto"},margin:[.5,0,0],width:30}).withConfig({displayName:"list__Dropdown",componentId:"sc-s8yppy-0"})([""]),(0,o.memo)((e=>{let{dashboards:d,selected:t,setSelected:o,itemProps:a}=e;const n=(0,b.A)();return(0,g.jsxs)(g.Fragment,{children:[(0,g.jsx)(w,{item:{id:"new",name:"Create a new dashboard",isNew:!0},itemProps:a}),(0,g.jsx)(r.MenuDropdown,{items:d,Item:w,value:t,hasSearch:!1,onItemClick:o,hideShadow:!0,itemProps:a,overflow:"hidden",ref:n})]})})));var D=t(97799),I=t(24609),v=t(19186),j=t(45706),C=t(88934),A=t(19371),k=t(63872),S=t(47090),_=t(3319),T=t(28864),F=t(5907),L=t(79748),N=t(52795),z=t(44245);const E=e=>{let{onDone:d}=e;const t=(0,C.Zp)(),a=(0,I.vt)(),r=(0,v.ID)(),n=(0,I.ns)(a,"slug"),s=(0,v.wz)(r,"slug"),i=(0,A.eg)(),[l,c]=(0,k.A)(),{sendLog:u}=(0,_.A)(),p=(0,z.tV)(),h=(0,T.DH)(null,{onSuccess:e=>{p({title:e.slug,id:e.id,destination:e.slug,type:"dashboards",droppable:!0,droppableProps:{dashboardId:e.id,dropArea:!0},tooltip:{title:e.slug,description:"Custom dashboard with personalized visualizations and metrics tailored to your monitoring requirements."}}),l({header:"Added",text:(0,g.jsxs)(g.Fragment,{children:["Chart added in"," ",(0,g.jsx)(L.A,{as:"a",strong:!0,onClick:()=>t(`/spaces/${n}/rooms/${s}/dashboards/${e.slug}`),children:e.name})," ","dashboard."]})}),setTimeout((()=>d()),2e3),u({feature:"drag-in-dashboard",isSuccess:!0})},onFail:e=>{const t=e?.response?.data,o=(0,S.o)(t?.errorMsgKey)||t?.errorMessage||"Something went wrong";c({message:o}),d(),u({feature:"drag-in-dashboard",isFailure:!0,message:o})}}),b=(0,F.nM)(),f=(0,F.Dn)(a,r);return(0,o.useCallback)(((e,d)=>{const t=i.getNode({id:d?.itemId}),o=(0,N.h)(t.getAttributes());"new"!==e?b(o.contextScope,{...o,dashboardId:e,itemLayout:d},(()=>h(e))):f({name:"[Untitled]"},(e=>{b(o.contextScope,{...o,dashboardId:e.id,itemLayout:d},(()=>h(e.id)))}))}),[f,b])},M=(0,a.default)(r.Flex).attrs({background:"mainBackground",padding:[2],overflow:"auto",height:"80%",width:"600px"}).withConfig({displayName:"dropDashboard__ScaledDownContainer",componentId:"sc-zd7fpn-0"})(["box-shadow:0 0 0 1px rgba(63,63,68,0.05),-1px 0 15px 0 rgba(34,33,81,0.01),0px 15px 15px 0 rgba(34,33,81,0.25);"]),P=e=>{let{id:d,setOverDashboard:t}=e;const o=(0,I.vt)(),a=(0,v.ID)(),n=(0,I.ns)(o,"slug"),s=(0,v.wz)(a,"slug"),i=(0,j.A)(d,{spaceId:o,spaceSlug:n,roomId:a,roomSlug:s}),l=E({onDone:t});return d?(0,g.jsx)(r.Flex,{flex:!0,width:"100%",height:"100%",alignItems:"center",justifyContent:"center",children:(0,g.jsx)(M,{children:i?(0,g.jsx)(h.A,{title:"Loading dashboard..."}):(0,g.jsx)(D.A,{id:d,containerWidth:600,trashable:!1,containerDndProps:{droppable:!0},onDragEnd:(e,o)=>{if(!o)return t();l(d,o)}})})}):null},R=(0,a.default)(r.Flex).attrs({column:!0,background:"dropdown",width:{max:"auto",min:100,base:100}}).withConfig({displayName:"dropInDashboard__Dropdown",componentId:"sc-12fd9r3-0"})(["box-shadow:0 0 0 1px rgba(63,63,68,0.05),-1px 0 15px 0 rgba(34,33,81,0.01),0px 15px 15px 0 rgba(34,33,81,0.25);"]),B=()=>{const[e,d]=(0,o.useState)(),[t,a]=(0,o.useState)();(0,c.A)();const b=(0,u.q)();let f=(0,p.Sf)(b);f=(0,o.useMemo)((()=>[...f].sort(((e,d)=>new Date(e.updatedAt)<new Date(d.updatedAt)?1:-1))),[b]);const m=(0,u.RQ)(),x=(0,s.A)(t?.id,500),w=E({onDone:a});(0,n.E5)({onDragMove:e=>{let{active:d,over:t}=e;t?.id&&d&&d.data.current&&(d.data.current.dashboardable?t.data.current.dropinDashboards?a((e=>e||{active:d,dropinDashboards:!0})):t.data.current.dashboardId?a((e=>e&&e?.id===t.data.current.dashboardId?e:{...e,id:t.data.current.dashboardId,active:d})):t.data.current.droppable||a():a())},onDragEnd:e=>{let{active:d,over:t}=e;t?.id&&d&&d.data.current&&(t.data.current.dashboardId&&d.data.current.dashboardable?w(t.data.current.dashboardId,d.data.current):setTimeout((()=>a()),1e3))},onDragCancel:()=>{a()}});const D=(0,o.useMemo)((()=>({overDashboardId:x})),[x]);if(!t?.active)return null;const{isItem:I,isContainer:v,dashboardable:j}=t.active.data.current;return j&&(I||v)?(0,g.jsxs)(r.Layer,{position:"right",full:!0,backdrop:!0,shadow:!0,justifyContent:"end",children:[(0,g.jsx)(P,{id:x,setOverDashboard:a}),t?.dropinDashboards&&(0,g.jsxs)(R,{children:[(0,g.jsx)(i.z,{title:"Drop in a dashboard",onClose:()=>a()}),(0,g.jsx)(l.Yv,{gap:2,height:"100%",overflow:"hidden",background:"dropdown",children:m?(0,g.jsx)(y,{dashboards:f,selected:e,setSelected:d,itemProps:D}):(0,g.jsx)(h.A,{title:"Loading dashboards..."})})]})]}):null}}}]);