import{R as D,k as b,o as S,S as E,b as L,a4 as g,j as e,ar as R,h as s,i as r,dn as N,dp as f,D as x}from"./app-BgLa5dit.js";import{u as T}from"./ekVIVtrT.chunk.js";import{D as p}from"./BE59vaMU.chunk.js";import{D as j}from"./BYqcacqE.chunk.js";import"./KIVqng-q.chunk.js";import"./0GREfvNX.chunk.js";import"./JAv_fVmZ.chunk.js";import"./B5-QmNlz.chunk.js";import"./CTg_3F42.chunk.js";import"./DEF_vJGe.chunk.js";import"./CGQPfl0D.chunk.js";function H(n){const[i,d]=D.useState(!0),o=b();function c(a){return p.dashboards({targetType:x.Discover,presentationId:n.presentationId},i,a)}function m(a){o(c(a))}const h=T(c,m),t=S(E.presentation(n.presentationId)),{hasPermissions:l}=L();function A(a){return o(p.updateDashboard(a.id,a))}const u=l(g.StreamableLearningDashboardStatusUpdate);return t.data?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"mt-3",children:[e.jsx("h6",{children:`Presentation: ${t.data.name}`}),e.jsx("p",{children:t.data.description})]}),e.jsx(j,{presentation:t.data,dashboards:h.items,onStatusChange:A,canPublish:u,columns:N.getColumnSet(f.StreamableLearningDashboard),filterArchivedDashboards:i,setFilterArchivedDashboards:d,getEditDetailsAppLink:a=>({application:r.STREAMABLE_LEARNING,action:s.StreamableLearning.EDIT_DASHBOARD_DETAILS,args:[a]}),getDeleteAppLink:a=>({application:r.STREAMABLE_LEARNING,action:s.StreamableLearning.DELETE_DASHBOARD,args:[a]}),getNewDashboardAppLink:()=>({application:r.STREAMABLE_LEARNING,action:s.StreamableLearning.NEW_DASHBOARD,args:[n.presentationId]}),getCopyDashboardAppLink:a=>({application:r.STREAMABLE_LEARNING,action:s.StreamableLearning.COPY_DASHBOARD,args:[a]})})]}):e.jsx("div",{className:"text-center py-3",children:e.jsx(R,{as:"div",animation:"border",role:"status"})})}export{H as EditStreamableDashboardListView};
//# sourceMappingURL=COa9rfxd.chunk.js.map
