PageSourceSearch

https://wext.ai/_next/static/chunks/pages/student/my-courses-0a6b06f623a92731.js

js wext.ai collected 2026-10-05 13:22:35 UTC 6,334 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[819],{47275:function(e,s,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/student/my-courses",function(){return n(22821)}])},22821:function(e,s,n){"use strict";n.r(s),n.d(s,{default:function(){return E}});var t=n(85893),r=n(67294),i=n(21757),o=n(68029),l=n(88329),a=n(8186),c=n(3712),u=n(74032),d=n(73636),x=n(12553),m=n(90092),f=n(5920),h=n(38488),g=n(84468),b=n(11163),p=n(39715),j=n(18318),w=n(2777);function C(e){let{courses:s}=e;return(0,t.jsx)(g.Z,{h:"100%",p:4,boxShadow:"lg",bg:"gray.50",borderRadius:"10px",children:s.map((e,s)=>(0,t.jsx)(y,{course:e},s))})}function y(e){let{course:s}=e,n=(0,b.useRouter)(),r=e=>{n.push("/student/my-courses/".concat(e))},g=(0,i.S)({base:"18px",md:"20px"}),C=(0,i.S)({base:4,md:6});return(0,t.jsx)(o.x,{p:{base:2,md:6},w:"full",children:(0,t.jsx)(o.x,{w:"full",bg:"white",boxShadow:"md",borderRadius:"15px",p:C,children:(0,t.jsx)(l.k,{w:"full",align:"center",justify:"space-between",children:(0,t.jsxs)(a.g,{align:"stretch",spacing:{base:3,md:4},w:"full",children:[(0,t.jsxs)(c.K,{direction:{base:"column",sm:"row"},justify:"space-between",align:{base:"flex-start",sm:"center"},w:"full",gap:2,children:[(0,t.jsx)(u.C,{bg:"transparent",alignItems:"center",borderRadius:"8px",textTransform:"none",p:0,children:(0,t.jsxs)(d.U,{spacing:2,children:[(0,t.jsx)(x.J,{as:p.$Hv,fontSize:g}),(0,t.jsx)(m.x,{fontSize:{base:"md",md:"xl"},fontWeight:"semibold",children:s.title})]})}),s.units>0&&s.lessons>0&&(0,t.jsxs)(m.x,{fontSize:{base:"sm",md:"sm"},fontWeight:"bold",color:"blue.500",children:[s.progress,"% Complete"]})]}),(0,t.jsxs)(c.K,{direction:{base:"column",md:"column"},w:"full",spacing:{base:2,md:3},children:[(0,t.jsx)(u.C,{bg:"transparent",textTransform:"none",p:0,children:(0,t.jsx)(m.x,{fontSize:{base:"xs",md:"sm"},color:"gray.600",fontWeight:"medium",children:s.description})}),(0,t.jsx)(f.E,{value:s.progress,size:"sm",colorScheme:"blue",w:"full",boxShadow:"sm",bgColor:"gray.200",borderRadius:"md"})]}),(0,t.jsxs)(c.K,{direction:{base:"column",sm:"row"},justify:"space-between",align:{base:"flex-start",sm:"center"},w:"full",pt:{base:2,md:4},spacing:{base:2,sm:4},children:[(0,t.jsx)(u.C,{bg:"transparent",textTransform:"none",p:0,children:(0,t.jsxs)(d.U,{spacing:2,align:"center",children:[(0,t.jsx)(x.J,{as:w.Sa3,fontSize:g}),(0,t.jsxs)(m.x,{fontSize:{base:"sm",md:"md"},color:"gray.600",fontWeight:"medium",children:[s.units," Unit",s.units>1?"s":""]})]})}),(0,t.jsx)(u.C,{bg:"transparent",textTransform:"none",p:0,w:{base:"full",sm:"auto"},children:(0,t.jsxs)(d.U,{spacing:2,align:"center",children:[(0,t.jsx)(x.J,{as:j.jyt,fontSize:g}),(0,t.jsxs)(m.x,{fontSize:{base:"sm",md:"md"},color:"gray.600",fontWeight:"medium",children:[s.lessons," Lesson",s.lessons>1?"s":""]})]})})]}),(0,t.jsx)(o.x,{pt:{base:2,md:4},children:(0,t.jsx)(h.z,{bg:"blue.500",color:"white",w:"full",onClick:()=>r(s.id),borderRadius:"10px",_hover:{bg:"blue.600"},_active:{bg:"blue.700"},size:{base:"md",md:"lg"},children:s.buttonText})})]})})})})}var v=n(69957),S=n(58896),z=n(3581),_=n(1873);let k=()=>{let{user:e}=(0,v.aC)(),s=(0,v.HQ)(),{currentPage:n,totalPages:i,goToPage:o}=(0,v.h0)(1,1),l=(0,S.TL5)(),a=(0,S.CGy)(e=>e.studentCourses.data);(0,r.useEffect)(()=>{var t;l((0,_.C)({axios:s,filter:{class:null==e?void 0:null===(t=e.studentInfo)||void 0===t?void 0:t.class,page:n,limit:30}}))},[l,n]);let c=a&&Array.isArray(a.results)?a.results.map(e=>{let{course:s}=e;return{course:s}}).map(e=>{let{course:s}=e;return{id:s.id,title:s.title,description:s.description,progress:s.progress,units:s.units.length,lessons:s.units.reduce((e,s)=>{var n;return e+((null===(n=s.lessons)||void 0===n?void 0:n.length)||0)},0),buttonText:s.progress>0?"Continue Course":"Start Course"}}):[];return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(C,{courses:c}),(0,t.jsx)(z.$,{mt:10,current:n,total:i,onPageChange:o,position:"relative"})]})};var T=n(31046);function E(){let e=(0,T.ff)("white","navy.700");return(0,t.jsx)(o.x,{bg:e,minH:"50vh",mt:{base:20,md:0},mx:"auto",px:2,py:2,children:(0,t.jsx)(k,{})})}},84468:function(e,s,n){"use strict";var t=n(85893),r=n(49381),i=n(73035),o=n(26277);let l=(0,r.G)((e,s)=>{let{size:n,variant:r,...l}=e,a=(0,i.m)("Card",{size:n,variant:r});return(0,t.jsx)(o.m.div,{ref:s,__css:a,...l})});s.Z=l},3581:function(e,s,n){"use strict";n.d(s,{$:function(){return d}});var t=n(85893),r=n(31046),i=n(90092),o=n(38488),l=n(88329),a=n(82206),c=n(12519);n(67294);var u=n(30080);let d=e=>{let{current:s,total:n,onPageChange:d,...x}=e,m=(0,r.ff)(x.bg||"navy.700",x.bg||"white"),f=(0,r.ff)("white","navy.700");if(1===n)return(0,t.jsx)(t.Fragment,{});let h=e=>{d(e)},g=e=>{"Enter"===e.key&&d(+e.target.value)};return(0,t.jsx)(l.k,{alignItems:"center",justifyContent:"center",position:"absolute",bottom:0,...x,bg:"transparent",w:"full",children:(0,t.jsxs)(l.k,{alignItems:"center",justifyContent:"center",children:[s>1&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(a.I,{type:"number",w:10,textAlign:"center",p:0,fontSize:14,fontWeight:5,placeholder:s.toString(),_focus:{borderColor:m},color:m,onKeyDown:g,min:1,max:s}),(0,t.jsx)(c.h,{icon:(0,t.jsx)(u.xdf,{size:30}),"aria-label":"left-arrow",color:m,bg:"transparent",onClick:()=>h(1)}),(0,t.jsx)(c.h,{icon:(0,t.jsx)(u.sG8,{size:30}),"aria-label":"left-arrow",color:m,bg:"transparent",onClick:()=>h(s-1)})]}),(0,t.jsx)(l.k,{gap:4,alignItems:"center",justifyContent:"center",children:(()=>{let e=[];
1if(n<=8)for(let s=1;s<=n;s++)e.push(s);else{let t=Math.max(Math.min(s-2,n-4),1),r=Math.min(s+2,n);for(let s=t;s<=r;s++)e.push(s);1!==t&&e.unshift("..."),r!==n&&e.push("...")}return e.map((e,n)=>"..."===e?(0,t.jsx)(i.x,{mr:2,ml:2,color:"gray.400",children:"..."},n):(0,t.jsx)(o.z,{isActive:e===s,onClick:()=>h(e),w:5,borderRadius:"50%",bg:m,color:f,children:e},n))})()}),s<n&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(c.h,{icon:(0,t.jsx)(u.AeI,{size:30}),"aria-label":"right-arrow",color:m,bg:"transparent",onClick:()=>h(s+1)}),(0,t.jsx)(c.h,{icon:(0,t.jsx)(u.eDK,{size:30}),"aria-label":"right-arrow",color:m,bg:"transparent",onClick:()=>h(n)}),(0,t.jsx)(a.I,{type:"number",w:10,textAlign:"center",p:0,fontSize:14,fontWeight:5,placeholder:s.toString(),_focus:{borderColor:m},color:m,onKeyDown:g,min:s,max:n})]})]})})}}},function(e){e.O(0,[9774,2888,179],function(){return e(e.s=47275)}),_N_E=e.O()}]);

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.