import{x as w,f as C,y as S,z as D,e as x,a as e,i as A,t as p,b as l,w as n,d as s,n as f,u as o,l as d,g as b,A as v,o as y}from"./app-iLLm8RtX.js";const E={class:"bg-white shadow mb-6"},N={class:"px-6 py-4"},z={class:"flex justify-between items-center"},V={class:"text-2xl font-bold text-gray-900"},_={key:0,class:"text-gray-600"},B={class:"flex items-center space-x-1"},L={class:"relative"},P={class:"absolute left-0 mt-1 w-48 bg-white rounded-md shadow-lg z-50 border"},M={class:"relative"},$={class:"absolute left-0 mt-1 w-48 bg-white rounded-md shadow-lg z-50 border"},O={__name:"PartnerNavigation",props:{title:String,subtitle:String},setup(m){const h=w(),r=C(null),i=a=>{const t=h.url;return a==="/partner/dashboard"?t==="/partner/dashboard"||t==="/partner/dashboard/":t.startsWith(a)},g=a=>{r.value=r.value===a?null:a},u=()=>{r.value=null},c=a=>{a.target.closest(".relative")||u()};return S(()=>{document.addEventListener("click",c)}),D(()=>{document.removeEventListener("click",c)}),(a,t)=>(y(),x("div",E,[e("div",N,[e("div",z,[e("div",null,[e("h1",V,p(m.title),1),m.subtitle?(y(),x("p",_,p(m.subtitle),1)):A("",!0)]),e("nav",B,[l(o(d),{href:"/partner/dashboard",class:f([i("/partner/dashboard")?"bg-orange-100 text-orange-800":"text-gray-700 hover:bg-gray-100","px-3 py-2 rounded-md text-sm font-medium flex items-center"])},{default:n(()=>[...t[2]||(t[2]=[e("i",{class:"fas fa-tachometer-alt mr-1"},null,-1),s("Dashboard ",-1)])]),_:1},8,["class"]),e("div",L,[e("button",{onClick:t[0]||(t[0]=k=>g("students")),class:f([[i("/partner/students")?"bg-orange-100 text-orange-800":"text-gray-700 hover:bg-gray-100",r.value==="students"?"bg-gray-100":""],"px-3 py-2 rounded-md text-sm font-medium flex items-center"])},[t[3]||(t[3]=e("i",{class:"fas fa-users mr-1"},null,-1)),t[4]||(t[4]=s("Students ",-1)),e("i",{class:f([r.value==="students"?"fa-chevron-up":"fa-chevron-down","fas ml-1 text-xs"])},null,2)],2),b(e("div",P,[l(o(d),{href:"/partner/students",onClick:u,class:"block px-4 py-2 text-sm text-gray-700 hover:bg-orange-50"},{default:n(()=>[...t[5]||(t[5]=[e("i",{class:"fas fa-list mr-2"},null,-1),s("All Students ",-1)])]),_:1}),l(o(d),{href:"/partner/students/create",onClick:u,class:"block px-4 py-2 text-sm text-gray-700 hover:bg-orange-50"},{default:n(()=>[...t[6]||(t[6]=[e("i",{class:"fas fa-user-plus mr-2"},null,-1),s("Add Student ",-1)])]),_:1})],512),[[v,r.value==="students"]])]),l(o(d),{href:"/partner/courses",class:f([i("/partner/courses")?"bg-orange-100 text-orange-800":"text-gray-700 hover:bg-gray-100","px-3 py-2 rounded-md text-sm font-medium flex items-center"])},{default:n(()=>[...t[7]||(t[7]=[e("i",{class:"fas fa-book mr-1"},null,-1),s("Courses ",-1)])]),_:1},8,["class"]),e("div",M,[e("button",{onClick:t[1]||(t[1]=k=>g("enrollments")),class:f([[i("/partner/enrollments")||i("/partner/certificates")||i("/partner/manual-certificates")?"bg-orange-100 text-orange-800":"text-gray-700 hover:bg-gray-100",r.value==="enrollments"?"bg-gray-100":""],"px-3 py-2 rounded-md text-sm font-medium flex items-center"])},[t[8]||(t[8]=e("i",{class:"fas fa-graduation-cap mr-1"},null,-1)),t[9]||(t[9]=s("Enrollments ",-1)),e("i",{class:f([r.value==="enrollments"?"fa-chevron-up":"fa-chevron-down","fas ml-1 text-xs"])},null,2)],2),b(e("div",$,[l(o(d),{href:"/partner/enrollments",onClick:u,class:"block px-4 py-2 text-sm text-gray-700 hover:bg-orange-50"},{default:n(()=>[...t[10]||(t[10]=[e("i",{class:"fas fa-list mr-2"},null,-1),s("All Enrollments ",-1)])]),_:1}),l(o(d),{href:"/partner/certificates",onClick:u,class:"block px-4 py-2 text-sm text-gray-700 hover:bg-orange-50"},{default:n(()=>[...t[11]||(t[11]=[e("i",{class:"fas fa-certificate mr-2"},null,-1),s("Certificates ",-1)])]),_:1}),l(o(d),{href:"/partner/manual-certificates",onClick:u,class:"block px-4 py-2 text-sm text-gray-700 hover:bg-orange-50"},{default:n(()=>[...t[12]||(t[12]=[e("i",{class:"fas fa-upload mr-2"},null,-1),s("Manual Records ",-1)])]),_:1})],512),[[v,r.value==="enrollments"]])]),l(o(d),{href:"/partner/logout",method:"post",class:"px-3 py-2 rounded-md text-sm font-medium text-red-600 hover:bg-red-50 flex items-center"},{default:n(()=>[...t[13]||(t[13]=[e("i",{class:"fas fa-sign-out-alt mr-1"},null,-1),s("Logout ",-1)])]),_:1})])])])]))}};export{O as _};
