import{aL as f,u as j,bZ as g,R as t,w as G,j as e,bA as v,b7 as a,ao as b,F as y}from"./app-BgLa5dit.js";import{W as A}from"./MEkA24R1.chunk.js";import{B as C}from"./DlnxdFKU.chunk.js";const u="userManager.bulkUserActionsYearGroupRolloverActionDetails";function Y(s){var c;const n=f.getValidYearGroups(s.yearGroups),[r,i]=j(g.BULK_USER_ACTIONS),[l,p]=t.useState(!1),{setDisableNext:d}=t.useContext(A);t.useEffect(()=>{d(!(r!=null&&r.yearGroup)||!l)},[l,r==null?void 0:r.yearGroup]),t.useEffect(()=>{i("yearGroup",G.last(n)),i("subAction","yearGroupRollover")},[]);function m(o){const{value:x}=o.target;i("yearGroup",n.find(h=>h.value.toString()===x.toString()))}return e.jsxs(v.Provider,{value:u,children:[e.jsx("h2",{className:"h4 mb-3",children:e.jsx(a,{phrase:"heading"})}),e.jsxs("div",{className:"px-2 pt-2 border rounded mb-2 pb-0",children:[e.jsxs("ul",{className:"mt-2 ps-3 ms-1",children:[e.jsx("li",{children:e.jsx(a,{phrase:"info"})}),e.jsxs("li",{children:[e.jsx(a,{phrase:"ssoWarning"})," ",!!s.editSsoHelpArticleUrl&&e.jsx("a",{href:s.editSsoHelpArticleUrl,target:"_blank",className:"info-link",children:e.jsx(a,{phrase:"ssoWarningArticle"})})]}),e.jsx("li",{className:"text-danger",children:e.jsx(a,{phrase:"infoWarning"})})]}),e.jsxs("div",{className:"form-group",children:[e.jsx("label",{children:e.jsx(a,{phrase:"label"})}),e.jsx("select",{className:"form-select form-select-lg w-33",onChange:m,value:((c=r.yearGroup)==null?void 0:c.value)||"",children:n.map(o=>e.jsx("option",{value:o.value,className:"text-dark",children:o.name},o.id))})]}),e.jsx(C,{yearGroups:s.yearGroups,graduatingYearGroup:r.yearGroup,countsByYearGroup:s.countsByYearGroup}),e.jsx(b.Check,{className:"my-3",type:"checkbox",label:y.getPhrase(u,"rolloverConfirmationLabel"),id:"rolloverConfirmation",value:"rolloverConfirmation",onChange:()=>p(!l),checked:l})]})]})}export{Y as B};
//# sourceMappingURL=S-UysoQB.chunk.js.map
