import{aU as u,r as o,G as f,j as r,F as s,o as h,B as g}from"./index-62412d73.js";import{u as C,D as x,b as j}from"./GenericForm-0bdc2731.js";import"./ContentCopy-2803a023.js";import"./ExpandMore-270e10d6.js";import"./ListItemText-e018beda.js";import"./Close-45a41f0c.js";import"./DialogContentText-3747410b.js";import"./AdmUsuarios-b29a49ac.js";import"./Alert-00e531f3.js";import"./Edit-b0ca90dc.js";import"./ListItemIcon-db4667b4.js";import"./AdjuntarArchivoSolicitud-1cb30c2e.js";import"./QrReader-e918a5fc.js";import"./PictureAsPdf-7478ec13.js";import"./main-d2c36a4f.js";import"./NoRowsComponent-60007845.js";import"./MoreVert-ad7d34d0.js";import"./useForm-c5fd5c47.js";import"./Card-9a848e01.js";import"./CardContent-7c197acc.js";import"./cjs-450adfd1.js";import"./OmegaTransferList-dd2e3814.js";import"./CardHeader-b8f95819.js";import"./DatosDom-8064dda9.js";import"./ImageViewerModal-67b612c5.js";import"./Avatar-6fa1c95a.js";import"./_commonjs-dynamic-modules-9b6cc816.js";import"./env-198ff0f3.js";import"./cargaPreferenciasDeUsuario-9792c370.js";import"./mapValues-d92aa435.js";import"./Scheduler-33605f5f.js";import"./___vite-browser-external_commonjs-proxy-087935ee.js";const _=()=>{let{name:t}=u();const{loading:v,data:e,error:a,load:n}=C(t||"",!0),[m,p]=o.useState(!1),[c,i]=o.useState(!0);f();const l=async()=>{n()};if(o.useEffect(()=>{e&&p(!0),i(!1)},[e]),o.useEffect(()=>{i(!0),t&&l()},[t]),!a)if(c){const d=`Error: No se encontro el componente components/Custom/${t}`;return h(g,{height:"100dvh",children:[r("h3",{children:t}),r("div",{className:"error",children:d})]})}else return m?r(s,{children:r(o.Suspense,{fallback:r("div",{children:"Cargando..."}),children:r(j,{})})}):r(s,{children:r(o.Suspense,{fallback:r("div",{children:"Cargando..."}),children:r(x,{})})})};export{_ as default};
