(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,77071,e=>{"use strict";let a=(0,e.i(56420).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",0,a],77071)},95187,(e,a,l)=>{"use strict";Object.defineProperty(l,"__esModule",{value:!0});var r={callServer:function(){return t.callServer},createServerReference:function(){return s.createServerReference},findSourceMapURL:function(){return i.findSourceMapURL}};for(var n in r)Object.defineProperty(l,n,{enumerable:!0,get:r[n]});let t=e.r(32120),i=e.r(92245),s=e.r(35326)},81814,e=>{"use strict";var a=e.i(43476),l=e.i(71645),r=e.i(77071),n=e.i(38286),t=e.i(19367),i=e.i(95187);let s=(0,i.createServerReference)("40a752b6a8d7bd9f33920cc02b41e80002e5e4ebec",i.callServer,void 0,i.findSourceMapURL,"createCreator");function u({creator:e,managers:l,teams:r}){return(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,a.jsx)(n.Field,{label:"Prénom",required:!0,children:(0,a.jsx)(n.Input,{name:"firstName",defaultValue:e?.firstName,required:!0})}),(0,a.jsx)(n.Field,{label:"Nom",required:!0,children:(0,a.jsx)(n.Input,{name:"lastName",defaultValue:e?.lastName,required:!0})}),(0,a.jsx)(n.Field,{label:"Pseudonyme",required:!0,children:(0,a.jsx)(n.Input,{name:"pseudo",defaultValue:e?.pseudo,required:!0})}),(0,a.jsx)(n.Field,{label:"Email",children:(0,a.jsx)(n.Input,{name:"email",type:"email",defaultValue:e?.email??""})}),(0,a.jsx)(n.Field,{label:"Téléphone",children:(0,a.jsx)(n.Input,{name:"phone",defaultValue:e?.phone??""})}),(0,a.jsx)(n.Field,{label:"Pays",children:(0,a.jsx)(n.Input,{name:"country",defaultValue:e?.country??""})}),(0,a.jsx)(n.Field,{label:"Langues",children:(0,a.jsx)(n.Input,{name:"languages",placeholder:"FR, EN…",defaultValue:e?.languages??""})}),(0,a.jsx)(n.Field,{label:"Date d'entrée",children:(0,a.jsx)(n.Input,{name:"entryDate",type:"date",defaultValue:e?.entryDate?e.entryDate.toISOString().slice(0,10):""})}),(0,a.jsx)(n.Field,{label:"Statut",required:!0,children:(0,a.jsxs)(n.Select,{name:"status",defaultValue:e?.status??"CANDIDAT",children:[(0,a.jsx)("option",{value:"CANDIDAT",children:"Candidat"}),(0,a.jsx)("option",{value:"INTEGRATION",children:"Intégration"}),(0,a.jsx)("option",{value:"ACTIF",children:"Actif"}),(0,a.jsx)("option",{value:"INACTIF",children:"Inactif"}),(0,a.jsx)("option",{value:"SUSPENDU",children:"Suspendu"}),(0,a.jsx)("option",{value:"SORTI",children:"Sorti"})]})}),(0,a.jsx)(n.Field,{label:"Manager attitré",children:(0,a.jsxs)(n.Select,{name:"managerId",defaultValue:e?.managerId??"AUCUN",children:[(0,a.jsx)("option",{value:"AUCUN",children:"— Aucun —"}),l.map(e=>(0,a.jsx)("option",{value:e.id,children:e.label},e.id))]})}),(0,a.jsx)(n.Field,{label:"Équipe",children:(0,a.jsxs)(n.Select,{name:"teamId",defaultValue:e?.teamId??"AUCUN",children:[(0,a.jsx)("option",{value:"AUCUN",children:"— Aucune —"}),r.map(e=>(0,a.jsx)("option",{value:e.id,children:e.label},e.id))]})}),(0,a.jsx)(n.Field,{label:"Score (sur 100)",hint:"Scoring candidat interne",children:(0,a.jsx)(n.Input,{name:"score",type:"number",min:0,max:100,defaultValue:e?.score??""})}),(0,a.jsx)("div",{className:"col-span-2",children:(0,a.jsx)(n.Field,{label:"Notes internes",children:(0,a.jsx)(n.Textarea,{name:"notes",defaultValue:e?.notes??""})})})]})}e.s(["NewCreatorButton",0,function({managers:e,teams:i,secondary:d,label:c}){let[o,p]=(0,l.useState)(!1);return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(n.Button,{variant:d?"secondary":"primary",onClick:()=>p(!0),children:[(0,a.jsx)(r.Plus,{className:"h-4 w-4"})," ",c??"Nouveau créateur"]}),(0,a.jsx)(t.Modal,{open:o,onClose:()=>p(!1),title:"Nouveau créateur",wide:!0,children:(0,a.jsxs)("form",{action:s,className:"space-y-4",children:[(0,a.jsx)(u,{managers:e,teams:i}),(0,a.jsxs)("div",{className:"flex justify-end gap-2 border-t border-ink-700 pt-4",children:[(0,a.jsx)(n.Button,{type:"button",variant:"ghost",onClick:()=>p(!1),children:"Annuler"}),(0,a.jsx)(n.Button,{type:"submit",children:"Créer le créateur"})]})]})})]})}],81814)}]);