import{aP as b,o as d,s as h,dn as L,dp as P,e7 as E,h as i,i as c,j as t,ar as j,aR as M,cE as S}from"./app-BgLa5dit.js";import{u as V}from"./8Im-OACs.chunk.js";import{O as g}from"./B-fq6xxv.chunk.js";import{M as y}from"./CJkmdwb7.chunk.js";import{P as A}from"./DUyf8veO.chunk.js";import{E as D}from"./RTbqjc8Y.chunk.js";import"./g56uS58q.chunk.js";import"./CTg_3F42.chunk.js";import"./BfMtaC_g.chunk.js";function k(s){const m=b(),l=d(h.video(s.videoId)),a=d(M.currentUser());function u(e){return[{label:"Remove",button:!0,appLink:{application:c.VIDEOS,action:i.Videos.REMOVE_VIDEO_PLAYLIST,args:[s.videoId,e.id]},className:"btn btn-outline-danger"}]}const p=L.getColumnSet(P.VideoPlaylists),x={actions:u,appLinks:{[E.Playlist]:e=>({application:c.PLAYLISTS,action:i.Playlists.EDIT_PLAYLIST,args:[e.id]})}};function o(e){return A.videoPlaylists(s.videoId,e)}function n(e){return S(m)(o(e))}const{items:I,isFetching:r,hasMore:f,nextCursor:v}=V(o,n);return!r&&a.data?t.jsxs(t.Fragment,{children:[t.jsx(D,{videoId:s.videoId,activeAction:i.Videos.EDIT_VIDEO_PLAYLISTS,currentUser:a.data}),t.jsx(g,{object:l.data}),t.jsx(y,{members:I,columns:p,columnData:x,emptyStateText:"No playlist contains this video.",isFetching:r,fetchNext:n,nextCursor:v,hasMoreMembers:f})]}):t.jsx("div",{className:"text-center pt-5",children:t.jsx(j,{as:"div",animation:"border",role:"status"})})}export{k as EditVideoPlaylistsView};
//# sourceMappingURL=P1TkPvvm.chunk.js.map
