(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,970065,e=>{"use strict";var r=e.i(843476),t=e.i(647163);e.s(["Card",0,function({className:e,...a}){return(0,r.jsx)("div",{"data-slot":"card",className:(0,t.cn)("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e),...a})},"CardContent",0,function({className:e,...a}){return(0,r.jsx)("div",{"data-slot":"card-content",className:(0,t.cn)("px-6",e),...a})},"CardDescription",0,function({className:e,...a}){return(0,r.jsx)("div",{"data-slot":"card-description",className:(0,t.cn)("text-muted-foreground text-sm",e),...a})},"CardHeader",0,function({className:e,...a}){return(0,r.jsx)("div",{"data-slot":"card-header",className:(0,t.cn)("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...a})},"CardTitle",0,function({className:e,...a}){return(0,r.jsx)("div",{"data-slot":"card-title",className:(0,t.cn)("leading-none font-semibold",e),...a})}])},994179,e=>{"use strict";var r=e.i(843476),t=e.i(991918),a=e.i(225913),s=e.i(647163);let d=(0,a.cva)("inline-flex items-center justify-center rounded-md border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"border-transparent bg-destructive text-white [a&]:hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"}},defaultVariants:{variant:"default"}});e.s(["Badge",0,function({className:e,variant:a,asChild:i=!1,...n}){let o=i?t.Slot:"span";return(0,r.jsx)(o,{"data-slot":"badge",className:(0,s.cn)(d({variant:a}),e),...n})}])},655378,e=>{"use strict";var r=e.i(843476),t=e.i(522016),a=e.i(271645),s=e.i(618566),d=e.i(970065),i=e.i(167881),n=e.i(994179),o=e.i(270598),c=e.i(272944);e.s(["default",0,function(){let e=(0,s.useParams)().id,l=(0,a.useMemo)(()=>(0,c.getApiService)(),[]),{error:u}=(0,o.useToast)(),[m,x]=(0,a.useState)(null),[f,g]=(0,a.useState)(!0);return(0,a.useEffect)(()=>{(async()=>{g(!0);let r=await l.getEmployee(e);r.success&&r.data?x(r.data):u("Failed to load employee",r.error),g(!1)})()},[l,e,u]),(0,r.jsxs)("div",{className:"flex-1 space-y-6",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("h1",{className:"text-3xl font-bold text-foreground",children:"Employee Details"}),(0,r.jsx)("p",{className:"text-muted-foreground mt-2",children:"View employee information"})]}),(0,r.jsx)(t.default,{href:"/accounts/employees",children:(0,r.jsx)(i.Button,{variant:"outline",children:"Back"})})]}),(0,r.jsxs)(d.Card,{className:"bg-card border-border",children:[(0,r.jsx)(d.CardHeader,{children:(0,r.jsx)(d.CardTitle,{children:"Employee"})}),(0,r.jsx)(d.CardContent,{children:f?(0,r.jsx)("p",{className:"text-muted-foreground",children:"Loading employee..."}):m?(0,r.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 text-sm",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Code"}),(0,r.jsx)("p",{className:"font-medium text-foreground",children:m.code})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Name"}),(0,r.jsx)("p",{className:"font-medium text-foreground",children:m.name})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Phone"}),(0,r.jsx)("p",{className:"font-medium text-foreground",children:m.phone||"-"})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Email"}),(0,r.jsx)("p",{className:"font-medium text-foreground",children:m.email||"-"})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Designation"}),(0,r.jsx)("p",{className:"font-medium text-foreground",children:m.designation||"-"})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("p",{className:"text-muted-foreground",children:"Status"}),(0,r.jsx)(n.Badge,{variant:m.active?"default":"secondary",children:m.active?"Active":"Inactive"})]})]}):(0,r.jsx)("p",{className:"text-muted-foreground",children:"Employee not found."})})]})]})}])}]);