import{c as y,a as g,h as S,s as b,r as a,j as e,w as j,S as k,B as n,T as d,d as C,p as M,M as w,u as I,i as L,K as u,I as v,k as T,D,s4 as E}from"./index-55b8aeb0.js";import{g as A,u as z}from"./useViewPort-76519521.js";import{I as B,R as F}from"./index-657b4fde.js";import{u as R}from"./useToggle-24d42bce.js";import{L as O}from"./LogoBox-d7b4bf44.js";import{C as P}from"./CardContent-5d45e66d.js";import"./AntdIcon-4834ad0b.js";import"./slicedToArray-f5e6f6d2.js";import"./defineProperty-83f36300.js";import"./toPropertyKey-d8419463.js";import"./typeof-7fd5df1e.js";import"./objectSpread2-1e39d65c.js";import"./FilterOutlined-bcd42762.js";import"./InfoCircleOutlined-dfd4d17d.js";import"./SolutionOutlined-701bdd3f.js";import"./styled-ea700eba.js";const f=()=>{const p=y(),{profileMenuItemsList:l}=g(t=>S(t)),c=g(t=>b(t));return a.useMemo(()=>A(c.sidenav.theme),[c.sidenav.theme]),e.jsx(e.Fragment,{children:e.jsx(j,{sx:{height:"100%",flex:1},children:e.jsx(k,{style:{height:"100%",padding:24,paddingTop:6},children:e.jsx(n,{sx:{mt:2},children:l&&l.map((t,i)=>{var x;return e.jsxs(n,{children:[e.jsx(d,{variant:"h5",children:t.label}),e.jsx(n,{sx:{my:1},children:t&&((x=t.children)==null?void 0:x.map((s,h)=>{const o=location.pathname===s.url,r=B[s.icon];return e.jsx(C,{to:s.url,target:s.target,"data-menu-key":s.key,style:{display:"flex",gap:"10px",alignItems:"center",textDecoration:"none",color:"inherit"},onClick:()=>{p(M({menuitem_id:(s==null?void 0:s.key)||""}))},children:e.jsxs(w,{sx:m=>({display:"flex",flexDirection:"row",gap:2,ml:0,width:"100%",lineHeight:2,p:1,transition:"all 0.3s",borderRadius:"5px",backgroundColor:o?"#E0EFFF":"",color:o?m.palette.common.black:""}),children:[r?e.jsx(r,{style:{fontSize:16}}):e.jsx(F,{style:{fontSize:16}}),e.jsx(d,{variant:"subtitle1",children:s.label})]})},h)}))})]},i)})})})})})},H=()=>e.jsxs(n,{sx:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",flex:1},children:[e.jsx(O,{}),e.jsx(d,{variant:"h4",children:" Welcome To Admin Settings"}),e.jsx(d,{variant:"subtitle2",align:"center",children:"Please Click On Menu"})]}),te=()=>{z();const{isOpen:p,hide:l,toggleOpen:c}=R(),t=y(),i=I(),[x,s]=a.useState("Settings"),[h,o]=a.useState("Admin"),r=g(m=>m.customise.sidenav.showMobileMenu);return a.useEffect(()=>{t(L({from:"profilemenu",code:"MENU0008"}))},[]),a.useEffect(()=>{i.pathname==="/pages/settings"&&(s("Settings"),o("Admin"))},[i]),e.jsx(n,{sx:{my:2},children:e.jsxs(u,{container:!0,spacing:2,children:[e.jsx(u,{size:{xs:12,lg:3.3,xl:r?2.3:2.7},sx:{display:{lg:"block",xs:"none"}},children:e.jsx(f,{})}),e.jsxs(u,{size:{xs:12,lg:8.7,xl:r?9.7:9.3},children:[e.jsx(j,{sx:{display:{lg:"none",xs:"block"}},children:e.jsxs(n,{children:[e.jsx(v,{onClick:()=>{c()},children:e.jsx(T,{size:20})}),e.jsx(D,{open:p,onClose:l,sx:{width:288,"& .MuiDrawer-paper":{width:288}},children:e.jsx(f,{})})]})}),e.jsx(j,{sx:{mt:{xs:2,lg:0},height:"100%"},children:e.jsxs(P,{children:[i.pathname==="/pages/settings"&&e.jsx(e.Fragment,{children:e.jsx(n,{sx:{display:"grid",placeContent:"center",height:"100%"},children:e.jsx(H,{})})}),e.jsx(n,{children:e.jsx(E,{context:{title:x,setTitle:s,subtitle:h,setSubtitle:o}})})]})})]})]})})};export{te as default};
