var S=Object.defineProperty;var u=Object.getOwnPropertySymbols;var z=Object.prototype.hasOwnProperty,P=Object.prototype.propertyIsEnumerable;var f=(t,s,r)=>s in t?S(t,s,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[s]=r,a=(t,s)=>{for(var r in s||(s={}))z.call(s,r)&&f(t,r,s[r]);if(u)for(var r of u(s))P.call(s,r)&&f(t,r,s[r]);return t};import{aT as E,r as k,j as e,aY as _,cH as B,bn as D,aX as F}from"./react-vendor-xYZnmIII.js";import{a as H,S as O,b as Q,B as c,d as R,e as A,_ as g,a7 as v,a8 as N,a9 as y}from"./ui-components-CQM92IK3.js";import{u as G}from"./use-screen-XQDPI5EM.js";import{L as X}from"./landing-layout-hWcnW4wD.js";import{g as Y}from"./route-D0xh7FtZ.js";import w from"./exam-filter-CejwkMs7.js";import"./inertia-vendor-cBbDTmhJ.js";import"./ui-vendor-Ds9iwIxa.js";import"./interactive-vendor-B1OgcAgP.js";import"./index-J6afNYNJ.js";import"./app-logo-BQGZ7CFC.js";import"./main-CnGu8e_N.js";import"./theme-colors-CLpwvDr4.js";import"./use-auth-l-ShkEGs.js";import"./appearance-5ivIjthu.js";import"./language-C7bQIqs2.js";import"./notification-C3MPMjX2.js";import"./profile-toggle-CTDQohVW.js";import"./index.browser-OxPLOBIU.js";import"./search-input-BXgStIKS.js";import"./debounce-CWHP_ANh.js";const xe=({children:t})=>{var j;const{url:s,props:r}=E(),{category:i,translate:C}=r,{frontend:l}=C,[b,d]=k.useState(!1),m=Y(s),x=(j=m.view)!=null?j:"grid",{screen:p}=G(),T=(o,L)=>{const n=a({},m);return"search"in n&&delete n.search,route("category.exams",a(a({category:L||"all"},n),o))},h=o=>{F.get(T({view:o},i==null?void 0:i.slug))};return e.jsx(X,{customizable:!1,children:e.jsxs("div",{className:"container flex items-start gap-6 py-6",children:[p>768&&e.jsx(H,{className:"sticky top-24 w-64 p-4",children:e.jsx(w,{})}),e.jsxs("div",{className:"flex-1",children:[e.jsxs("div",{className:"mb-6 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[p<768&&e.jsxs(O,{open:b,onOpenChange:d,children:[e.jsx(Q,{asChild:!0,children:e.jsx(c,{size:"icon",variant:"outline",children:e.jsx(_,{className:"h-5 w-5"})})}),e.jsx(R,{side:"left",className:"border-border w-[220px]",children:e.jsx(A,{className:"h-full",children:e.jsx(w,{setOpen:d})})})]}),e.jsxs("div",{children:[e.jsxs("h2",{className:"text-2xl font-bold capitalize",children:[i?i.title:l.all," Exams"]}),i&&i.description&&e.jsx("p",{className:"text-muted-foreground mt-1 text-sm",children:i.description})]})]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(g,{delayDuration:0,children:e.jsxs(v,{children:[e.jsx(N,{asChild:!0,children:e.jsx(c,{size:"icon",variant:x==="grid"?"default":"outline",onClick:()=>h("grid"),children:e.jsx(B,{className:"h-4 w-4"})})}),e.jsx(y,{children:e.jsx("p",{children:l.grid_view})})]})}),e.jsx(g,{delayDuration:0,children:e.jsxs(v,{children:[e.jsx(N,{asChild:!0,children:e.jsx(c,{size:"icon",variant:x==="list"?"default":"outline",onClick:()=>h("list"),children:e.jsx(D,{className:"h-4 w-4"})})}),e.jsx(y,{children:e.jsx("p",{children:l.list_view})})]})})]})]}),t]})]})})};export{xe as default};
