import{d as w,B as y,G as S,a as R,E as x,c as d,R as p,b as C,e as _,w as c,o as l,h as s,H as F,u as e,I as B,s as m,V as D,J as V,g as f,K as I,N,O as A,P as E,Q as H,F as T,f as U,S as q,_ as G}from"./index-562c8470.js";import{s as J,a as K}from"./index-d6eb1d44.js";const L={key:1,class:"workspace-dashboard__grid"},M={class:"workspace-dashboard__side"},j=w({__name:"Dashboard",setup(O){y(S,{interval:J(30)});const v=R(),u=x(v.flowRuns.getFlowRunsCount,[{}]),k=d(()=>u.executed),i=d(()=>u.response===0),b=[{text:"Dashboard"}],a=p("span",q,K*24),t=p("tags",[]),n=d(()=>({timeSpanInSeconds:a.value,tags:t.value})),g=()=>G.map("WorkspaceDashboardFilter",n.value,"TaskRunsFilter");return(P,o)=>{const h=C("p-layout-default");return l(),_(h,{class:"workspace-dashboard"},{header:c(()=>[s(e(V),{crumbs:b},F({_:2},[i.value?void 0:{name:"actions",fn:c(()=>[s(e(B),{selected:e(t),"onUpdate:selected":o[0]||(o[0]=r=>m(t)?t.value=r:null),filter:{},"empty-message":"All tags",class:"workspace-dashboard__tags"},null,8,["selected"]),s(e(D),{selected:e(a),"onUpdate:selected":o[1]||(o[1]=r=>m(a)?a.value=r:null)},null,8,["selected"])]),key:"0"}]),1024)]),default:c(()=>[k.value?(l(),f(T,{key:0},[i.value?(l(),_(e(I),{key:0})):(l(),f("div",L,[s(e(N),{filter:n.value},null,8,["filter"]),A("div",M,[s(e(E),{filter:g}),s(e(H),{class:"workspace-dashboard__work-pools",filter:n.value},null,8,["filter"])])]))],64)):U("",!0)]),_:1})}}});export{j as default};
