PageSourceSearch

https://osirus.ai/_next/static/chunks/pages/users/[userId]/[name]-6133c70c169f3be0.js

js osirus.ai collected 2026-10-05 12:25:35 UTC 38,223 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[551],{3336:(e,s,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/users/[userId]/[name]",function(){return a(29808)}])},9114:(e,s,a)=>{"use strict";a.d(s,{C:()=>x});var l=a(37876),i=a(14232),r=a(42445),t=a(22426),n=a(17961),o=a(6078),d=a(84275),c=a(4301),m=a(91291),f=a(47701);let x=({isOpen:e,onClose:s,titleOverride:a,entityDescription:x,descriptionOverride:u,mainActionLabelOverride:p="Delete",skipActionLabelOverride:h="Cancel",onDelete:j})=>{let g=(0,i.useRef)(null),[b,N]=(0,i.useState)(!1),v=async()=>{try{N(!0),await j(),N(!1),s()}catch(e){N(!1),c.oR.error(f.Rb)}};return(0,l.jsx)(r.Lt,{isOpen:e,leastDestructiveRef:g,onClose:s,isCentered:!0,children:(0,l.jsx)(t.m,{className:"dialog",children:(0,l.jsx)(r.EO,{children:(0,l.jsxs)("div",{className:"text-center",children:[(0,l.jsx)(n.r,{children:a||`Delete "${x}"`}),(0,l.jsx)(o.c,{children:u||"You cannot undo this action."}),(0,l.jsxs)(d.j,{className:"d-flex justify-content-center gap-3",children:[(0,l.jsx)(m.A,{className:"me-2",ariaLabel:"Close Delete Dialog",buttonRef:g,onClick:s,children:h}),(0,l.jsx)(m.A,{className:"text-white",ariaLabel:`Delete ${x}`,color:"danger",onClick:v,isLoading:b,disabled:b,children:p})]})]})})})})}},18387:(e,s,a)=>{"use strict";a.d(s,{I:()=>d});var l=a(37876),i=a(75255),r=a(89461),t=a(28913),n=a(8519);let o={path:(0,l.jsxs)("g",{stroke:"currentColor",strokeWidth:"1.5",children:[(0,l.jsx)("path",{strokeLinecap:"round",fill:"none",d:"M9,9a3,3,0,1,1,4,2.829,1.5,1.5,0,0,0-1,1.415V14.25"}),(0,l.jsx)("path",{fill:"currentColor",strokeLinecap:"round",d:"M12,17.25a.375.375,0,1,0,.375.375A.375.375,0,0,0,12,17.25h0"}),(0,l.jsx)("circle",{fill:"none",strokeMiterlimit:"10",cx:"12",cy:"12",r:"11.25"})]}),viewBox:"0 0 24 24"},d=(0,r.R)((e,s)=>{let{as:a,viewBox:r,color:d="currentColor",focusable:c=!1,children:m,className:f,__css:x,...u}=e,p=(0,i.cx)("chakra-icon",f),h=(0,t.V)("Icon",e),j={ref:s,focusable:c,className:p,__css:{w:"1em",h:"1em",display:"inline-block",lineHeight:"1em",flexShrink:0,color:d,...x,...h}},g=r??o.viewBox;if(a&&"string"!=typeof a)return(0,l.jsx)(n.B.svg,{as:a,...j,...u});let b=m??o.path;return(0,l.jsx)(n.B.svg,{verticalAlign:"middle",viewBox:g,...j,...u,children:b})});d.displayName="Icon"},24306:(e,s,a)=>{"use strict";a.d(s,{D:()=>x});var l=a(37876),i=a(75255),r=a(59035),t=a(89461),n=a(8519);let o=(0,t.R)((e,s)=>{let a=(0,r.$)();return(0,l.jsx)(n.B.span,{ref:s,...e,__css:a.command,className:"chakra-menu__command"})});o.displayName="MenuCommand";var d=a(14232);let c=e=>{let{className:s,children:a,...t}=e,o=(0,r.$)(),c=d.Children.only(a),m=(0,d.isValidElement)(c)?(0,d.cloneElement)(c,{focusable:"false","aria-hidden":!0,className:(0,i.cx)("chakra-menu__icon",c.props.className)}):null,f=(0,i.cx)("chakra-menu__icon-wrapper",s);return(0,l.jsx)(n.B.span,{className:f,...t,__css:o.icon,children:m})};c.displayName="MenuIcon";let m=(0,t.R)((e,s)=>{let{type:a,...i}=e,t=(0,r.$)(),o=i.as||a?a??void 0:"button",c=(0,d.useMemo)(()=>({textDecoration:"none",color:"inherit",userSelect:"none",display:"flex",width:"100%",alignItems:"center",textAlign:"start",flex:"0 0 auto",outline:0,...t.item}),[t.item]);return(0,l.jsx)(n.B.button,{ref:s,type:o,...i,__css:c})});var f=a(90695);let x=(0,t.R)((e,s)=>{let{icon:a,iconSpacing:r="0.75rem",command:t,commandSpacing:n="0.75rem",children:d,...x}=e,u=(0,f.Os)(x,s),p=a||t?(0,l.jsx)("span",{style:{pointerEvents:"none",flex:1},children:d}):d;return(0,l.jsxs)(m,{...u,className:(0,i.cx)("chakra-menu__menuitem",u.className),children:[a&&(0,l.jsx)(c,{fontSize:"0.8em",marginEnd:r,children:a}),p,t&&(0,l.jsx)(o,{marginStart:n,children:t})]})});x.displayName="MenuItem"},25018:(e,s,a)=>{"use strict";a.d(s,{z:()=>g});var l=a(37876),i=a(75255),r=a(62897),t=a(10184),n=a(42205),o=a(75784),d=a(38581),c=a(14232),m=a(76835);let f={exit:{duration:.15,ease:m.xf.easeInOut},enter:{type:"spring",damping:25,stiffness:180}},x={exit:({direction:e,transition:s,transitionEnd:a,delay:l})=>{let{exit:i}=(0,m.Jv)({direction:e});return{...i,transition:s?.exit??m.yA.exit(f.exit,l),transitionEnd:a?.exit}},enter:({direction:e,transitionEnd:s,transition:a,delay:l})=>{let{enter:i}=(0,m.Jv)({direction:e});return{...i,transition:a?.enter??m.yA.enter(f.enter,l),transitionEnd:s?.enter}}},u=(0,c.forwardRef)(function(e,s){let{direction:a="right",style:r,unmountOnExit:t,in:n,className:c,transition:f,transitionEnd:u,delay:p,motionProps:h,animatePresenceProps:j,...g}=e,b=Object.assign({position:"fixed"},(0,m.Jv)({direction:a}).position,r),N=!t||n&&t,v=n||t?"enter":"exit",y={transitionEnd:u,transition:f,direction:a,delay:p};return(0,l.jsx)(o.N,{...j,custom:y,children:N&&(0,l.jsx)(d.P.div,{...g,ref:s,initial:"exit",className:(0,i.cx)("chakra-sli
1de",c),animate:v,exit:"exit",custom:y,variants:x,style:b,...h})})});u.displayName="Slide";var p=a(8519),h=a(89461);let j=(0,p.B)(u),g=(0,h.R)((e,s)=>{let{className:a,children:o,motionProps:d,containerProps:c,...m}=e,{getDialogProps:f,getDialogContainerProps:x,isOpen:u}=(0,t.k3)(),h=f(m,s),g=x(c),b=(0,i.cx)("chakra-modal__content",a),N=(0,t.x5)(),v={display:"flex",flexDirection:"column",position:"relative",width:"100%",outline:0,...N.dialog},y={display:"flex",width:"100vw",height:"$100vh",position:"fixed",left:0,top:0,...N.dialogContainer},{placement:w}=(0,r.gJ)();return(0,l.jsx)(n.u,{children:(0,l.jsx)(p.B.div,{...g,className:"chakra-modal__content-container",__css:y,children:(0,l.jsx)(j,{motionProps:d,direction:w,in:u,className:b,...h,__css:v,children:o})})})});g.displayName="DrawerContent"},26970:(e,s,a)=>{"use strict";a.d(s,{s:()=>u});var l=a(37876),i=a(75255),r=a(57396),t=a(10184),n=a(29185),o=a(18387),d=a(89461),c=a(28913),m=a(8519);function f(e){return(0,l.jsx)(o.I,{focusable:"false","aria-hidden":!0,...e,children:(0,l.jsx)("path",{fill:"currentColor",d:"M.439,21.44a1.5,1.5,0,0,0,2.122,2.121L11.823,14.3a.25.25,0,0,1,.354,0l9.262,9.263a1.5,1.5,0,1,0,2.122-2.121L14.3,12.177a.25.25,0,0,1,0-.354l9.263-9.262A1.5,1.5,0,0,0,21.439.44L12.177,9.7a.25.25,0,0,1-.354,0L2.561.44A1.5,1.5,0,0,0,.439,2.561L9.7,
111.823a.25.25,0,0,1,0,.354Z"})})}let x=(0,d.R)(function(e,s){let a=(0,c.V)("CloseButton",e),{children:i,isDisabled:r,__css:t,...o}=(0,n.M)(e);return(0,l.jsx)(m.B.button,{type:"button","aria-label":"Close",ref:s,disabled:r,__css:{outline:0,display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,...a,...t},...o,children:i||(0,l.jsx)(f,{width:"1em",height:"1em"})})});x.displayName="CloseButton";let u=(0,d.R)((e,s)=>{let{onClick:a,className:n,...o}=e,{onClose:d}=(0,t.k3)(),c=(0,i.cx)("chakra-modal__close-btn",n),m=(0,t.x5)();return(0,l.jsx)(x,{ref:s,__css:m.closeButton,className:c,onClick:(0,r.H)(a,e=>{e.stopPropagation(),d()}),...o})});u.displayName="ModalCloseButton"},29808:(e,s,a)=>{"use strict";a.r(s),a.d(s,{__N_SSP:()=>ea,default:()=>el});var l=a(37876),i=a(94208),r=a.n(i),t=a(48230),n=a.n(t),o=a(89099),d=a(14232),c=a(24836),m=a(59035),f=a(11626),x=a(50485),u=a(13642),p=a(24306),h=a(76629),j=a(60685),g=a(9114),b=a(62897),N=a(22426),v=a(25018),y=a(26970),w=a(17961),k=a(6078),C=a(84275),A=a(49034),_=a(88992),I=a(4301),M=a(59586),R=a(36074),z=a(92660),S=a(91291),$=a(31480),L=a(15212),B=a(87186),E=a(10110),O=a(5960),U=a(47701),D=a(97085);let P=({user:e,align:s="start"})=>(0,l.jsxs)("div",{className:`d-flex flex-wrap gap-2 justify-content-${s} align-items-center`,children:[e.systemRole===M.G6.admin&&(0,l.jsx)(D.A,{bgColor:"secondary",textColor:"white",label:"Admin"}),e.systemRole===M.G6.editor&&(0,l.jsx)(D.A,{bgColor:"warning",textColor:"black",label:"Staff"}),e.isVerified&&(0,l.jsx)(D.A,{bgColor:"success",textColor:"white",label:"Verified"})]}),F=Object.values(A.Ay.getAllTimezones()).map(e=>({value:e.name,label:e.name})).sort((e,s)=>e.label.localeCompare(s.label)),V=({user:e,isOpen:s,onClose:a,canEditDetails:i=!1,showAdminSettings:r=!0})=>{let[t,{isLoading:n}]=(0,R.H7)(),[o]=(0,R.hT)(),{register:c,handleSubmit:m,reset:f,control:x,getValues:u,formState:{errors:p}}=(0,_.mN)({defaultValues:{firstName:e.firstName||"",lastName:e.lastName||"",email:e.email||"",bio:e.bio||"",timezone:e.timezone||e.timeZone||"",systemRole:e.systemRole||"null"}});(0,d.useEffect)(()=>{f({firstName:e.firstName||"",lastName:e.lastName||"",email:e.email||"",bio:e.bio||"",timezone:e.timezone||e.timeZone||"",systemRole:e.systemRole||"null"})},[e,f]);let h=async s=>{if(i)try{let l={id:e.id,firstName:s.firstName,lastName:s.lastName,email:e.email,bio:s.bio,timezone:s.timezone};await t(l).unwrap(),I.oR.success("User details updated successfully"),a()}catch(e){I.oR.error(e?.data?.message||U.Rb)}},j=({label:e,value:s})=>(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)("strong",{className:"small",children:[e,": "]}),(0,l.jsx)("span",{className:"d-block",children:s||"Not Defined"})]});return(0,l.jsxs)(b._s,{isOpen:s,onClose:a,size:"xl",children:[(0,l.jsx)(N.m,{}),(0,l.jsxs)(v.z,{className:"drawer",children:[(0,l.jsx)(y.s,{}),(0,l.jsx)(w.r,{children:i?"Modify":`User: ${e.name}`}),(0,l.jsx)(k.c,{children:(0,l.jsxs)("div",{className:"mt-3",children:[!i&&(0,l.jsxs)("div",{className:"d-md-flex gap-3 align-items-center",children:[(0,l.jsx)(z.p,{src:e.profileMedia?.media.sourceUrl||O.xH,alt:e.profileMedia?.media.details?.altText||"",width:100,height:100,className:"object-fit-cover rounded-pill"}),(0,l.jsxs)("div",{children:[e.firstName&&(0,l.jsxs)("h2",{className:"h5 mb-0 mt-2 mt-md-0",children:[e.firstName," ",e.lastName]}),(0,l.jsx)("div",{className:"mt-2 w-md-450p",children:(0,l.jsx)(P,{user:e})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Joined On",value:(0,E.dD)(e.createdAt||"")})})]})]}),r&&(0,l.jsxs)("div",{children:[(0,l.jsx)("h2",{className:"h5 mt-5",children:"Settings"}),(0,l.jsx)("hr",{className:"text-light-gray opacity-100"}),(0,l.jsx)("div",{className:"mt-4 form w-100 w-lg-50",children:(0,l.jsx)(L.A,{register:c("systemRole"),label:"System Role",options:[{label:"None",value:"null"},{label:"Editor",value:M.G6.editor},{label:"Admin",value:M.G6.admin}],onSelectChange:s=>{let a=s?.toString();o({payload:{id:e.id,systemRole:"null"===a?null:a}})},control:x,getValues:u,errors:p})})]}),i?(0,l.jsxs)("form",{id:"update-user-details-form",onSubmit:m(h),children:[(0,l.jsxs)("div",{className:"row gx-4 mt-4",children:[(0,l.jsx)("div",{className:"col-lg-6",children:(0,l.jsx)($.A,{register:c("firstName"),errors:p,placeholder:"Enter first name",label:"First Name",getValues:u})}),(0,l.jsx)("div",{className:"col-lg-6 mt-4 mt-lg-0",children:(0,l.jsx)($.A,{register:c("lastName"),errors:p,placeholder:"Enter last name",label:"Last Name",getValues:u})})]}),(0,l.jsx)("div",{className:"mt-4",children:(0,l.jsx)($.A,{register:c("email"),errors:p,type:"email",placeholder:"Email address",label:"Email Address",getValues:u,readOnly:!0,appendInput:(0,l.jsx)("span",{className:"bi bi-lock text-muted","aria-hidden":"true"})})}),(0,l.jsx)("div",{className:"mt-4",children:(0,l.jsx)(L.A,{register:c("timezone"),label:"Timezone",options:[{value:"",label:"Select timezone"},...F],control:x,getValues:u,setFirstAsDefault:!1,errors:p})}),(0,l.jsx)("div",{className:"mt-4",children:(0,l.jsx)(B.A,{register:c("bio"),errors:p,placeholder:"Enter bio",label:"Bio",getValues:u,rows:5})})]}):(0,l.jsxs)("div",{children:[(0,l.jsx)("h2",{className:"h5 mt-5",children:"Info"}),(0,l.jsx)("hr",{className:"text-light-gray opacity-100"}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Username",value:e.name})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Email",value:e.email})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"First Name",value:e.firstName})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Last Name",value:e.lastName})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Short Bio",value:e.shortBio})}),(0,l.jsx)("h2",{className:"h5 mt-5",children:"Social Media"}),(0,l.jsx)("hr",{className:"text-light-gray opacity-100"}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"X",value:e.twitterUsername})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Instagram",value:e.instagramUsername})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"LinkedIn",value:e.linkedinUsername})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Site URL",value:e.siteUrl})}),(0,l.jsx)("h2",{className:"h5 mt-5",children:"Address"}),(0,l.jsx)("hr",{className:"text-light-gray opacity-100"}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Stree Address",value:e.address?.streetAddress})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"City",value:e.address?.city})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"State",value:e.address?.state})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Postal Code",value:e.address?.postalCode})}),(0,l.jsx)("div",{className:"mt-2",children:(0,l.jsx)(j,{label:"Country",value:e.address?.country})})]})]})}),i&&(0,l.jsxs)(C.j,{children:[(0,l.jsx)(S.A,{onClick:a,disabled:n,children:"Cancel"}),(0,l.jsx)(S.A,{type:"submit",form:"update-user-details-form",color:"primary",className:"text-white",isLoading:n,disabled:n,children:"Save"})]})]})]})};var T=a(43196);let G=["admin","editor","viewer","none","custom"],J=e=>"none"===e?"No access":e.charAt(0).toUpperCase()+e.slice(1),K=({userId:e,isOpen:s,onClose:a})=>{let{data:i,isFetching:r}=(0,R.X0)({userId:e},{skip:!s}),[t,{isLoading:n}]=(0,R.$L)(),[o,c]=(0,d.useState)((0,T.GE)());(0,d.useEffect)(()=>{c((0,T.o8)(i?.directPermissions??[]))},[i]);let m=async()=>{let s=(0,T.Y8)(e,o);await t({userId:e,permissions:s}).unwrap(),a()},f=(0,d.useMemo)(()=>T.Lf.map(e=>({key:e.key,label:e.label,role:o.apps?.[e.key]?.role??"none"})),[o]);return(0,l.jsxs)(b._s,{isOpen:s,onClose:a,size:"xl",children:[(0,l.jsx)(N.m,{}),(0,l.jsxs)(v.z,{className:"drawer",children:[(0,l.jsx)(y.s,{}),(0,l.jsx)(w.r,{children:"User Permissions"}),(0,l.jsx)(k.c,{children:(0,l.jsxs)("div",{className:"d-flex flex-column gap-4",children:[(0,l.jsx)("div",{className:"d-flex flex-wrap gap-3",children:f.map(e=>(0,l.jsxs)("span",{className:"badge rounded-pill bg-light text-dark border",children:[e.label,": ",J(e.role)]},e.key))}),T.Lf.map(s=>{let a=o.apps?.[s.key];return(0,l.jsxs)("div",{className:"border rounded-3 p-3",children:[(0,l.jsxs)("div",{className:"d-flex justify-content-between align-items-center",children:[(0,l.jsx)("h5",{className:"mb-0",children:s.label}),(0,l.jsx)("select",{className:"form-select form-select-sm w-auto",value:a?.role??"none",onChange:a=>{var l,i;return l=s.key,i=a.target.value,void c(s=>
1{let a=(0,T.o8)((0,T.Y8)(e,s)),r=T.os[i]??T.os.none;if(a.apps[l]={...a.apps[l],role:i,actions:{...r}},a.apps[l].special){let e="admin"===i?Object.keys(a.apps[l].special||{}).reduce((e,s)=>(e[s]=!0,e),{}):Object.keys(a.apps[l].special||{}).reduce((e,s)=>(e[s]=!1,e),{});a.apps[l].special=e}return a})},children:G.map(e=>(0,l.jsx)("option",{value:e,children:J(e)},e))})]}),(0,l.jsxs)("div",{className:"mt-3",children:[(0,l.jsx)("div",{className:"small fw-semibold text-uppercase text-muted mb-2",children:"CRUD Actions"}),(0,l.jsx)("div",{className:"d-flex flex-wrap gap-3",children:s.actions.map(i=>(0,l.jsxs)("label",{className:"form-check form-check-inline m-0",children:[(0,l.jsx)("input",{className:"form-check-input",type:"checkbox",checked:!!a?.actions?.[i],onChange:()=>{var a;return a=s.key,void c(s=>{let l=(0,T.o8)((0,T.Y8)(e,s)),r=!!l.apps[a].actions[i];return l.apps[a].actions[i]=!r,l.apps[a].role=(0,T.aW)(l.apps[a].actions),l})}}),(0,l.jsx)("span",{className:"form-check-label text-capitalize",children:i})]},i))})]}),s.special&&(0,l.jsxs)("div",{className:"mt-3",children:[(0,l.jsx)("div",{className:"small fw-semibold text-uppercase text-muted mb-2",children:"Special"}),(0,l.jsx)("div",{className:"d-flex flex-column gap-2",children:s.special.map(i=>(0,l.jsxs)("label",{className:"form-check form-check-inline m-0",children:[(0,l.jsx)("input",{className:"form-check-input",type:"checkbox",checked:!!a?.special?.[i.key],onChange:()=>{var a,l;return a=s.key,l=i.key,void c(s=>{let i=(0,T.o8)((0,T.Y8)(e,s));i.apps[a].special||(i.apps[a].special={});let r=!!i.apps[a].special?.[l];return i.apps[a].special[l]=!r,i})}}),(0,l.jsx)("span",{className:"form-check-label",children:i.label})]},i.key))})]})]},s.key)}),(0,l.jsxs)("div",{className:"d-flex justify-content-end gap-2",children:[(0,l.jsx)("button",{type:"button",className:"btn btn-outline-secondary",onClick:a,disabled:n||r,children:"Cancel"}),(0,l.jsx)("button",{type:"button",className:"btn btn-primary",onClick:m,disabled:n||r,children:n?"Saving...":"Save"})]})]})})]})]})};var X=a(71060),Y=a(6063),Z=a(51041),H=a(4847),W=a(59439),q=a(79641);let Q=e=>(0,Y.cD)(e)||e.name||e.email||e.id,ee=e=>e?.trim()||"",es=e=>Q(e).split(/\s+/).filter(Boolean).slice(0,2).map(e=>e.charAt(0).toUpperCase()).join("");var ea=!0;let el=(0,j.A)(({initialUser:e})=>{let s=(0,o.useRouter)(),a=(0,H.j)(),{user:i,activeOrgId:t}=(0,Z.gZ)(),{isOpen:j,onOpen:b,onClose:N}=(0,c.j)(),{isOpen:v,onOpen:y,onClose:w}=(0,c.j)(),{isOpen:k,onOpen:C,onClose:A}=(0,c.j)(),[_]=(0,q.n_)(),I="string"==typeof s.query.userId?s.query.userId:e?.id,{data:z}=(0,R.Nj)({idOrName:I||""},{skip:!I}),{data:S}=(0,R.X0)({userId:I||""},{skip:!I}),$=z||e,L=(0,d.useMemo)(()=>t&&$.orgMemberships?.find(e=>e.orgId===t)||null,[t,$.orgMemberships]),B=(0,d.useMemo)(()=>Q($),[$]),O=(0,d.useMemo)(()=>ee($.timezone)||ee($.timeZone),[$.timeZone,$.timezone]),U=(0,d.useMemo)(()=>{let e=t?$.orgMemberships?.find(e=>e.orgId===t):null,s=ee($.jobTitle)||ee($.title),a=ee(e?.org?.name);return[s?{icon:"bi bi-briefcase-fill",value:s}:null,a?{icon:"bi bi-house-fill",value:a}:null].filter(e=>!!e)},[t,$]),D=(0,d.useMemo)(()=>{let e=new Map;for(let s of $.orgMemberships||[]){let a=s.group;for(let l of(a?.id&&e.set(a.id,a),s.groups||[]))l?.id&&e.set(l.id,l)}return Array.from(e.values()).sort((e,s)=>e.name.localeCompare(s.name))},[$.orgMemberships]),P=(0,d.useMemo)(()=>(0,T.o8)(S?.permissions||$.permissions||[]),[S?.permissions,$.permissions]),F=(0,d.useMemo)(()=>T.Lf.map(e=>({...e,role:P.apps?.[e.key]?.role??"none"})).filter(e=>"none"!==e.role),[P]),G=(0,d.useMemo)(()=>{if(!i)return!1;if(i.systemRole===M.G6.admin)return!0;if(!t)return!1;let e=(i.orgMemberships||[]).find(e=>e.orgId===t)||null;return e?.role==="admin"||e?.org?.ownerId===i.id||(i.permissions||[]).some(e=>e.orgId===t&&"users"===e.appKey&&"permissions.update"===e.action&&!0===e.allowed)},[t,i]),J=(0,d.useMemo)(()=>{if(!i)return!1;if(i.id===$.id||i.systemRole===M.G6.admin)return!0;if(!t)return!1;let e=(i.orgMemberships||[]).find(e=>e.orgId===t)||null;return e?.role==="admin"||e?.org?.ownerId===i.id||(i.permissions||[]).some(e=>e.orgId===t&&"users"===e.appKey&&"update"===e.action&&!0===e.allowed)},[t,i,$.id]),Y=(0,d.useMemo)(()=>
1{if(!i?.id||!L?.id||L.org?.ownerId&&L.org.ownerId===$.id)return!1;let e=(i.orgMemberships||[]).find(e=>e.orgId===(t||""))||null;return L.org?.ownerId===i.id||e?.role==="admin"||(i.permissions||[]).some(e=>e.orgId===(t||"")&&"users"===e.appKey&&"delete"===e.action&&!0===e.allowed)},[t,i,L,$.id]),ea=async()=>{t&&L?.id&&(await _({orgId:t,membershipId:L.id}).unwrap(),a(R.uK.util.invalidateTags(["LocalUsers"])),s.push("/users"))};return I?(0,l.jsxs)(h.A,{useMainContentAreaId:!1,sidebarTopContent:()=>(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("h2",{className:"jsx-7e1306ff15781fa6 sidebar-heading",children:"Users"}),(0,l.jsx)("ul",{className:"jsx-7e1306ff15781fa6 sidebar-list mb-5",children:(0,l.jsx)("li",{title:"Back to Users",className:"jsx-7e1306ff15781fa6 sidebar-item",children:(0,l.jsxs)(n(),{href:"/users",className:"sidebar-link",children:[(0,l.jsx)("i",{className:"jsx-7e1306ff15781fa6 bi bi-arrow-left"})," ",(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6",children:"Back"})]})})})]}),renderMainNav:()=>null,children:[(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 group-detail-page",children:[(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 group-detail-header",children:(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 group-detail-title-row",children:[(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 group-detail-identity",children:[(0,l.jsx)("span",{"aria-hidden":"true",className:`jsx-7e1306ff15781fa6 group-initial-avatar group-initial-avatar--lg ${(0,W.fA)(B)} group-detail-avatar`,children:es($)}),(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 group-detail-copy",children:[(0,l.jsxs)("nav",{"aria-label":"Breadcrumb",className:"jsx-7e1306ff15781fa6 group-detail-breadcrumb",children:[(0,l.jsx)(n(),{href:"/users",children:"Users"}),(0,l.jsx)("span",{"aria-hidden":"true",className:"jsx-7e1306ff15781fa6",children:"/"}),(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6 group-detail-name",children:B})]}),(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 group-detail-meta",children:(0,l.jsxs)("span",{className:"jsx-7e1306ff15781fa6",children:[(0,l.jsx)("strong",{className:"jsx-7e1306ff15781fa6",children:"Added:"})," ",(0,E.$6)($.createdAt)]})})]})]}),(J||G||Y)&&(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 group-detail-actions",children:(0,l.jsx)(m.W,{placement:"bottom-end",children:({isOpen:e,onClose:s})=>(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(f.I,{as:x.K,"aria-label":"User actions",className:`btn btn-outline-light-gray d-flex align-items-center justify-content-center no-min-size w-xs-30p h-xs-30p rounded-pill border-0 text-dark ${e?"bg-light-gray":""}`,icon:(0,l.jsx)("span",{"aria-hidden":"true",className:"jsx-7e1306ff15781fa6 bi bi-three-dots-vertical fs-5"})}),(0,l.jsxs)(u.c,{className:"bg-white p-1 shadow rounded-md menu-list-container group-detail-menu-list",children:[J&&(0,l.jsx)(p.D,{className:"border-0 bg-white bg-hover-background rounded-md px-3 group-detail-menu-item",icon:(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6 bi bi-pencil-square"}),onClick:()=>{s(),y()},children:"Modify"}),G&&(0,l.jsx)(p.D,{className:"border-0 bg-white bg-hover-background rounded-md px-3 group-detail-menu-item",icon:(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6 bi bi-shield-lock"}),onClick:()=>{s(),b()},children:"Permissions"}),Y&&(0,l.jsx)(p.D,{className:"border-0 bg-white bg-hover-background rounded-md px-3 group-detail-menu-item text-danger",icon:(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6 bi bi-trash"}),onClick:()=>{s(),C()},children:"Delete"})]})]})})})]})}),(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-main-grid",children:[(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-left-column",children:[(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-profile-summary-row",children:[(0,l.jsx)("span",{"aria-hidden":"true",className:`jsx-7e1306ff15781fa6 user-detail-profile-avatar ${(0,W.fA)(B)}`,children:es($)}),(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-profile-summary-copy",children:[(0,l.jsx)("strong",{className:"jsx-7e1306ff15781fa6",children:B}),$.email&&(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6",children:$.email})]})]}),(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-info-column",children:[(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 card user-detail-info-card",children:(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 card-body",children:[(0,l.jsx)("h5",{className:"jsx-7e1306ff15781fa6 user-detail-info-card-title",children:"About"}),(0,l.jsx)("p",{className:"jsx-7e1306ff15781fa6 user-detail-info-card-text",children:$.bio?.trim()||"No bio provided yet."}),O&&(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-about-timezone",children:[(0,l.jsx)("i",{"aria-hidden":"true",className:"jsx-7e1306ff15781fa6 bi bi-clock"}),(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6",children:O})]})]})}),!!U.length&&(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 card user-detail-info-card",children:(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 card-body",children:[(0,l.jsx)("h5",{className:"jsx-7e1306ff15781fa6 user-detail-info-card-title",children:"Profile"}),(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 user-detail-profile-list",children:U.map(e=>(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-profile-row",children:[(0,l.jsx)("i",{"aria-hidden":"true",className:"jsx-7e1306ff15781fa6 "+(e.icon||"")}),(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6",children:e.value})]},`${e.icon}-${e.value}`))})]})})]})]}),(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 user-detail-related-column",children:[(0,l.jsxs)("section",{className:"jsx-7e1306ff15781fa6 group-detail-section user-detail-related-section",children:[(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 group-detail-section-header",children:(0,l.jsx)("h2",{className:"jsx-7e1306ff15781fa6",children:"Groups the user is part of"})}),!!D.length&&(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 groups-fullscreen-table user-detail-groups-grid",children:(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 groups-table-shell",children:(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 table-responsive groups-table-scroll custom-scroll-bar",children:(0,l.jsx)("table",{className:"jsx-7e1306ff15781fa6 table align-middle mb-0 groups-table-modern",children:(0,l.jsx)("tbody",{className:"jsx-7e1306ff15781fa6",children:D.map(e=>(0,l.jsx)("tr",{onClick:()=>{s.push(`/groups/${e.id}/${encodeURIComponent((0,X.x)(e.name))}`)},className:"jsx-7e1306ff15781fa6 cursor-pointer",children:(0,l.jsx)("td",{className:"jsx-7e1306ff15781fa6",children:(0,l.jsxs)("div",{className:"jsx-7e1306ff15781fa6 d-flex align-items-center gap-3 min-width-0",children:[(0,l.jsx)(W.rF,{name:e.name,size:"sm"}),(0,l.jsx)("span",{className:"jsx-7e1306ff15781fa6 fw-semibold text-truncate d-block",children:e.name})]})})},e.id))})})})})})]}),(0,l.jsxs)("section",{className:"jsx-7e1306ff15781fa6 group-detail-section group-detail-access-section user-detail-related-section",children:[(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 group-detail-section-header",children:(0,l.jsx)("h2",{className:"jsx-7e1306ff15781fa6",children:"Apps the user has access to"})}),F.length?(0,l.jsx)("div",{className:"jsx-7e1306ff15781fa6 table-responsive",children:(0,l.jsxs)("table",{className:"jsx-7e1306ff15781fa6 table mb-0 group-detail-table",children:[(0,l.jsx)("thead",{className:"jsx-7e1306ff15781fa6",children:(0,l.jsxs)("tr",{className:"jsx-7e1306ff15781fa6",children:[(0,l.jsx)("th",{scope:"col",className:"jsx-7e1306ff15781fa6",children:"App"}),(0,l.jsx)("th",{scope:"col",className:"jsx-7e1306ff15781fa6 group-detail-table-col-access",children:"Access"})]})}),(0,l.jsx)("tbody",{className:"jsx-7e1306ff15781fa6",children:F.map(e=>{let s;return(0,l.jsxs)("tr",{className:"jsx-7e1306ff15781fa6",children:[(0,l.jsx)("td",{className:"jsx-7e1306ff15781fa6 align-middle",children:e.label}),(0,l.jsx)("td",{className:"jsx-7e1306ff15781fa6 align-middle fw-semibold group-detail-access-cell",children:(s=e.role).charAt(0).toUpperCase()+s.slice(1)})]},e.key)})})]})}):G&&(0,l.jsx)("button",{type:"button",onClick:b,className:"jsx-7e1306ff15781fa6 btn btn-primary group-detail-manage-button",children:"Apps"})]})]})]})]}),J&&(0,l.jsx)(V,{user:$,isOpen:v,onClose:w,canEditDetails:!0,showAdminSettings:!1}),G&&I&&(0,l.jsx)(K,{userId:I,isOpen:j,onClose:N}),Y&&(0,l.jsx)(g.C,{isOpen:k,onClose:A,titleOverride:`Remove "${B}" User?`,descriptionOverride:"This will remove the user from the active organization.",entityDescription:"User",onDelete:ea}),(0,l.jsx)(r(),{id:"7e1306ff15781fa6",children:".user-detail-main-grid.jsx-7e1306ff15781fa6{align-items:flex-start;display:grid;gap:1.5rem;grid-template-columns:1fr;margin-top:1.5rem}.user-detail-left-column.jsx-7e1306ff15781fa6{min-width:0}.user-detail-related-column.jsx-7e1306ff15781fa6{min-width:0}.user-detail-related-section.jsx-7e1306ff15781fa6{border-top:0;padding-top:0}.user-detail-related-section.jsx-7e1306ff15781fa6+.user-detail-related-section.jsx-7e1306ff15781fa6{margin-top:1.25rem}.user-detail-related-section.jsx-7e1306ff15781fa6 .group-detail-manage-button.jsx-7e1306ff15781fa6{margin-top:1rem}.user-detail-profile-summary-row.jsx-7e1306ff15781fa6{align-items:center;display:flex;flex-direction:column;justify-content:flex-start;margin:0 0 1.75rem;text-align:center;width:100%}.user-detail-profile-avatar.jsx-7e1306ff15781fa6{align-items:center;border-radius:999px;color:#fff;display:inline-flex;font-size:3rem;font-weight:700;height:170px;justify-content:center;line-height:1;width:170px}.user-detail-profile-summary-copy.jsx-7e1306ff15781fa6{color:#1f2937;display:grid;font-size:1rem;gap:.75rem;line-height:1.2;margin-top:1.5rem}.user-detail-profile-summary-copy.jsx-7e1306ff15781fa6 strong.jsx-7e1306ff15781fa6{font-weight:700}.user-detail-profile-summary-copy.jsx-7e1306ff15781fa6 span.jsx-7e1306ff15781fa6{font-size:1rem;overflow-wrap:anywhere}.user-detail-info-column.jsx-7e1306ff15781fa6{max-width:100%;width:100%}.user-detail-info-card.jsx-7e1306ff15781fa6{border:1px solid#dbe3ee;border-radius:0;box-shadow:none;width:100%}.user-detail-info-card.jsx-7e1306ff15781fa6+.user-detail-info-card.jsx-7e1306ff15781fa6{margin-top:1.5rem}.user-detail-info-card.jsx-7e1306ff15781fa6 .card-body.jsx-7e1306ff15781fa6{padding:1.5rem}.user-detail-info-card-title.jsx-7e1306ff15781fa6{color:#1f2937;font-size:1.25rem;font-weight:700;line-height:1.2;margin:0 0 1.25rem}.user-detail-info-card-text.jsx-7e1306ff15781fa6{color:#6b7280;font-size:1rem;line-height:1.4;margin:0}.user-detail-about-timezone.jsx-7e1306ff15781fa6{align-items:center;color:#1f2937;display:flex;font-size:1rem;gap:1rem;margin-top:1.25rem;min-width:0}.user-detail-about-timezone.jsx-7e1306ff15781fa6 i.jsx-7e1306ff15781fa6{color:#1f2937;flex:0 0 18px;font-size:1rem;line-height:1;text-align:center}.user-detail-profile-list.jsx-7e1306ff15781fa6{display:grid;gap:1.35rem}.user-detail-profile-row.jsx-7e1306ff15781fa6{align-items:center;color:#1f2937;display:flex;font-size:1rem;gap:1rem;min-width:0}.user-detail-profile-row.jsx-7e1306ff15781fa6 i.jsx-7e1306ff15781fa6{color:#1f2937;flex:0 0 18px;font-size:1rem;line-height:1;text-align:center}.user-detail-profile-row.jsx-7e1306ff15781fa6 span.jsx-7e1306ff15781fa6{min-width:0;overflow-wrap:anywhere}.groups-fullscreen-table.jsx-7e1306ff15781fa6{display:grid;gap:.85rem;width:100%}.groups-table-shell.jsx-7e1306ff15781fa6{background:#fff;border:1px solid#dce3eb;border-radius:14px;overflow:hidden}.groups-table-scroll.jsx-7e1306ff15781fa6{max-height:none;min-height:154px;overflow:auto}.groups-table-modern thead th{background:#f2f5f9;border-bottom:1px solid#dce3eb;color:#2a3a51;font-size:.76rem;letter-spacing:.03em;position:sticky;text-transform:uppercase;top:0;z-index:1}.groups-table-modern tbody tr:hover{background:#f7fafe}.groups-table-modern tbody td{border-color:#edf1f6}.min-width-0{min-width:0}@media(min-width:992px){.user-detail-main-grid.jsx-7e1306ff15781fa6{gap:2rem;grid-template-columns:352px minmax(0,1fr);margin-top:2rem}.user-detail-related-column.jsx-7e1306ff15781fa6{padding-top:.25rem}.user-detail-profile-avatar.jsx-7e1306ff15781fa6{font-size:3.8rem;height:205px;width:205px}.user-detail-info-column.jsx-7e1306ff15781fa6{flex:0 0 352px;max-width:352px;width:352px}.groups-table-scroll.jsx-7e1306ff15781fa6{max-height:calc(100vh - 350px)}}"})]}):null})},49757:(e,s,a)=>{"use strict";a.d(s,{A:()=>d});var l=a(37876),i=a(14232),r=a(89099),t=a(91291),n=a(58862),o=a(5960);let d=({messageTitle:e,showMessage:s=!1,actionLabel:a,action:d,callActionOnInit:c=!1,showCancelAction:m=!0,showSpinner:f=!0,bottomMessage:x})=>{let u=(0,r.useRouter)();return(0,i.useEffect)(()=>{c&&d&&d()},[d,c]),(0,l.jsx)("div",{className:"h-fix-screen d-flex align-items-center justify-content-center",children:(0,l.jsxs)("div",{className:`minw-md-450p d-flex align-items-center justify-content-center flex-column p-4 rounded-md position-relative ${s?"shadow bg-white":""}`,children:[m&&s&&(0,l.jsx)(t.A,{ariaLabel:"Navigate back to home",className:"no-min-size position-absolute top-0 right-0 m-2 text-white",onClick:()=>u.back(),children:(0,l.jsx)("span",{className:"bi bi-x"})}),s&&(0,l.jsx)("img",{alt:"Osirus AI Logo",src:o.PM,className:"w-xs-220p img-fluid"}),f&&(0,l.jsx)("div",{className:"my-3",children:(0,l.jsx)(n.A,{})}),s&&(0,l.jsxs)("div",{className:"text-center mt-4 mw-xs-500p",children:[(0,l.jsx)("h4",{className:"mb-4",children:e}),(0,l.jsx)(t.A,{ariaLabel:"sign up",className:"ms-2 text-white fw-bold h-50 rounded-xl",color:"primary",onClick:()=>d&&d(),children:a})]}),(0,l.jsx)("div",{className:"mt-3",children:x})]})})}},50485:(e,s,a)=>{"use strict";a.d(s,{K:()=>t});var l=a(37876),i=a(14232),r=a(95812);let t=(0,a(89461).R)((e,s)=>{let{icon:a,children:t,isRound:n,"aria-label":o,...d}=e,c=a||t,m=(0,i.isValidElement)(c)?(0,i.cloneElement)(c,{"aria-hidden":!0,focusable:!1}):null;return(0,l.jsx)(r.$,{px:"0",py:"0",borderRadius:n?"full":void 0,ref:s,"aria-label":o,...d,children:m})});t.displayName="IconButton"},59439:(e,s,a)=>{"use strict";a.d(s,{Ip:()=>r,fA:()=>t,rF:()=>n});var l=a(37876);let i=["group-avatar-color-orange","group-avatar-color-green","group-avatar-color-peach","group-avatar-color-burnt","group-avatar-color-gold","group-avatar-color-magenta","group-avatar-color-blue","group-avatar-color-mint"],r=["group-member-pill-color-orange","group-member-pill-color-green","group-member-pill-color-peach","group-member-pill-color-burnt","group-member-pill-color-gold","group-member-pill-color-magenta","group-member-pill-color-blue","group-member-pill-color-mint"],t=e=>i[Array.from(e.trim()).reduce((e,s)=>e+s.charCodeAt(0),0)%i.length],n=({name:e,size:s="sm",className:a})=>(0,l.jsx)("span",{className:["group-initial-avatar",`group-initial-avatar--${s}
1`,t(e),a].filter(Boolean).join(" "),"aria-hidden":"true",children:e.trim().charAt(0).toUpperCase()})},60685:(e,s,a)=>{"use strict";a.d(s,{A:()=>m});var l=a(37876),i=a(14232),r=a(48230),t=a.n(r),n=a(89099),o=a(4847),d=a(63408),c=a(49757);let m=(e,s)=>{let a=a=>{let r=(0,n.useRouter)(),{isDataLoaded:m,isConnected:f,user:x}=(0,o.G)(d.Fk),u="string"==typeof r.asPath&&r.asPath.trim().length>0?r.asPath:"/",p="/"===u?"/login":`/login?redirect=${encodeURIComponent(u)}`,[h,j]=(0,i.useState)(!1);return((0,i.useEffect)(()=>j(!0),[]),h&&m)?f?s?.needSystemAdminRole&&x?.isSystemAdmin!==!0?(0,l.jsx)(c.A,{showMessage:!0,messageTitle:"You do not have sufficient permission to access this page",actionLabel:"Go Back",action:()=>r.back(),showSpinner:!1,showCancelAction:!1}):(0,l.jsx)(e,{...a}):(0,l.jsx)(c.A,{showMessage:!0,showSpinner:!1,messageTitle:"Please sign up to continue",actionLabel:"Sign Up",action:()=>r.push("/signup"),bottomMessage:(0,l.jsxs)("div",{className:"d-flex gap-1",children:[(0,l.jsx)("span",{children:"Already have an account?"}),(0,l.jsx)(t(),{href:p,className:"text-decoration-underline text-dark fw-bold",children:"Login"})]})}):(0,l.jsx)(c.A,{})};return e.getInitialProps&&(a.getInitialProps=e.getInitialProps),a}},62897:(e,s,a)=>{"use strict";a.d(s,{_s:()=>c,gJ:()=>o});var l=a(37876),i=a(16229),r=a(10184),t=a(10059);let[n,o]=(0,i.q)(),d={start:{ltr:"left",rtl:"right"},end:{ltr:"right",rtl:"left"}};function c(e){let{isOpen:s,onClose:a,placement:i="right",children:o,...c}=e,m=(0,t.D)(),f=m.components?.Drawer,x=function(e,s){if(e)return d[e]?.[s]??e}(i,m.direction);return(0,l.jsx)(n,{value:{placement:x},children:(0,l.jsx)(r.aF,{isOpen:s,onClose:a,styleConfig:f,...c,children:o})})}},71060:(e,s,a)=>{"use strict";a.d(s,{X:()=>l,x:()=>i});let l=e=>e&&"string"==typeof e&&e.toLowerCase().trim().replace(/\s+/g,"-").replace(/[^a-z0-9-]/g,"").replace(/-+/g,"-").replace(/^-|-$/g,"").substring(0,50)||"project",i=e=>e&&"string"==typeof e&&e.toLowerCase().trim().replace(/\s+/g,"-").replace(/[^a-z0-9-]/g,"").replace(/-+/g,"-").replace(/^-|-$/g,"").substring(0,50)||"agent"},84275:(e,s,a)=>{"use strict";a.d(s,{j:()=>d});var l=a(37876),i=a(67118),r=a(75255),t=a(10184),n=a(89461),o=a(8519);let d=(0,n.R)((e,s)=>{let{className:a,...n}=e,d=(0,r.cx)("chakra-modal__footer",a),c=(0,t.x5)(),m=(0,i.H2)({display:"flex",alignItems:"center",justifyContent:"flex-end",...c.footer});return(0,l.jsx)(o.B.footer,{ref:s,...n,__css:m,className:d})});d.displayName="ModalFooter"},87186:(e,s,a)=>{"use strict";a.d(s,{A:()=>n});var l=a(37876),i=a(14232),r=a(89099),t=a(98043);let n=({errors:e,register:s,textareaRef:a,label:n,getValues:o,helperText:d,cols:c=20,rows:m=5,enableAssistant:f=!0,assistantContext:x,...u})=>{let p=(0,r.useRouter)(),h=e?e[s?.name||""]?.message:null,[j,g]=(0,i.useState)(!1),[b,N]=(0,i.useState)(!1),v=(0,i.useRef)(null),y=(0,i.useCallback)(e=>{v.current=e,a&&(a.current=e);let l=s?.ref;if(l){if("function"==typeof l)return void l(e);l.current=e}},[s,a]),w=String(p?.asPath||p?.pathname||"").startsWith("/admin")&&f&&!u.disabled,k=w&&(j||b),C=s?(({ref:e,...s})=>s)(s):void 0;return(0,l.jsxs)("div",{className:`field-container textarea field-container--${j?"labelFloating":"labelResting"} ${h?"is-invalid":""} `,children:[w&&(0,l.jsx)(t.A,{targetRef:v,visible:k,fieldName:s?.name||n,context:x,getFormContext:o?()=>o():void 0,onFocusWithinChange:N}),(0,l.jsx)("label",{className:`field-label ${s?.name&&o&&!o(s.name)?"field-label--empty":""} field-label--${j?"floating":"resting"}`,htmlFor:s?.name,children:n}),(0,l.jsx)("textarea",{ref:y,cols:c,rows:m,className:`Input ${j?"Input--focused":""}`,...C,...u,onFocus:e=>{u.onFocus?.(e),g(!0)},onBlur:e=>{s?.onBlur(e),u.onBlur?.(e),g(!1)}}),d&&(0,l.jsx)("span",{className:"small d-block mt-2",children:d}),h&&(0,l.jsx)("span",{className:"invalid-feedback",children:`${h}`})]})}},97085:(e,s,a)=>{"use strict";a.d(s,{A:()=>t});var l=a(37876),i=a(14232);let r={success:{textColor:"white",bgColor:"success",icon:"bi bi-check",label:"Success"},error:{textColor:"dark",bgColor:"danger",icon:"bi bi-exclamation-circle",label:"Error"},pending:{textColor:"dark",bgColor:"warning",icon:"bi bi-clock",label:"Pending"}},t=({textColor:e,bgColor:s,label:a,icon:t,className:n,isOutline:o,type:d})=>{let c=(0,i.useMemo)(()=>d?{...r[d]}:{textColor:e,bgColor:s,label:a,icon:t}
1,[d,e,s,a,t]);return(0,l.jsxs)("span",{className:`small py-1 px-2 rounded-pill text-center text-capitalize ${o?"border border":"bg"}-${c.bgColor} text-${c.textColor} ${n}`,children:[c.icon&&(0,l.jsx)("span",{className:c.icon+"me-2"}),c.label]})}}},e=>{e.O(0,[8992,8831,6943,6347,6629,9525,636,6593,8792],()=>e(e.s=3336)),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.