import{r as y,w as r,aO as k,m as l,g as s,af as m,aN as M,c$ as j,b1 as C,d0 as w,cZ as v,W as u,bq as g,j as t,bn as I,V as D,b as d,i as $,d as L,O as S,c as T,d1 as R}from"./index-Csef3-wA.js";import{U as H}from"./styles-XiU4mAxA.js";import{I as x}from"./Icon-o1TUwOIX.js";import{T as _,a as N}from"./Tabs-EQ-ZuI5c.js";import{F as A}from"./Fab-kDY9LTNz.js";const F=()=>{const{openContact:o}=y.useContext(H);return o},P=r({paper:{boxShadow:"0 2px 8px rgba(180, 180, 180, 0.32)",transform:"translateY(10px)",minWidth:187}},"ActionsMenu")(k),W=l(({breakpoints:o})=>({root:{display:"flex",justifyContent:"flex-end",gap:20,padding:"21px 0",margin:"0 8px"},linksContainer:{display:"flex",alignItems:"center",gap:20,marginRight:20,[o.down("sm")]:{flexDirection:"column",alignItems:"flex-start",gap:10}},link:{opacity:.3,transition:"opacity 0.3s ease-in-out","&:hover":{opacity:1},[o.down("sm")]:{display:"flex",padding:8,gap:10,opacity:1,color:`${s.gray.dark} !important`}}}),"Header"),B=l(({breakpoints:o})=>({root:{opacity:.3,transition:"opacity 0.3s ease-in-out",cursor:"pointer","&:hover":{opacity:1},[o.down("sm")]:{opacity:1}}}),"Icon"),U=l(()=>({root:{display:"flex",padding:"5px 0"},menu:{width:218},divider:{height:1,border:0,background:s.gray.normal,margin:"6px 8px 8px 0"}}),"Settings"),K=P,z=w,h=r({root:{gap:8}},"MenuItem")(m),E=r({root:{margin:0,height:"auto",flexDirection:"column",alignItems:"flex-start",background:"transparent !important",color:`${s.gray.dark} !important`,cursor:"default"}},"MenuItemInfo")(m),Q=l(()=>({paper:{marginLeft:-8}}),"ActionsButton"),X=l({root:{position:"relative"},count:{position:"absolute",right:-1,top:-6,width:16,height:16,lineHeight:"16px",color:"white",background:s.deepRed,borderRadius:"50%",fontSize:12,fontWeight:800,textAlign:"center"},wrapper:{display:"flex",flexDirection:"column",gap:10,padding:"20px 0"},container:{cursor:"pointer",padding:10,transition:"background 0.6s ease-in-out",borderRadius:3,paddingLeft:40,position:"relative",lineHeight:"21px","&:hover":{background:s.gray.light},"&::before":{content:'""',width:8,height:8,background:s.gray.normal,borderRadius:"50%",position:"absolute",top:17,left:17},"&.read::before":{background:s.primary.blue}},date:{color:s.gray.dark,fontSize:12},message:{},link:{color:s.primary.blue}},"Notifications"),oo=r({paper:{width:450,padding:20,maxHeight:"unset",height:"auto",boxShadow:M}},"Popover")(j),to=r({root:{borderBottom:`1px solid ${s.gray.normal}`},indicatorColor:{background:"red"}},"Tabs")(_),eo=r({root:{textTransform:"none",minWidth:"unset"},selected:{fontWeight:"bold"}},"Tab")(N),so=l({heading:{textTransform:"uppercase",fontWeight:700},tabsContainer:{marginTop:10}},"NotificationsPopover"),no=r({root:{width:40,height:40,boxShadow:"none"}},"Fab")(A),ao=r({paper:{padding:"15px 20px 25px",borderRadius:"5px 5px 0 0"}},"Drawer")(C),ro=()=>{const o=W(),n=[{to:"#",onClick:F(),label:"pages.adminContact",icon:"menu_contact"},{href:v,component:"a",rel:"noopener noreferrer",target:"_blank",label:"pages.helpCenter",icon:"menu_help_center"},{to:u.apiDocsBase,rel:"noopener noreferrer",label:"pages.devs",icon:"menu_api_docs"}].map(({component:a,...i})=>({...i,LinkComponent:a||g}));return t.jsx("div",{className:o.linksContainer,children:n.map(({LinkComponent:a,label:i,icon:p,...b})=>t.jsxs(a,{className:o.link,...b,children:[t.jsx(I,{mdUp:!0,children:t.jsx(x,{name:p})}),t.jsx(D,{id:i})]},i))})},f=o=>{const e=B();return t.jsx(x,{className:e.root,...o})},io=()=>{const o=d(),e=[{label:o.formatMessage({id:"pages.myAccount"}),icon:"settings",to:u.myAccount},{label:o.formatMessage({id:"pages.users"}),icon:"menu_my_account",to:u.users}];return t.jsx(z,{children:e.map(({to:n,label:a,icon:i},p)=>t.jsx(g,{to:n,children:t.jsxs(h,{children:[t.jsx(f,{name:i})," ",a]},a)},p))})},{roles:c}=$;function O(){const o=d();return{[c.admin]:o.formatMessage({id:"users.roles.admin"}),[c.extendedCollaborator]:o.formatMessage({id:"users.roles.collaborator"}),[c.collaborator]:o.formatMessage({id:"users.roles.limited"})}}function co(){const o=d(),e={bold:n=>t.jsx("strong",{children:n})};return{[c.admin]:o.formatMessage({id:"users.roleDescription.admin"},e),[c.extendedCollaborator]:o.formatMessage({id:"users.roleDescription.collaborator"},e),[c.collaborator]:o.formatMessage({id:"users.roleDescription.limited"},e)}}const lo=()=>{const o=O(),{user:{email:e,role:n}}=L(a=>a.user);return t.jsxs(E,{children:[t.jsx("strong",{children:e}),t.jsx("small",{children:o[n]})]})},q=()=>{const o=S(),e=T();return()=>e(R(o))},po=()=>{const o=d(),e=q(),n=o.formatMessage({id:"common.logout"});return t.jsxs(h,{onClick:e,children:[t.jsx(f,{name:"logout2"}),n]})},uo=()=>{const o=U();return t.jsx("div",{className:o.divider})};export{ao as D,no as F,ro as H,f as I,uo as L,K as M,oo as P,io as S,to as T,lo as U,po as a,so as b,eo as c,co as d,h as e,Q as f,W as h,X as n,U as s,O as u};