import{A as e,G as t,I as n,P as r,Pt as i,Q as a,Tt as o,Z as s,bt as c,et as l,ht as u,o as d}from"./vue-vendor-DMUmTARL.js";import{t as f}from"./AdminSettingLayout-CzCwKa9p.js";import{t as p}from"./route-block-D7Rwj2No.js";import{i as m}from"./useMonitorCharts-DKKyM31W.js";import{t as h}from"./MonitorMicroCards-CC33dtgf.js";import{t as g}from"./useMonitorData-CVv8eY_l.js";import{t as _}from"./BuildInfoSection-Du0AaEO6.js";import{t as v}from"./MonitorChartDialog-BOZ92DV_.js";import{t as y}from"./MonitorToolbar-Dgibz-pZ.js";import{t as b}from"./RuntimeEnvSection-BlqSJ514.js";var x={class:`flex h-full flex-col`},S=n({__name:`index`,setup(n){let{history:p,applyTrend:S}=m(),{monitorData:C,lastUpdateTime:w,isLoading:T,isError:E,isPaused:D,refreshInterval:O,countdown:k,togglePause:A,changeInterval:j,start:M,stop:N}=g({onTrend:S}),P=o(!1),F=o(`cpu`),I=e=>{F.value=e,P.value=!0},L=d(),R=()=>{L.hash&&t(()=>{let e=document.querySelector(L.hash);e&&typeof e.scrollIntoView==`function`&&e.scrollIntoView({behavior:`smooth`,block:`start`})})};return s(()=>{M(),R()}),a(()=>{N()}),(t,n)=>{let a=f;return l(),e(`div`,x,[r(a,{plain:``},{default:u(()=>[r(y,{"refresh-interval":i(O),"onUpdate:refreshInterval":n[0]||=e=>c(O)?O.value=e:null,"is-paused":i(D),"last-update-time":i(w),countdown:i(k),onChangeInterval:i(j),onTogglePause:i(A)},null,8,[`refresh-interval`,`is-paused`,`last-update-time`,`countdown`,`onChangeInterval`,`onTogglePause`]),r(h,{"monitor-data":i(C),"is-loading":i(T),"is-error":i(E),history:i(p),onViewChart:I},null,8,[`monitor-data`,`is-loading`,`is-error`,`history`]),r(b),r(_)]),_:1}),r(v,{visible:i(P),"onUpdate:visible":n[1]||=e=>c(P)?P.value=e:null,type:i(F),history:i(p)},null,8,[`visible`,`type`,`history`])])}}});typeof p==`function`&&p(S);var C=S;export{C as default};