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: //opt/netdata/usr/share/netdata/web/v3/8707.36b4d7e72466ccf395e9.chunk.js
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"8b1701d6db299c2b7259bc89c3ef365137725d5e"};var t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="a553fdce-983e-4411-bac2-b4d8d132aff5",e._sentryDebugIdIdentifier="sentry-dbid-a553fdce-983e-4411-bac2-b4d8d132aff5")}catch(e){}}(),(globalThis.webpackChunkcloud_frontend=globalThis.webpackChunkcloud_frontend||[]).push([[8707],{68453(e,t,n){n.d(t,{A:()=>Z});var o=n(96540),s=n(38429);const r={snapshot:null,index:0,elapsedMs:0,totalMs:0,paused:!1,transitioning:!1,loopCount:0},a="HYDRATE",i="REHYDRATE",l="TICK",d="PAUSE",c="RESUME",u="NEXT",p="PREV",h="JUMP",f="DISMISS",m=e=>({type:a,snapshot:e}),x=e=>({type:i,snapshot:e}),y=e=>({type:l,elapsedMs:e}),g=()=>({type:d}),b=()=>({type:c}),w=()=>({type:u}),v=()=>({type:p}),M=e=>({type:h,index:e}),I=()=>({type:f}),C=(e,t)=>e?.entries?.[t]?.durationMs??0,k=(e,t)=>{switch(t.type){case a:return{...r,snapshot:t.snapshot,totalMs:C(t.snapshot,0)};case i:{const n=t.snapshot,o=n?.entries||[],s=Math.min(e.index,Math.max(0,o.length-1)),r=o[s]?.id===e.snapshot?.entries?.[e.index]?.id;return{...e,snapshot:n,index:s,elapsedMs:r?e.elapsedMs:0,totalMs:C(n,s)}}case l:return e.paused?e:t.elapsedMs>=e.totalMs?k(e,w()):{...e,elapsedMs:t.elapsedMs};case d:return{...e,paused:!0};case c:return{...e,paused:!1};case u:{const t=(e.snapshot?.entries||[]).length-1;if(e.index<t){const t=e.index+1;return{...e,index:t,elapsedMs:0,totalMs:C(e.snapshot,t)}}return e.snapshot?.loop?{...e,index:0,elapsedMs:0,totalMs:C(e.snapshot,0),loopCount:e.loopCount+1}:{...e,paused:!0}}case p:{const t=Math.max(0,e.index-1);return{...e,index:t,elapsedMs:0,totalMs:C(e.snapshot,t)}}case h:{const n=e.snapshot?.entries||[],o=Math.max(0,n.length-1),s=Math.min(Math.max(0,t.index),o);return{...e,index:s,elapsedMs:0,totalMs:C(e.snapshot,s)}}case f:return{...r};default:return e}},j=k;var E=n(54148),F=n(96957),T=n(74959),R=n(63474),A=n(45706),_=n(87398),S=(n(98992),n(3949),n(74848));const N=e=>{let{active:t,durationMs:n,scrollSpeed:r,children:a}=e;const i=(0,o.useRef)(null);return(0,o.useEffect)(()=>{if(!t||!i.current)return;let e=!1,o=0,s=null,a="";const l=[],d=()=>{if(e)return;const t=i.current?.querySelector('[data-testid="dashboardGrid"]');if(!t)return void(o=requestAnimationFrame(d));const c=t.scrollHeight-t.clientHeight;if(c<=0)return void(o=requestAnimationFrame(d));s=t,a=t.style.overflow,t.style.overflow="hidden",t.scrollTop=0;const u=r?c/r*1e3:n;Array.from(t.children).forEach(e=>{const t=e.animate([{transform:"translateY(0)"},{transform:`translateY(-${c}px)`}],{duration:u,easing:"linear",fill:"forwards"});l.push(t)})};return o=requestAnimationFrame(d),()=>{e=!0,cancelAnimationFrame(o),l.forEach(e=>e.cancel()),s&&(s.style.overflow=a)}},[t,n,r]),(0,S.jsx)(s.Flex,{ref:i,flex:"1",width:"100%",height:"100%",overflow:"hidden",position:"relative",children:a})},$=e=>{let{dashboardId:t,spaceId:n,roomId:r,entry:a,active:i,durationMs:l}=e;const d=(0,A.A)(t,{spaceId:n,roomId:r,skipIfLoaded:!0}),c=(0,_.eg)();return(0,o.useEffect)(()=>{if(!i||!a?.timeRange)return;const e=c?.getRoot?.();e?.moveX&&e.moveX(a.timeRange.after,a.timeRange.before)},[i,a?.timeRange?.after,a?.timeRange?.before,c]),d?(0,S.jsx)(s.Flex,{"data-testid":"entry-loading",column:!0,flex:"1",width:"100%",height:"100%",children:(0,S.jsx)(R.O2,{})}):"scroll"===a?.mode?(0,S.jsx)(N,{active:i,durationMs:l,scrollSpeed:a?.scrollSpeed,children:(0,S.jsx)(T.J,{id:t,roomId:r,isOnTV:!0})}):(0,S.jsx)(s.Flex,{flex:"1",width:"100%",height:"100%",overflow:"hidden",position:"relative",children:(0,S.jsx)(T.J,{id:t,roomId:r,isOnTV:!0})})};var P=n(882);const B=(0,P.keyframes)(["from{opacity:0}to{opacity:1}"]),L=(0,P.default)(s.Flex).attrs({position:"absolute",inset:"0",column:!0,alignItems:"center",justifyContent:"center",gap:2}).withConfig({displayName:"titleCard__Overlay",componentId:"sc-1c91sxd-0"})(["background:#0b1220;color:#fff;animation:"," 400ms ease-out;z-index:10;"],B),D=e=>{let{index:t,total:n,upNext:o}=e;return(0,S.jsxs)(L,{children:[(0,S.jsx)(s.TextSmall,{opacity:.6,style:{letterSpacing:"1px",textTransform:"uppercase"},children:"Up next"}),(0,S.jsx)(s.Text,{fontSize:"18px",strong:!0,children:o}),(0,S.jsxs)(s.TextSmall,{opacity:.5,children:[t+1," of ",n]})]})},q=(0,P.keyframes)(["from{opacity:0}to{opacity:1}"]),O=(0,P.keyframes)(["from{opacity:1}to{opacity:0}"]),z=(0,P.default)(s.Flex).attrs({position:"absolute",top:"0",left:"0",width:"100%",height:"100%"}).withConfig({displayName:"transition__Layer",componentId:"sc-167y0wu-0"})(["animation:"," 400ms ease-out forwards;"],e=>"in"===e.state?q:O),H=(0,P.default)(s.Flex).attrs({position:"relative",flex:"1",width:"100%",height:"100%"}).withConfig({displayName:"transition__Stack",componentId:"sc-167y0wu-1"})([""]),K=e=>{let{kind:t,index:n,total:o,transitioning:s,incoming:r,outgoing:a,incomingKey:i,outgoingKey:l,upNext:d}=e;return"cut"===t?(0,S.jsx)(H,{children:r}):(0,S.jsxs)(H,{children:[s&&a&&(0,S.jsx)(z,{state:"out",children:a},l),s&&"titleCard"===t&&(0,S.jsx)(D,{index:n,total:o,upNext:d},`title-${i}`),(0,S.jsx)(z,{state:"in",children:r},i)]})},X=(0,P.default)(s.Flex).attrs({position:"absolute",top:3,left:"50%",gap:2,padding:[1,2],alignItems:"center",background:"tooltip",round:2,border:{side:"all",color:"border"},zIndex:5}).withConfig({displayName:"hud__Ambient",componentId:"sc-1y5tk1w-0"})(["transform:translateX(-50%);backdrop-filter:blur(8px);opacity:",";transition:opacity 200ms ease;pointer-events:",";"],e=>e.visible?1:0,e=>e.visible?"auto":"none"),Y=(0,P.default)(s.Flex).attrs({position:"absolute",bottom:3,left:"50%",gap:2,padding:[2,3],alignItems:"center",background:"tooltip",round:2,border:{side:"all",color:"border"},zIndex:10}).withConfig({displayName:"hud__Controls",componentId:"sc-1y5tk1w-1"})(["transform:translateX(-50%);backdrop-filter:blur(8px);opacity:",";transition:opacity 200ms ease;pointer-events:",";"],e=>e.visible?1:0,e=>e.visible?"auto":"none"),U=e=>{let{playlistName:t,index:n,total:r,elapsedMs:a,totalMs:i,paused:l,onTogglePause:d,onNext:c,onPrev:u,onClose:p,onToggleFullscreen:h,showClose:f,showFullscreen:m}=e;const[x,y]=(0,o.useState)(!1),g=(0,o.useRef)(0);(0,o.useEffect)(()=>{const e=()=>{y(!0),window.clearTimeout(g.current),g.current=window.setTimeout(()=>y(!1),3e3)};return window.addEventListener("mousemove",e),window.addEventListener("keydown",e),()=>{window.removeEventListener("mousemove",e),window.removeEventListener("keydown",e),window.clearTimeout(g.current)}},[]);const b=i>0?Math.min(100,a/i*100):0;return(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(X,{visible:x,children:[(0,S.jsx)(s.Text,{color:"text",children:t}),(0,S.jsxs)(s.TextSmall,{color:"textLite",children:["\xb7 ",n+1," / ",r]}),(0,S.jsx)(s.Box,{width:"160px",height:"2px",background:"separator",round:!0,overflow:"hidden",children:(0,S.jsx)(s.Box,{width:`${b}%`,height:"100%",background:"primary"})})]}),(0,S.jsxs)(Y,{visible:x,"data-testid":"playback-controls",children:[(0,S.jsx)(s.IconButton,{icon:"chevron_left",onClick:u,tooltip:"Previous"}),(0,S.jsx)(s.IconButton,{icon:l?"play_solid":"pause_solid",onClick:d,tooltip:l?"Play":"Pause"}),(0,S.jsx)(s.IconButton,{icon:"chevron_right",onClick:c,tooltip:"Next"}),m&&(0,S.jsx)(s.IconButton,{icon:"expand",onClick:h,tooltip:"Fullscreen"}),f&&(0,S.jsx)(s.IconButton,{icon:"x",onClick:p,tooltip:"Close"})]})]})},V=e=>{let{onClose:t}=e;return(0,S.jsxs)(s.Flex,{flex:"1",column:!0,alignItems:"center",justifyContent:"center",gap:3,background:"mainBackground",children:[(0,S.jsx)(s.H3,{children:"Playlist is no longer available"}),(0,S.jsx)(s.Text,{children:"The playlist you were viewing was deleted or cannot be loaded."}),t&&(0,S.jsx)(s.Button,{onClick:t,children:"Close"})]})},J=e=>e?.timeRange?`${e.timeRange.after}:${e.timeRange.before}`:"default",Z=e=>{let{playlist:t,spaceId:n,roomId:a,mode:i,onClose:l,onLoopAdvance:d}=e;const{state:c,pause:u,resume:p,next:h,prev:f,rehydrate:C}=(e=>{const[t,n]=(0,o.useReducer)(j,r),s=(0,o.useRef)(0),a=(0,o.useRef)(0),i=(0,o.useRef)(0);(0,o.useEffect)(()=>{e&&(n(m(e)),s.current=performance.now(),a.current=0)},[e?.playlistId]),(0,o.useEffect)(()=>{const e=t=>{const o=t-s.current-a.current;n(y(Math.max(0,Math.floor(o)))),i.current=requestAnimationFrame(e)};return i.current=requestAnimationFrame(e),()=>cancelAnimationFrame(i.current)},[t.index,t.paused,t.snapshot?.playlistId,t.loopCount]),(0,o.useEffect)(()=>{s.current=performance.now(),a.current=0},[t.index,t.loopCount]);const l=(0,o.useCallback)(()=>{a.current+=performance.now()-s.current-t.elapsedMs,n(g())},[t.elapsedMs]),d=(0,o.useCallback)(()=>{s.current=performance.now()-t.elapsedMs,a.current=0,n(b())},[t.elapsedMs]),c=(0,o.useCallback)(()=>n(w()),[]),u=(0,o.useCallback)(()=>n(v()),[]),p=(0,o.useCallback)(e=>n(M(e)),[]),h=(0,o.useCallback)(e=>n(x(e)),[]),f=(0,o.useCallback)(()=>n(I()),[]);return{state:t,dispatch:n,pause:l,resume:d,next:c,prev:u,jump:p,rehydrate:h,dismiss:f}})(t),[k,T]=(0,o.useState)(!1),[R,A]=(0,o.useState)(null),_=(0,o.useRef)(null),N=c.snapshot,P=N?.entries||[],B=P[c.index],L=(c.index+1)%Math.max(P.length,1),D=P[L],q=(0,F.fz)(B?.dashboardId);(0,o.useEffect)(()=>{c.loopCount>0&&t&&C(t)},[c.loopCount]),(0,o.useEffect)(()=>{c.loopCount>0&&d?.(c.loopCount)},[c.loopCount,d]),(0,o.useEffect)(()=>{if(!N)return;const e=_.current;if(_.current=c.index,null===e||e===c.index)return;const t=N.entries?.[e];if(!t)return;A(t),T(!0);const n=E.r$[N.transition]||0,o=window.setTimeout(()=>{T(!1),A(null)},n);return()=>window.clearTimeout(o)},[c.index,c.loopCount,N]);const O=(0,o.useMemo)(()=>!(!B||!D||P.length<2)&&(!(c.totalMs-c.elapsedMs>E.Oy)&&J(B)===J(D)),[B,D,P.length,c.totalMs,c.elapsedMs]);if((e=>{let{togglePause:t,next:n,prev:s,toggleFullscreen:r,onEsc:a}=e;(0,o.useEffect)(()=>{const e=e=>{" "===e.key||"Space"===e.code?(t?.(),e.preventDefault()):"ArrowRight"===e.key?n?.():"ArrowLeft"===e.key?s?.():"f"===e.key||"F"===e.key?r?.():"Escape"===e.key&&a?.()};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[t,n,s,r,a])})({togglePause:()=>c.paused?p():u(),next:h,prev:f,toggleFullscreen:()=>{"layer"===i&&(document.fullscreenElement?document.exitFullscreen():document.documentElement.requestFullscreen())},onEsc:"layer"===i?l:()=>C(t)}),!t&&!N)return(0,S.jsx)(V,{onClose:l});if(0===P.length)return(0,S.jsx)(s.Flex,{flex:"1",alignItems:"center",justifyContent:"center",children:"Add dashboards to play this playlist."});const z=(0,S.jsx)($,{dashboardId:B.dashboardId,spaceId:n,roomId:a,entry:B,active:!0,durationMs:B.durationMs},`entry-${c.index}`),H=R?(0,S.jsx)($,{dashboardId:R.dashboardId,spaceId:n,roomId:a,entry:R,active:!1,durationMs:R.durationMs},`outgoing-${R.id}`):null,X=O?(0,S.jsx)($,{dashboardId:D.dashboardId,spaceId:n,roomId:a,entry:D,active:!1,durationMs:D.durationMs},`prefetch-${L}`):null;return(0,S.jsxs)(s.Flex,{flex:"1",width:"100%",height:"100%",position:"relative",background:"mainBackground",children:[X&&(0,S.jsx)(s.Flex,{position:"absolute",top:"0",left:"0",width:"100%",height:"100%",style:{visibility:"hidden"},children:X}),(0,S.jsx)(K,{kind:N.transition,index:c.index,total:P.length,transitioning:k,incoming:z,outgoing:H,incomingKey:`layer-${B.dashboardId}-${c.index}`,outgoingKey:R?`layer-out-${R.dashboardId}-${R.id}`:null,upNext:q?.name||B.dashboardId}),(0,S.jsx)(U,{playlistName:N.name,index:c.index,total:P.length,elapsedMs:c.elapsedMs,totalMs:c.totalMs,paused:c.paused,onTogglePause:()=>c.paused?p():u(),onNext:h,onPrev:f,onClose:"layer"===i?l:void 0,onToggleFullscreen:"layer"===i?()=>document.fullscreenElement?document.exitFullscreen():document.documentElement.requestFullscreen():void 0,showClose:"layer"===i,showFullscreen:"layer"===i})]})}},54148(e,t,n){n.d(t,{Bb:()=>a,CA:()=>r,Ez:()=>l,Oy:()=>h,Zg:()=>o,hO:()=>d,iH:()=>u,lR:()=>i,r$:()=>p,sV:()=>c,w0:()=>s});const o="dashboards",s="playlist",r="room",a="/",i=4e4,l="fade",d="static",c={after:-9e5,before:0},u=["cut","fade","titleCard"],p={cut:0,fade:400,titleCard:800},h=2e3},591(e,t,n){n.d(t,{W9:()=>d,ng:()=>l,yp:()=>c});n(98992),n(54520),n(72577),n(81454);var o=n(96540),s=n(49163),r=n(54148);const a=e=>{if(!e)return null;const{id:t,name:n,value:o={},scope:s,type:r,entity:a,path:i,roomID:l,version:d}=e;return{playlistId:t,name:n,entries:o.entries||[],transition:o.transition||"fade",loop:!1!==o.loop,createdAt:o.createdAt,updatedAt:o.updatedAt,raw:{scope:s,type:r,entity:a,path:i,roomID:l,version:d}}},i=()=>(0,s._)({params:{type:[r.Zg],entity:[r.w0]}}),l=()=>{const e=i();return(0,o.useMemo)(()=>e.map(a).filter(Boolean),[e])},d=e=>{const t=i();return(0,o.useMemo)(()=>{const n=t.find(t=>t.id===e);return n?a(n):null},[t,e])},c=e=>{const t=i();return(0,o.useMemo)(()=>t.find(t=>t.id===e)||null,[t,e])}}}]);