import{jsxs as t,Fragment as n,jsx as e}from"react/jsx-runtime";import{B as m,a as l}from"./ui-components-B24mpb8o.js";import{D as f}from"./layout-CZk01yM3.js";import{Head as h,Link as a}from"@inertiajs/react";import{Plus as o,Award as p}from"lucide-react";import d from"./certificate-card-BDj-tR6c.js";import"next-themes";import"sonner";import"react";import"@radix-ui/react-label";import"class-variance-authority";import"@radix-ui/react-checkbox";import"@radix-ui/react-avatar";import"@radix-ui/react-dropdown-menu";import"@radix-ui/react-scroll-area";import"@radix-ui/react-popover";import"@radix-ui/react-radio-group";import"@radix-ui/react-dialog";import"@radix-ui/react-slot";import"clsx";import"@radix-ui/react-separator";import"@radix-ui/react-tooltip";import"@radix-ui/react-tabs";import"@radix-ui/react-accordion";import"@radix-ui/react-progress";import"@radix-ui/react-select";import"cmdk";import"@radix-ui/react-switch";import"react-day-picker";import"@radix-ui/react-slider";import"embla-carousel-react";import"@radix-ui/react-toggle-group";import"vaul";import"tailwind-merge";import"./main-Cv60h411.js";import"./theme-colors-CLpwvDr4.js";import"./appearance-zLWEcDPI.js";import"./language-79bZLpyc.js";import"./notification-BBQVVMqD.js";import"date-fns";import"./app-logo-CAnM-q9p.js";import"./route-D0xh7FtZ.js";import"./use-lang-Cw_jKJYs.js";import"./certificate-preview-DuT8f0Zb.js";const u=({templates:i})=>{const c=i.filter(r=>r.type==="exam"),s=i.filter(r=>r.type==="course");return t(n,{children:[e(h,{title:"Certificate Templates"}),t("div",{className:"space-y-6",children:[t("div",{className:"flex items-center justify-between",children:[t("div",{children:[e("h2",{className:"text-xl font-semibold",children:"Certificate Templates"}),e("p",{className:"text-muted-foreground text-sm",children:"Manage your certificate templates for course completion"})]}),e(a,{href:route("certificate.templates.create"),children:t(m,{children:[e(o,{className:"mr-2 h-4 w-4"}),"Create Template"]})})]}),t("div",{className:"py-6",children:[e("h6",{className:"mb-3 text-xl font-semibold",children:"Course Certificate Templates"}),s.length===0?e(l,{className:"p-12",children:t("div",{className:"flex flex-col items-center justify-center text-center",children:[e(p,{className:"text-muted-foreground mb-4 h-16 w-16"}),e("h3",{className:"mb-2 text-xl font-semibold",children:"No certificate templates yet"}),e("p",{className:"text-muted-foreground mb-4",children:"Create your first certificate template to get started"}),e(a,{href:route("certificate.templates.create"),children:t(m,{children:[e(o,{className:"mr-2 h-4 w-4"}),"Create Your First Template"]})})]})}):e("div",{className:"grid gap-6 md:grid-cols-2 lg:grid-cols-3",children:s.map(r=>e(d,{type:"course",template:r},r.id))})]}),t("div",{className:"py-6",children:[e("h6",{className:"mb-3 text-xl font-semibold",children:"Exam Certificate Templates"}),c.length===0?e(l,{className:"p-12",children:t("div",{className:"flex flex-col items-center justify-center text-center",children:[e(p,{className:"text-muted-foreground mb-4 h-16 w-16"}),e("h3",{className:"mb-2 text-xl font-semibold",children:"No certificate templates yet"}),e("p",{className:"text-muted-foreground mb-4",children:"Create your first certificate template to get started"}),e(a,{href:route("certificate.templates.create"),children:t(m,{children:[e(o,{className:"mr-2 h-4 w-4"}),"Create Your First Template"]})})]})}):e("div",{className:"grid gap-6 md:grid-cols-2 lg:grid-cols-3",children:c.map(r=>e(d,{type:"exam",template:r},r.id))})]})]})]})};u.layout=i=>e(f,{children:i});export{u as default};
