import{d as v,aV as y,aW as V,k as C,t as D,h as i,aX as F,c as _,i as l,j as d,o as n,l as a,D as x,p as r,m as e,aY as R,aC as S,Z as B,y as m,aZ as N,a_ as U,a$ as j,b0 as T,F as W,a as Z,B as A,b1 as E,u as Q}from"./index-7qezL2zM.js";import{s as H,a as I}from"./index-Vv9yEoRy.js";const M={class:"workspace-dashboard__header-actions"},P={class:"workspace-dashboard__subflows-toggle"},X={key:1,class:"workspace-dashboard__grid"},Y={class:"workspace-dashboard__side"},J=v({__name:"Dashboard",setup($){y(V,{interval:H(30)});const b=C(),c=D(b.flowRuns.getFlowRunsCount,[{}]),u=i(()=>c.executed),p=i(()=>c.response===0),f=[{text:"Dashboard"}],s=F({range:{type:"span",seconds:-I},tags:[]}),k=()=>Q.map("WorkspaceDashboardFilter",s,"TaskRunsFilter");return(q,o)=>{const g=d("p-toggle"),h=d("p-button"),w=d("p-layout-default");return n(),_(w,{class:"workspace-dashboard"},{header:l(()=>[a(e(B),{crumbs:f,class:"workspace-dashboard__page-heading"},x({_:2},[u.value&&!p.value?{name:"actions",fn:l(()=>[r("div",M,[r("div",P,[a(g,{modelValue:e(s).hideSubflows,"onUpdate:modelValue":o[0]||(o[0]=t=>e(s).hideSubflows=t),append:"Hide subflows"},null,8,["modelValue"])]),a(e(R),{selected:e(s).tags,"onUpdate:selected":o[1]||(o[1]=t=>e(s).tags=t),"empty-message":"All tags"},null,8,["selected"]),a(e(S),{modelValue:e(s).range,"onUpdate:modelValue":o[2]||(o[2]=t=>e(s).range=t),class:"workspace-dashboard__date-select"},null,8,["modelValue"])])]),key:"0"}:void 0]),1024)]),default:l(()=>[u.value?(n(),m(W,{key:0},[p.value?(n(),_(e(N),{key:0})):(n(),m("div",X,[a(e(U),{filter:e(s)},null,8,["filter"]),r("div",Y,[a(e(j),{filter:k}),a(e(T),{class:"workspace-dashboard__work-pools",filter:e(s)},null,8,["filter"])])]))],64)):Z("",!0),a(e(E),{title:"Ready to scale?",subtitle:"Webhooks, role and object-level security, and serverless push work pools on Prefect Cloud"},{actions:l(()=>[a(h,{to:"https://www.prefect.io/cloud-vs-oss?utm_source=oss&utm_medium=oss&utm_campaign=oss&utm_term=none&utm_content=none",target:"_blank",primary:""},{default:l(()=>[A(" Upgrade to Cloud ")]),_:1})]),_:1})]),_:1})}}});export{J as default};
//# sourceMappingURL=Dashboard-CbeAyIw-.js.map
