import{aT as n,j as t,aS as x}from"./react-vendor-xYZnmIII.js";import{C as u}from"./course-card-2-B4SIepk5.js";import{T as c}from"./tabs-eeNoRD9t.js";import{y as h,z as f,D as j,B as N}from"./ui-components-CQM92IK3.js";import{g as b,S as v}from"./section-BOHF3o7C.js";import"./inertia-vendor-cBbDTmhJ.js";import"./ui-vendor-Ds9iwIxa.js";import"./interactive-vendor-B1OgcAgP.js";import"./use-lang-Dg6I_Fym.js";import"./chunked-uploader-input-dQEAsxxf.js";import"./input-error-_LAmvivg.js";import"./loading-button-D7aXR3K4.js";import"./inertia-FIn3q7f1.js";import"./icon-picker-dialog-jzY0-ZNJ.js";import"./icon-picker-e9MMAA5U.js";import"./debounce-CWHP_ANh.js";import"./icon-picker-tooltip-CR2ZyXZ1.js";import"./table-header-CjMHr8CW.js";import"./table-page-size-CzF8rJAG.js";import"./route-D0xh7FtZ.js";const J=()=>{var r,l,a;const{props:p}=n(),{page:o,customize:d,categoryTopCourses:i}=p,s=b(o,"category_courses");return t.jsxs(v,{customize:d,pageSection:s,containerClass:"py-20",children:[t.jsxs("div",{className:"mx-auto",children:[t.jsx("h2",{className:"mb-4 text-3xl font-bold sm:text-4xl",children:s==null?void 0:s.title}),t.jsx("p",{className:"text-muted-foreground",children:s==null?void 0:s.description})]}),i[0]&&t.jsxs(c,{defaultValue:i[0].slug,children:[t.jsx("div",{className:"mt-6 flex w-full max-w-[1000px] overflow-x-auto overflow-y-hidden",children:t.jsx(h,{className:"h-[60px] justify-center px-2",children:i.map(e=>t.jsx(f,{value:e.slug,className:"h-11 cursor-pointer text-base",children:e.title},e.id))})}),i.map(e=>t.jsx(j,{value:e.slug,className:"mt-10",children:e.courses&&e.courses.length>0?t.jsx("div",{className:"grid grid-cols-1 gap-6 md:grid-cols-2 lg:grid-cols-3",children:e.courses.map(m=>t.jsx(u,{course:m},m.id))}):t.jsx("p",{className:"text-muted-foreground text-center",children:"No courses found"})},e.id))]}),t.jsx("div",{className:"mt-10 flex items-center justify-center",children:((r=s==null?void 0:s.properties)==null?void 0:r.button_text)&&t.jsx(N,{asChild:!0,variant:"outline",className:"h-[42px] px-5",children:t.jsx(x,{href:((l=s==null?void 0:s.properties)==null?void 0:l.button_link)||"",children:(a=s==null?void 0:s.properties)==null?void 0:a.button_text})})})]})};export{J as default};
