import{f as h,P as u,r as n,z as g,d as j,a as y,a0 as w,i as S,j as e,B as a,T as d,_ as C,a1 as b}from"./index-7b9530f9.js";import{I as v,R as I}from"./index-fa74e94c.js";import{T as z}from"./TextField-a16050c5.js";import{I as R}from"./InputAdornment-e3017a11.js";import{G as p}from"./Grid2-e0ccfa46.js";import"./AntdIcon-682f2518.js";import"./objectSpread2-12329e58.js";import"./index-1f83e1d2.js";import"./index-e5978b8b.js";import"./FilterFilled-70c51a7c.js";import"./FilterOutlined-ae23dbc1.js";import"./InfoCircleOutlined-7b2d51dc.js";import"./SolutionOutlined-2052de7c.js";import"./Select-71d7c76c.js";import"./Grow-ac96e569.js";import"./isMuiElement-a5b21fef.js";const A=h(u)(({theme:s})=>({backgroundColor:"#fff",...s.typography.body2,padding:s.spacing(4),textAlign:"left",borderRadius:"10px",cursor:"pointer",color:s.palette.text.secondary,...s.applyStyles("dark",{backgroundColor:"#1A2027"})})),H=()=>{const[s,i]=n.useState([]),x=g(),m=j(),{system:{reportsMenuItemsList:r}}=y(t=>w(t));n.useEffect(()=>{m(S({code:"MENU0005",from:"reportsmenu"}))},[]),n.useEffect(()=>{i(r)},[r]);const f=t=>{const c=r==null?void 0:r.filter(o=>o.label.toLowerCase().includes(t.target.value.toLowerCase()));t.target.value===""?i(r):i(c)},l=t=>{x(t)};return e.jsxs(a,{sx:{width:"100%"},children:[e.jsxs(a,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",my:"24px"},children:[e.jsx(d,{variant:"h5",color:"text.primary",children:"Reports"}),e.jsx(a,{sx:{display:{xs:"hidden",md:"flex"},alignItems:"center",gap:"10px",fontWeight:600},children:e.jsx(a,{sx:{position:"static",overflowY:"hidden"},children:e.jsx(z,{id:"input-with-icon-textfield",size:"small",InputProps:{startAdornment:e.jsx(R,{position:"start",children:e.jsx(C,{size:20})})},sx:{width:300},onChange:f,variant:"outlined",placeholder:"Search Report..."})})})]}),(s==null?void 0:s.length)!=0?e.jsx(p,{container:!0,rowSpacing:2,columnSpacing:{xs:1,sm:2,md:3},style:{marginLeft:"0px"},children:s==null?void 0:s.map((t,c)=>{const o=v[t.icon];return e.jsx(e.Fragment,{children:e.jsx(p,{size:{xs:12,md:6,lg:6,xl:3},children:e.jsx(A,{sx:{border:"1px solid #dee2e6",boxShadow:"none"},onClick:()=>l(t.url),children:e.jsxs(a,{display:"flex",alignItems:"center",children:[o?e.jsx(o,{style:{fontSize:16}}):e.jsx(I,{style:{fontSize:16}}),e.jsx(d,{sx:{color:"text.secondary",fontSize:"16px",paddingX:2,flexGrow:1},onClick:()=>{},variant:"h6",children:t==null?void 0:t.label}),e.jsx(b,{size:"20",onClick:()=>{l(t.url)}})]})})})})})}):""]})};export{H as default};
