import{ao as e,aU as t,aP as S,aq as i,aG as A,aH as V,ba as v,f as p,e as m,L as R,bN as C,p as I,az as h,fu as f,aX as b,aZ as w,fp as y,c3 as k,cz as O}from"./app-k0jcl5PQ.js";import{P as _}from"./D9SGbB34.chunk.js";import{P as H,V as G,a as q}from"./DH1mz64H.chunk.js";import{R as z}from"./BpIVHcUT.chunk.js";import{u as F,V as M}from"./BUtU6IOA.chunk.js";import{u as U}from"./DDxzgH2W.chunk.js";import{R as $}from"./DzJMFLaU.chunk.js";import{S as B}from"./EHuWazu9.chunk.js";import{C as D}from"./Cw9cwr2f.chunk.js";import"./BwBaQklX.chunk.js";import"./BlKMjFEf.chunk.js";import"./CofWDDSQ.chunk.js";import"./DwvfEevL.chunk.js";import"./ByBCp1MC.chunk.js";import"./BhYYYlpK.chunk.js";import"./FGhEvk_q.chunk.js";import"./WCBjpMHJ.chunk.js";import"./DoFMWlew.chunk.js";import"./CMnqIsoM.chunk.js";import"./eerUhItV.chunk.js";import"./Cukd0Qmt.chunk.js";import"./B31bqZwo.chunk.js";import"./uoUaCILN.chunk.js";import"./f_twTV5Z.chunk.js";import"./BDeUEvb2.chunk.js";import"./Daim1zo7.chunk.js";import"./B3XH0kWB.chunk.js";import"./BRhv_AHY.chunk.js";import"./BDviDDog.chunk.js";import"./wCY37Ze3.chunk.js";import"./CIN5bTKK.chunk.js";import"./DAIetGMf.chunk.js";import"./TReHo2Ua.chunk.js";import"./Bj7bJt_4.chunk.js";import"./CGYNvpr2.chunk.js";import"./U4M4wGTR.chunk.js";import"./Bw9otuBi.chunk.js";import"./BvnABNse.chunk.js";import"./Bh7bFXwG.chunk.js";import"./DCdUbbLx.chunk.js";import"./t24_x3Gi.chunk.js";import"./DwDhXSrj.chunk.js";import"./CCtuxSlD.chunk.js";import"./CPXlV0fg.chunk.js";import"./ApI7cEru.chunk.js";import"./DXxHdeNz.chunk.js";import"./CpGXOT1_.chunk.js";import"./DkDkjje4.chunk.js";import"./hKqzfsO4.chunk.js";import"./fstW5ZQE.chunk.js";import"./9ls1F1Ve.chunk.js";import"./DRKUY7jf.chunk.js";const j="settings.noItemsEmptyState";function Q(){return e.jsxs(t,{children:[e.jsx(t.Image,{src:S.EmptyStates.ContentReview.NO_ITEMS,size:"small"}),e.jsx(t.Heading,{children:e.jsx(i,{namespace:j,phrase:"heading"})}),e.jsx(t.Info,{children:e.jsx(i,{namespace:j,phrase:"info"})})]})}const o="settings.turnedOffEmptyState",W=R.encloseNamespace(o);function X(){const n=A.getLiteArticle(V.ContentReview);return e.jsxs(t,{children:[e.jsx(t.Image,{src:S.EmptyStates.ContentReview.TURNED_OFF,size:"small"}),e.jsx(t.Heading,{children:e.jsx(i,{namespace:o,phrase:"heading"})}),e.jsxs(t.Info,{children:[e.jsx(i,{namespace:o,phrase:"info"})," ",e.jsx(v,{className:"info-link",appLink:{application:m.SETTINGS,action:p.Settings.CONTENT_REVIEW_SETTINGS},children:e.jsx(i,{namespace:o,phrase:"contentReviewSettings"})})]}),e.jsx(t.Cta,{href:n,text:W("learnMore"),className:"btn btn-link info-link"})]})}const c="settings.contentReview",r=R.encloseNamespace(c);function We(n){C({title:r("pageTitle")});const{commonVideoProps:E}=U({locationContext:I.VideoThumbnail}),s=h(z.getRestrictedObjects([f.Custom],n.cursor)),l=h(D.getLibraryReviewPeriod()),L=F({location:M.VideoItem,presentationSlug:null}),{hasPermissions:N}=b(),P=s.hasCompleted&&l.hasCompleted;return e.jsxs(B,{heading:r("heading"),breadcrumbs:[r("heading")],requiredPermissions:w.ManageVideoAccess,children:[e.jsx($,{active:"content-review"}),(()=>{var d,u,x,g;return P?(d=l.data)!=null&&d.reviewPeriod?(x=(u=s.data)==null?void 0:u.data)!=null&&x.length?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"d-flex justify-content-between mb-2",children:[e.jsx("p",{className:"h4",children:e.jsx(i,{namespace:c,phrase:"count",options:{smartCount:s.data.count}})}),e.jsx(v,{appLink:{application:m.SETTINGS,action:p.Settings.APPROVE_ALL_VIDEOS},className:"btn btn-dark",children:e.jsx(i,{namespace:c,phrase:"approveAll"})})]}),e.jsx("hr",{}),e.jsx(G.Provider,{value:L,children:e.jsx(q,{videos:s.data.data.filter(a=>!!O.getRestrictionByType(a._restrictions,f.Custom)),getVideoAppLink:(a,T)=>k.getAppLink(a,T,null),hasPermissions:N,presentationAudiences:[],getPreviewQuestionsAppLink:a=>y.getPreviewQuestionsAppLink(a),commonVideoProps:E})}),((g=s.data.pagination)==null?void 0:g.cursors)&&e.jsx("div",{className:"clearfix",children:e.jsx(_,{cursors:s.data.pagination.cursors,appLink:{application:m.SETTINGS,action:p.Settings.CONTENT_REVIEW},buttonVariant:"outline-dark",className:"py-2 float-end"})})]}):e.jsx(Q,{}):e.jsx(X,{}):e.jsx(H,{})})()]})}export{We as ContentReviewView};
//# sourceMappingURL=BAEVY7iZ.chunk.js.map
