PageSourceSearch

https://terraincognitaacademy.com/assets/InstructorDashboard-DAyKwuyk.js

js terraincognitaacademy.com collected 2026-10-09 22:02:21 UTC 20,500 bytes, 7 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/CourseBuilder-0OAyACsb.js","assets/query-603sR3e5.js","assets/index-Bgl7Qh3e.js","assets/router-wEt8kAIS.js","assets/ui-vDfEnoEi.js","assets/charts-Cjj8e2PO.js","assets/supabase-V1kumFDL.js","assets/motion-DGqSTYfv.js","assets/index-ClHCw_5W.css","assets/Certificate-1BJl_kBf.js","assets/browser-jMnWQhOo.js","assets/textarea-C-OKFypY.js","assets/switch-DKQF4G2_.js","assets/ScheduleDateTimePicker-tAagwTiG.js","assets/calendar-BbxN7UvB.js","assets/startOfMonth-B9_XjsQ0.js","assets/addMonths-Jr-IABiE.js","assets/subDays-CRFeQjuv.js","assets/addYears-B7Fv_7zj.js","assets/chevron-left-BaPe8OMM.js","assets/calendar-DjVzY4xv.js","assets/breadcrumb-B2LP5Qcb.js","assets/RichTextEditor-D0KAM8j6.js","assets/link-qDSz15mH.js","assets/list-CcYIRiPb.js","assets/image-CpEvssAc.js","assets/music-lekusMnX.js","assets/video-ehTZDQ2d.js","assets/alert-dialog-DGUlZ9QV.js","assets/sortable.esm-0LX9BeL7.js","assets/house-Dd8A855d.js","assets/grip-vertical-C8Kdi8xH.js"])))=>i.map(i=>d[i]);
2import{W as c,Y as u,J as y,$ as o,_ as g,h as Z,aF as I,i,A as ee,aG as B,a1 as se,k as te,au as Q,s as j,g as re,u as S,q as ae,N as ne,B as E,aH as ie,av as le,aI as D,a3 as K,m as O,I as ce,o as oe,am as de,j as me,aJ as ue,aK as xe,ar as he}from"./index-Bgl7Qh3e.js";import{u as k,j as e,c as je,a as C,d as G}from"./query-603sR3e5.js";import{A as ge,a as pe,b as fe,c as Ne,d as be,e as ve,f as we,g as ye,h as Ce}from"./alert-dialog-DGUlZ9QV.js";import{R as _e}from"./RevenueForecast-DnkZWkOM.js";import{L as d,u as Se}from"./router-wEt8kAIS.js";import{G as Ee}from"./GamificationPanel-B7wbzUD2.js";import{O as ke}from"./OnboardingGuide-BNtEadiX.js";import{P as Pe,a as qe,b as R,c as Fe,d as Ae,e as De,f as Re}from"./pagination-Dm50nGBT.js";import{E as M}from"./euro-CbUcAGVA.js";import"./ui-vDfEnoEi.js";import"./charts-Cjj8e2PO.js";import"./supabase-V1kumFDL.js";import"./motion-DGqSTYfv.js";import"./alert-Cz-TNOSv.js";import"./circle-alert-2kyiO4q7.js";import"./calendar-DjVzY4xv.js";import"./subDays-CRFeQjuv.js";import"./trophy-jdeKVkg1.js";import"./flame-DnGU-9bX.js";import"./video-ehTZDQ2d.js";import"./file-text-D59XcTc4.js";import"./chevron-left-BaPe8OMM.js";import"./ellipsis-R7e0Metg.js";const Me=({instructorId:m})=>{const{data:x,isLoading:f}=k({queryKey:["instructor-revenue-stats",m],enabled:!!m,queryFn:async()=>{const{data:t,error:a}=await j.from("instructor_revenue_stats").select("*").eq("instructor_id",m).single();if(a)throw a;return t}}),{data:b,isLoading:n}=k({queryKey:["recent-earnings",m],enabled:!!m,queryFn:async()=>{const{data:t,error:a}=await j.from("instructor_earnings").select(`
3          *,
4          courses (
5            title
6          )
7        `).eq("instructor_id",m).order("created_at",{ascending:!1}).limit(5);if(a)throw a;return t}}),N=t=>{switch(t){case"completed":return"bg-green-500/10 text-green-500";case"pending":return"bg-yellow-500/10 text-yellow-500";case"refunded":return"bg-red-500/10 text-red-500";default:return"bg-muted"}};return f||n?e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[e.jsxs(c,{className:"lg:col-span-2",children:[e.jsxs(u,{children:[e.jsx(y,{className:"h-6 w-32"}),e.jsx(y,{className:"h-4 w-48"})]}),e.jsx(o,{children:e.jsx("div",{className:"space-y-4",children:[1,2,3].map(t=>e.jsx(y,{className:"h-16 w-full"},t))})})]}),e.jsxs(c,{children:[e.jsx(u,{children:e.jsx(y,{className:"h-6 w-32"})}),e.jsx(o,{children:e.jsx("div",{className:"space-y-4",children:[1,2,3].map(t=>e.jsx(y,{className:"h-12 w-full"},t))})})]})]}):e.jsxs("div",{className:"space-y-6",children:[e.jsx(_e,{instructorId:m}),e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6",children:[e.jsxs(c,{className:"lg:col-span-2 bg-card/50 backdrop-blur-sm",children:[e.jsx(u,{children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{children:[e.jsxs(g,{className:"flex items-center gap-2",children:[e.jsx(Z,{className:"w-5 h-5 text-primary"}),"Recent Earnings"]}),e.jsx(I,{children:"Your latest course sales"})]}),e.jsx(i,{variant:"outline",size:"sm",asChild:!0,children:e.jsxs(d,{to:"/instru
7ctor/earnings",children:["View All",e.jsx(ee,{className:"w-4 h-4 ml-2"})]})})]})}),e.jsx(o,{children:!b||b.length===0?e.jsxs("div",{className:"text-center py-8",children:[e.jsx(B,{className:"w-12 h-12 mx-auto mb-3 text-muted-foreground/50"}),e.jsx("p",{className:"text-muted-foreground",children:"No earnings yet"}),e.jsx("p",{className:"text-sm text-muted-foreground/70 mt-1",children:"Start selling your courses to see earnings here"})]}):e.jsx("div",{className:"space-y-3",children:b.map(t=>e.jsxs("div",{className:"flex items-center justify-between p-4 rounded-lg border bg-card hover:bg-accent/5 transition-colors",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"font-medium truncate mb-1",children:t.courses?.title||"Course"}),e.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[e.jsx("span",{children:se(new Date(t.created_at),{addSuffix:!0})}),e.jsx(te,{variant:"outline",className:N(t.status),children:t.status})]})]}),e.jsxs("div",{className:"text-right ml-4",children:[e.jsxs("p",{className:"font-bold text-lg text-primary",children:["+$",Number(t.net_amount).toFixed(2)]}),e.jsxs("p",{className:"text-xs text-muted-foreground",children:["$",Number(t.amount).toFixed(2)," gross"]})]})]},t.id))})})]}),e.jsxs("div",{className:"space-y-6",children:[e.jsxs(c,{className:"bg-gradient-to-br from-primary/10 to-primary/5 border-primary/20",children:[e.jsx(u,{children:e.jsxs(g,{className:"flex items-center gap-2 text-lg",children:[e.jsx(Q,{className:"w-5 h-5 text-primary"}),"Total Revenue"]})}),e.jsx(o,{children:e.jsxs("div",{className:"space-y-4",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-sm text-muted-foreground mb-1",children:"Net Earnings"}),e.jsxs("p",{className:"text-3xl font-bold text-primary",children:["$",Number(x?.net_revenue||0).toFixed(2)]})]}),e.jsxs("div",{className:"pt-4 border-t",children:[e.jsxs("div",{className:"flex justify-between text-sm mb-2",children:[e.jsx("span",{className:"text-muted-foreground",children:"Gross Revenue"}),e.jsxs("span",{className:"font-medium",children:["$",Number(x?.gross_revenue||0).toFixed(2)]})]}),e.jsxs("div",{className:"flex justify-between text-sm mb-2",children:[e.jsx("span",{className:"text-muted-foreground",children:"Platform Fees"}),e.jsxs("span",{className:"font-medium text-red-500",children:["-$",Number(x?.total_fees||0).toFixed(2)]})]}),e.jsxs("div",{className:"flex justify-between text-sm",children:[e.jsx("span",{className:"text-muted-foreground",children:"Paid Out"}),e.jsxs("span",{className:"font-medium text-green-500",children:["$",Number(x?.paid_out_amount||0).toFixed(2)]})]})]})]})})]}),e.jsxs(c,{className:"bg-gradient-to-br from-accent/10 to-accent/5 border-accent/20",children:[e.jsx(u,{children:e.jsxs(g,{className:"flex items-center gap-2 text-lg",children:[e.jsx(B,{className:"w-5 h-5 text-accent"}),"Available Balance"]})}),e.jsxs(o,{children:[e.jsxs("p",{className:"text-3xl font-bold text-accent mb-4",children:["$",Number(x?.available_balance||0).toFixed(2)]}),e.jsx(i,{className:"w-full",asChild:!0,children:e.jsx(d,{to:"/instructor/earnings",children:"Request Payout"})})]})]}),e.jsx(c,{className:"bg-card/50 backdrop-blur-sm",children:e.jsx(o,{className:"pt-6",children:e.jsxs("div",{className:"grid grid-cols-2 gap-4 text-center",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-bold text-primary",children:x?.total_enrollments||0}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Total Sales"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-bold text-secondary",children:x?.courses_with_sales||0}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Courses Sold"})]})]})})})]})]})]})},Te=()=>he(()=>import("./CourseBuilder-0OAyACsb.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31])),_=25,is=()=>{const m=je(),x=Se(),[f,b]=C.useState(""),[n,N]=C.useState(1);C.useEffect(()=>{Te()},[]);const{user:t}=re(),{data:a}=k({queryKey:["instructor-courses",t?.id],enabled:!!t,queryFn:async()=>{const{data:s,error:r}=await j.from("courses").select("*").eq("instructor_id",t.id).order("created_at",{ascending:!1});if(r)throw r;return s}}),{data:P}=k({queryKey:["instructor-all-enrollments",t?.id],enabled:!!t,queryFn:async()=>{const{data:s,error:r}=await j.from("courses").select("id, price").eq("instructor_id",t.id);if(r)throw r;if(!s||s.length===0)return{counts:{},paidCounts:{},uniqueStudentCount:0,totalRevenue:0};const v=s.map(l=>l.id),w={};
7s.forEach(l=>{w[l.id]=l.price||0});const{data:X,error:z}=await j.from("course_enrollments").select("course_id, user_id, payment_id").in("course_id",v);if(z)throw z;const F={},A={},L=new Set;let $=0;return X?.forEach(l=>{F[l.course_id]=(F[l.course_id]||0)+1,L.add(l.user_id),l.payment_id&&(A[l.course_id]=(A[l.course_id]||0)+1,$+=w[l.course_id]||0)}),{counts:F,paidCounts:A,uniqueStudentCount:L.size,totalRevenue:$}}}),Y=P?.counts||{},H=G({mutationFn:async s=>{const{error:r}=await j.from("courses").delete().eq("id",s);if(r)throw r},onSuccess:()=>{S.success("Course deleted successfully"),m.invalidateQueries({queryKey:["instructor-courses"]})},onError:s=>{S.error(s.message||"Failed to delete course")}}),q=G({mutationFn:async s=>{const{data:{session:r}}=await j.auth.getSession();if(!r)throw new Error("Not authenticated");const{data:v,error:w}=await j.functions.invoke("clone-course",{body:{courseId:s}});if(w)throw w;if(v?.error)throw new Error(v.error);return v},onSuccess:s=>{S.success("Course cloned successfully! Redirecting to edit..."),m.invalidateQueries({queryKey:["instructor-courses"]}),x(`/instructor/courses/${s.newCourseSlug}/edit`)},onError:s=>{S.error(s.message||"Failed to clone course")}}),U=P?.totalRevenue||0,V=P?.uniqueStudentCount||0,p=C.useMemo(()=>{if(!a)return[];if(!f.trim())return a;const s=f.toLowerCase().trim();return a.filter(r=>r.title.toLowerCase().includes(s)||r.short_description?.toLowerCase().includes(s)||r.slug.toLowerCase().includes(s))},[a,f]),h=Math.ceil(p.length/_),T=C.useMemo(()=>{const s=(n-1)*_;return p.slice(s,s+_)},[p,n]),J=s=>{b(s),N(1)},W=()=>{const s=[];if(h<=7)for(let r=1;r<=h;r++)s.push(r);else{s.push(1),n>3&&s.push("ellipsis");for(let r=Math.max(2,n-1);r<=Math.min(h-1,n+1);r++)s.push(r);n<h-2&&s.push("ellipsis"),s.push(h)}return s};return e.jsxs(e.Fragment,{children:[e.jsx(ae,{title:"Instructor Dashboard - Manage Courses & Track Revenue",description:"Manage your spiritual courses, track student enrollments, and monitor your earnings. Your instructor command center.",keywords:["instructor dashboard","course management","earnings","teaching"]}),e.jsxs("div",{className:"min-h-screen bg-background",children:[e.jsx(ne,{}),e.jsx("main",{className:"pt-28 sm:pt-32 pb-8 px-4",children:e.jsxs("div",{className:"max-w-7xl mx-auto",children:[e.jsxs("div",{className:"flex justify-between items-center mb-12",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-4xl font-bold mb-2 bg-gradient-cosmic bg-clip-text text-transparent",children:"Instructor Dashboard"}),e.jsx("p",{className:"text-muted-foreground",children:"Manage your courses and track student progress"})]}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx(i,{asChild:!0,variant:"outline",size:"lg",children:e.jsxs(d,{to:"/instructor/courses",children:[e.jsx(E,{className:"w-5 h-5 mr-2"}),"Manage Courses"]})}),e.jsx(i,{asChild:!0,variant:"outline",size:"lg",children:e.jsxs(d,{to:"/instructor/earnings",children:[e.jsx(M,{className:"w-5 h-5 mr-2"}),"Earnings"]})}),e.jsx(i,{asChild:!0,variant:"outline",size:"lg",children:e.jsxs(d,{to:"/instructor/analytics",children:[e.jsx(ie,{className:"w-5 h-5 mr-2"}),"Analytics"]})}),e.jsx(i,{asChild:!0,variant:"outline",size:"lg",children:e.jsxs(d,{to:"/messages",children:[e.jsx(le,{className:"w-5 h-5 mr-2"}),"Messages"]})}),e.jsx(i,{asChild:!0,size:"lg",className:"bg-gradient-cosmic",children:e.jsxs(d,{to:"/instructor/courses/new",children:[e.jsx(D,{className:"w-5 h-5 mr-2"}),"Create Course"]})})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-12",children:[e.jsxs(c,{className:"bg-gradient-to-br from-primary/10 to-primary/5 backdrop-blur-sm border-primary/20 hover:border-primary/40 transition-all",children:[e.jsx(u,{className:"pb-3",children:e.jsx(g,{className:"text-sm font-medium text-muted-foreground",children:"Total Courses"})}),e.jsxs(o,{children:[e.jsxs("div",{className:"flex items-baseline justify-between",children:[e.jsx("p",{className:"text-4xl font-bold text-primary",children:a?.length||0}),e.jsx(E,{className:"w-8 h-8 text-primary/50"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-2",children:[a?.filter(s=>s.is_published).length||0," published"]})]})]}),e.jsxs(c,{className:"bg-gradient-to-br from-accent/10 to-accent/5 backdrop-blur-sm border-accent/20 hover:border-accent/40 transition-all",children:[e.jsx(u,{className:"pb-3",children:e.jsx(g,{className:"text-sm font-medium text-muted-foreground",children:"Total Students"})}),e.jsxs(o,{children:[e.jsxs("div",{className:"flex items-baseline justify-between",children:[e.jsx("p",{className:"text-4xl font-bold text-accent",children:V}),e.jsx(K,{className:"w-8 h-8 text-accent/50"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Across all courses"})]})]}),e.jsxs(c,{className:"bg-gradient-to-br from-green-500/10 to-green-500/5 backdrop-blur-sm border-green-500/20 hover:border-green-500/40 transition-all",children:[e.jsx(u,{className:"pb-3",children:e.jsx(g,{className:"text-sm font-medium text-muted-foreground",children:"Total Revenue"})}),e.jsxs(o,{children:[e.jsxs("div",{className:"flex items-baseline justify-between",children:[e.jsxs("p",{className:"text-4xl font-bold text-green-500",children:["€",U.toFixed(0)]}),e.jsx(M,{className:"w-8 h-8 text-green-500/50"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Estimated earnings"})]})]}),e.jsxs(c,{className:"bg-gradient-to-br from-blue-500/10 to-blue-500/5 backdrop-blur-sm border-blue-500/20 hover:border-blue-500/40 transition-all",children:[e.jsx(u,{className:"pb-3",children:e.jsx(g,{className:"text-sm font-medium text-muted-foreground",children:"Avg. Rating"})}),e.jsxs(o,{children:[e.jsxs("div",{className:"flex items-baseline justify-between",children:[e.jsx("p",{className:"text-4xl font-bold text-blue-500",children:"4.8"}),e.jsx(Q,{className:"w-8 h-8 text-blue-500/50"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Based on reviews"})]})]})]}),e.jsx("div",{className:"mb-12",children:e.jsx(Me,{instructorId:t?.id})}),t&&e.jsx("div",{className:"mb-12",children:e.jsx(Ee,{userId:t.id,variant:"compact"})}),t&&e.jsx(ke,{type:"instructor"}),e.jsxs(c,{className:"bg-card/50 backdrop-blur-sm border-border/50",children:[e.jsx(u,{children:e.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx(g,{children:"Your Courses"}),e.jsxs(I,{children:["Manage and edit your courses",p.length!==a?.length&&e.jsxs("span",{className:"ml-2",children:["(",p.length," of ",a?.length," shown)"]})]})]}),e.jsxs("div",{className:"flex items-center gap-3 w-full sm:w-auto",children:[e.jsxs("div",{className:"relative flex-1 sm:flex-none sm:w-64",children:[e.jsx(O,{className:"absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground"}),e.jsx(ce,{placeholder:"Search courses...",value:f,onChange:s=>J(s.target.value),className:"pl-9"})]}
7),e.jsx(i,{asChild:!0,size:"sm",children:e.jsxs(d,{to:"/instructor/courses/new",children:[e.jsx(D,{className:"w-4 h-4 mr-2"}),"New Course"]})})]})]})}),e.jsxs(o,{children:[!a||a.length===0?e.jsxs("div",{className:"text-center py-12",children:[e.jsx(E,{className:"w-16 h-16 mx-auto mb-4 text-muted-foreground/50"}),e.jsx("p",{className:"text-xl text-muted-foreground mb-2",children:"No courses yet"}),e.jsx("p",{className:"text-sm text-muted-foreground mb-6",children:"Create your first course to start teaching"}),e.jsx(i,{asChild:!0,children:e.jsxs(d,{to:"/instructor/courses/new",children:[e.jsx(D,{className:"w-4 h-4 mr-2"}),"Create Your First Course"]})})]}):T.length===0?e.jsxs("div",{className:"text-center py-12",children:[e.jsx(O,{className:"w-12 h-12 mx-auto mb-4 text-muted-foreground/50"}),e.jsx("p",{className:"text-lg text-muted-foreground mb-2",children:"No courses found"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Try a different search term"})]}):e.jsx("div",{className:"space-y-4",children:T.map(s=>e.jsx(c,{className:"group hover:border-primary/50 hover:shadow-lg transition-all duration-300",children:e.jsx(o,{className:"p-6",children:e.jsxs("div",{className:"flex items-start gap-6",children:[e.jsx("div",{className:"flex-shrink-0 w-32 h-24 rounded-lg overflow-hidden bg-muted",children:s.thumbnail_url?e.jsx("img",{src:oe.thumbnailLarge(s.thumbnail_url)||s.thumbnail_url,alt:s.title,className:"w-full h-full object-cover group-hover:scale-105 transition-transform duration-300",loading:"lazy",decoding:"async",width:800,height:600}):e.jsx("div",{className:"w-full h-full flex items-center justify-center",children:e.jsx(E,{className:"w-8 h-8 text-muted-foreground/50"})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-start justify-between gap-4 mb-2",children:[e.jsx("h3",{className:"text-xl font-bold group-hover:text-primary transition-colors truncate",children:s.title}),e.jsx("span",{className:`flex-shrink-0 px-3 py-1 rounded-full text-xs font-medium ${s.is_published?"bg-accent/20 text-accent border border-accent/30":"bg-muted border border-border"}`,children:s.is_published?"Published":"Draft"})]}),e.jsx("p",{className:"text-muted-foreground mb-4 line-clamp-2",children:s.short_description||"No description"}),e.jsxs("div",{className:"flex items-center gap-6 text-sm",children:[e.jsxs("span",{className:"flex items-center gap-2 text-muted-foreground",children:[e.jsx(K,{className:"w-4 h-4"}),e.jsx("span",{className:"font-medium",children:Y?.[s.id]||0})," students"]}),e.jsxs("span",{className:"flex items-center gap-2 text-muted-foreground",children:[e.jsx(M,{className:"w-4 h-4"}),e.jsxs("span",{className:"font-medium",children:["€",s.price]})]}),s.level&&e.jsx("span",{className:"px-2 py-1 rounded bg-muted text-xs font-medium",children:s.level})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(i,{asChild:!0,variant:"outline",size:"sm",children:e.jsx(d,{to:`/instructor/courses/${s.slug}/edit`,children:"Edit"})}),e.jsx(i,{asChild:!0,variant:"ghost",size:"sm",children:e.jsxs(d,{to:`/courses/${s.slug}`,children:[e.jsx(de,{className:"w-4 h-4 mr-2"}),"View"]})}),e.jsx(i,{variant:"ghost",size:"sm",onClick:()=>q.mutate(s.id),disabled:q.isPending,children:q.isPending?e.jsx(me,{className:"w-4 h-4 animate-spin"}):e.jsxs(e.Fragment,{children:[e.jsx(ue,{className:"w-4 h-4 mr-2"}),"Clone"]})}),e.jsxs(ge,{children:[e.jsx(pe,{asChild:!0,children:e.jsx(i,{variant:"ghost",size:"sm",className:"text-destructive hover:text-destructive",children:e.jsx(xe,{className:"w-4 h-4"})})}),e.jsxs(fe,{children:[e.jsxs(Ne,{children:[e.jsx(be,{children:"Delete Course?"}),e.jsxs(ve,{children:['This will permanently delete "',s.title,'" and all its modules, lessons, and forum topics. This action cannot be undone.']})]}),e.jsxs(we,{children:[e.jsx(ye,{children:"Cancel"}),e.jsx(Ce,{onClick:()=>H.mutate(s.id),className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:"Delete"})]})]})]})]})]})})},s.id))}),h>1&&e.jsxs("div",{className:"mt-6 flex flex-col sm:flex-row items-center justify-between gap-4",children:[e.jsxs("p",{className:"text-sm text-muted-foreground",children:["Showing ",(n-1)*_+1," to ",Math.min(n*_,p.length)," of ",p.length," courses"]}),e.jsx(Pe,{children:e.jsxs(qe,{children:[e.jsx(R,{children:e.jsx(Fe,{onClick:()=>N(s=>
7Math.max(1,s-1)),className:n===1?"pointer-events-none opacity-50":"cursor-pointer"})}),W().map((s,r)=>e.jsx(R,{children:s==="ellipsis"?e.jsx(Ae,{}):e.jsx(De,{onClick:()=>N(s),isActive:n===s,className:"cursor-pointer",children:s})},r)),e.jsx(R,{children:e.jsx(Re,{onClick:()=>N(s=>Math.min(h,s+1)),className:n===h?"pointer-events-none opacity-50":"cursor-pointer"})})]})})]})]})]})]})})]})]})};export{is as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.