PageSourceSearch

https://www.codedex.io/_next/static/chunks/pages/admin/course-projects-b70a2da5d7918e4b.js

js codedex.io collected 2026-09-25 14:55:20 UTC 22,168 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7258],{67978:function(n,e,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/course-projects",function(){return t(72351)}])},89205:function(n,e,t){"use strict";t.d(e,{Z:function(){return community_PinProjectShowCase}});var r=t(82729),o=t(85893),i=t(39327),s=t(39828),l=t(92369);let{firestore:a}=(0,l.UM)();async function pinProject(n){let{communityName:e="project-showcase",projectId:t,pinStatus:r}=n;if(!e||!t)throw Error("postId and uid are required fields.");try{let n=(0,s.JU)(a,"community",e,"posts",t),o=await (0,s.QT)(n),i=o.data();if(i)return await (0,s.r7)(n,{pinned:r}),{status:200,message:"Project pinned successfully ."};throw Error("Unauthorized: You don't have permission to update this post.")}catch(n){throw Error(n)}}var c=t(67294),d=t(47010),u=t(55788),p=t(19521);function _templateObject(){let n=(0,r._)(["\n  padding: 8px 12px;\n  display: flex;\n  align-items: center;\n  gap: 12px;\n  border-radius: 4px;\n  color: ",";\n\n  &.delete {\n    p {\n      color: ",";\n    }\n\n    svg {\n      path {\n        /* fill: ","; */\n      }\n    }\n\n    :hover {\n      background-color: ",";\n\n      p {\n        color: ",";\n      }\n\n      svg {\n        path {\n          fill: ",";\n        }\n      }\n    }\n  }\n\n  .dropdown-text {\n    color: ",";\n    font-size: 16px;\n    font-weight: 500;\n    line-height: 150%;\n  }\n\n  :hover {\n    background-color: ",";\n\n    p {\n      color: ",";\n    }\n\n    svg {\n      path {\n        fill: ",";\n      }\n    }\n  }\n"]);return _templateObject=function(){return n},n}let m=p.default.div.withConfig({componentId:"sc-64830591-0"})(_templateObject(),n=>{let{theme:e}=n;return e.colors.text.primary},n=>{let{theme:e}=n;return e.colors.text.accent.red},n=>{let{theme:e}=n;return e.colors.text.accent.red},n=>{let{theme:e}=n;return e.colors.background.grey.tertiary},n=>{let{theme:e}=n;return e.colors.text.accent.red},n=>{let{theme:e}=n;return e.colors.text.accent.red},n=>{let{theme:e}=n;return e.colors.text.primary},n=>{let{theme:e}=n;return e.colors.background.grey.tertiary},n=>{let{theme:e}=n;return e.colors.text.accent.blue},n=>{let{theme:e}=n;return e.colors.text.accent.blue});var community_PinProjectShowCase=function(n){let{projectId:e,pinnedStatus:t,isUserAdmin:r}=n,[s,l]=(0,c.useState)(!1),[a,p]=(0,c.useState)(t);async function pinUnpin(n){n.stopPropagation(),l(!0);let t=await pinProject({projectId:e,pinStatus:!a});200===t.status&&(p(!a),l(!1))}if(r)return s?(0,o.jsxs)(m,{children:[a?(0,o.jsx)(u.$iT,{color:"#F43F5E"}):(0,o.jsx)(i.lYB,{}),(0,o.jsx)(d.Z,{color:"#2CBAFF",size:16})]}):(0,o.jsxs)(m,{onClick:n=>pinUnpin(n),children:[a?(0,o.jsx)(u.$iT,{color:"#F43F5E"}):(0,o.jsx)(i.lYB,{}),a?"Remove staff pick":"Add to Staff Picks"]})}},44510:function(n,e,t){"use strict";var r=t(67294),o=t(11163);e.Z=function(n){let{community:e,filter:t,refreshTrigger:i=null}=n,s=(0,o.useRouter)(),[l,a]=(0,r.useState)([]),[c,d]=(0,r.useState)(!1),[u,p]=(0,r.useState)(1);return(0,r.useEffect)(()=>{async function getCommunityPosts(){let n="".concat(e,"-").concat(t.internalName,"-").concat(i),r=JSON.parse(sessionStorage.getItem(n));if((null==r?void 0:r.posts)||(r={}),r.posts)a(null==r?void 0:r.posts),p(null==r?void 0:r.currentPage),(null==r?void 0:r.posts.length)===0&&d(!0);else{let o=t.api,i=await fetch(o),s=await i.json(),l=s.posts;r={posts:[...l],currentPage:"leaderboards"===e?null==s?void 0:s.lastUserId:1},sessionStorage.setItem(n,JSON.stringify({...r})),a(l),p(1),0===l.length&&d(!0)}}a([]),getCommunityPosts()},[e,null==t?void 0:t.api,null==t?void 0:t.internalName,i]),(0,r.useEffect)(()=>{function logScrollPosition(){let n="".concat(e,"-").concat(t.internalName,"-").concat(i,"-scroll");0!=window.scrollY&&sessionStorage.setItem(n,JSON.stringify(window.scrollY))}return window.addEventListener("scroll",logScrollPosition),()=>{window.removeEventListener("scroll",logScrollPosition)}},[s.asPath,e,t.internalName,i]),{posts:l,noMorePosts:c,currentPage:u}}},21264:function(n,e,t){"use strict";var r=t(85893);e.Z=function(n){let{...e}=n;return(0,r.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",...e,children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15 1.66699H13.3333V3.33366H15V1.66699ZM3.33323 3.33367H8.33323V5.00034H3.33323V16.667H14.9999V11.667H16.6666V18.3337L16.6666 18.3337H1.66656V16.667V5.00034V3.33367H3.33323ZM6.66672 10.0003H5.00005V13.3337V15.0003V15.0003H10.0001V13.3337L11.6666 13.3337V11.667H9.9999V13.3337L6.66672 13.3337V10.0003ZM9.99995 8.33367H8.33333V10.0003H6.66667V8.33361H8.33328V6.66701H9.9999V5.00034H11.6666V6.66701H9.99995V8.33367ZM11.6668 3.33367H13.3334V5.00034H11.6668V3.33367ZM14.9999 3.33367H16.6666V5.00034H18.3332V6.66701H16.6666V8.33367H15V10.0003H13.3333V8.33361H14.9999V6.66701H16.6666V5.00034H14.9999V3.33367ZM11.6668 10.0003H13.3334V11.667H11.6668V10.0003Z",fill:"#64748B"})})}},65919:function(n,e,t){"use strict";var r=t(85893);e.Z=function(n){let{...e}=n;return(0,r.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:(0,r.jsx)("path",{d:"M9.75 16.5H8.25V13.5H3V10.5H4.5V12H13.5V10.5H15V13.5H9.75V16.5ZM6 10.5H4.5V9H6V10.5ZM13.5 10.5H12V9H13.5V10.5ZM7.5 9H6V6H7.5V9ZM12 9H10.5V6H12V9ZM13.5 6H12V3H6V6H4.5V1.5H13.5V6Z",fill:"#475569"})})}},17984:function(n,e,t){"use strict";var r=t(85893);e.Z=function(n){let{...e}=n;return(0,r.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",...e,children:[(0,r.jsx)("path",{d:"M4 10H8V14H4V10Z",fill:"#64748B"}),(0,r.jsx)("path",{d:"M10 10H14V14H10V10Z",fill:"#64748B"}),(0,r.jsx)("path",{d:"M20 10H16V14H20V10Z",fill:"#64748B"})]})}},86121:function(n,e,t){"use strict";var r=t(82729),o=t(85893),i=t(19521),s=t(67294),l=t(62286),a=t.n(l),c=t(41664),d=t.n(c),u=t(11163);
1function _templateObject(){let n=(0,r._)(["\n  display: flex;\n  align-items: center;\n  margin: 0px 20px;\n  border-bottom: 2px solid ",';\n  font-family: "Mulish", sans-serif;\n  max-width: calc(100vw - 2rem);\n\n  '," {\n    overflow: scroll;\n  }\n\n  "," {\n    overflow: hidden;\n  }\n\n  p {\n    margin: 0px;\n  }\n\n  .channel-filter {\n    padding: 10px 8px;\n    border-bottom: 2px solid transparent;\n\n    .filter-text {\n      padding: 8px 12px;\n      color: ",";\n      font-size: 16px;\n      font-weight: 600;\n      line-height: 150%;\n      border-radius: 4px;\n      min-width: var(--min-width);\n      white-space: nowrap;\n\n      span {\n        /* padding: 2px 6px; */\n        border-radius: 50%;\n        background: ",";\n        font-size: 12px;\n        font-style: normal;\n        font-weight: 700;\n        line-height: normal;\n      }\n    }\n\n    :hover {\n      .filter-text {\n        background: ",";\n        color: ",";\n      }\n    }\n  }\n\n  .current-filter {\n    border-bottom: 2px solid #14adff;\n    .filter-text {\n      font-weight: 700;\n      color: ",";\n\n      span {\n        background: #0080d4;\n        color: #fff;\n      }\n    }\n  }\n  a {\n    text-decoration: none;\n  }\n"]);return _templateObject=function(){return n},n}let p=i.default.div.withConfig({componentId:"sc-54782e55-0"})(_templateObject(),n=>{let{theme:e}=n;return e.colors.border.grey.light},n=>{let{theme:e}=n;return e.breakpoints.xs},n=>{let{theme:e}=n;return e.breakpoints.sm},n=>{let{theme:e}=n;return e.colors.text.tertiary},n=>n.theme.colors.border.grey.light,n=>n.theme.colors.background.grey.tertiary,n=>{let{theme:e}=n;return e.colors.text.accent.blue},n=>{let{theme:e}=n;return e.colors.text.primary});e.Z=function(n){let{filters:e,currentFilter:t,setCurrentFilter:r}=n,i=a().get().codedextoken||"",l=(0,s.useRef)({}),c=(0,u.useRouter)(),m=c.asPath.replace(/\/(submissions|winners)(\/)?$/,"");return(0,s.useEffect)(()=>{Object.values(e).forEach(n=>{let e=l.current[n.internalName];if(e){let n=e.style.fontWeight;e.style.fontWeight="700";let t=e.scrollWidth;e.style.fontWeight=n,e.style.setProperty("--min-width","".concat(t,"px"))}})},[e]),(0,o.jsx)(p,{className:"community-feed-filters",children:Object.values(e).map(n=>{if(((null==n?void 0:n.disableOnLogout)!=!0||i)&&(null==n?void 0:n.disable)!=!0)return(null==m?void 0:m.includes("monthly-challenge"))?(0,o.jsx)(d(),{href:"".concat(m,"/").concat(n.link),children:(0,o.jsx)("div",{className:"channel-filter nes-pointer ".concat(t===n.internalName?"current-filter":""),onClick:()=>r(n.internalName),children:(0,o.jsxs)("p",{className:"filter-text",ref:e=>{l.current[n.internalName]=e},children:[n.displayText," ",(null==n?void 0:n.num)&&(0,o.jsx)("span",{style:{padding:(null==n?void 0:n.num)>=10?"3px 4px":"2px 6px"},children:null==n?void 0:n.num})]})})},n.internalName):(0,o.jsx)("div",{className:"channel-filter nes-pointer ".concat(t===n.internalName?"current-filter":""," ").concat(n.internalName),onClick:()=>r(n.internalName),children:(0,o.jsxs)("p",{className:"filter-text",ref:e=>{l.current[n.internalName]=e},children:[n.displayText," ",(null==n?void 0:n.num)&&(0,o.jsx)("span",{style:{padding:(null==n?void 0:n.num)>=10?"3px 4px":"2px 6px"},children:null==n?void 0:n.num})]})},n.internalName)})})}},1791:function(n,e,t){"use strict";var r=t(82729),o=t(85893),i=t(19521),s=t(67294),l=t(41664),a=t.n(l),c=t(17984),d=t(63877),u=t(85307),p=t(69214),m=t(609),h=t(9473),f=t(87094),x=t(92152);function _templateObject(){let n=(0,r._)(["\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n\n  a {\n    text-decoration: none;\n  }\n\n  .author {\n    display: flex;\n    align-items: center;\n    gap: 12px;\n\n    "," {\n      overflow-x: hidden;\n    }\n\n    "," {\n      overflow-x: visible;\n    }\n\n    .author-image {\n      flex-shrink: 0;\n      img {\n        width: 32px;\n        height: 32px;\n        border-radius: 50%;\n        object-fit: cover;\n        transition-duration: 0.2s;\n\n        :hover {\n          opacity: 0.8;\n        }\n      }\n    }\n\n    //redo-ellipsis\n\n    .author-info {\n      display: flex;\n      align-items: center;\n      gap: 8px;\n\n      text-overflow: ellipsis;\n      /* overflow: hidden; */\n      white-space: nowrap;\n\n      .author-name {\n        display: flex;\n        align-items: center;\n        gap: 4px;\n\n        .name {\n          color: ",";\n          font-size: 16px;\n          font-weight: 700;\n          line-height: 150%;\n\n          :hover {\n            text-decoration: underline;\n          }\n\n          /* flip to true to restore gold club names */\n          ","\n        }\n\n        .rank-image {\n          img {\n            width: 24px;\n            height: 24px;\n          }\n        }\n      }\n\n      .author-username {\n        display: flex;\n        align-items: center;\n        gap: 4px;\n\n        .username,\n        .posted-since {\n          color: ",";\n          font-size: 16px;\n          font-weight: 500;\n          line-height: 150%;\n        }\n\n        .dot {\n          background-color: ",";\n          width: 2px;\n          height: 2px;\n        }\n\n        .username {\n          :hover {\n            text-decoration: underline;\n          }\n        }\n      }
1\n\n      .rank-image,\n      .time-posted {\n        position: relative;\n\n        .tooltip {\n          display: none;\n          min-width: fit-content;\n          position: absolute;\n          white-space: nowrap;\n          top: -40px;\n          left: 50%;\n          transform: translateX(-50%);\n        }\n\n        :hover {\n          .tooltip {\n            display: block;\n          }\n        }\n      }\n    }\n  }\n\n  .dropdown-toggle {\n    padding: 8px;\n    border-radius: 4px;\n    transition-duration: 0.2s;\n    position: relative;\n    z-index: 1;\n\n    .dots {\n      path {\n        fill: ",";\n      }\n    }\n\n    :hover {\n      background-color: ",";\n\n      .dots {\n        path {\n          fill: ",";\n        }\n      }\n    }\n  }\n"]);return _templateObject=function(){return n},n}let g=i.default.div.withConfig({componentId:"sc-231f8006-0"})(_templateObject(),n=>{let{theme:e}=n;return e.breakpoints.xs},n=>{let{theme:e}=n;return e.breakpoints.sm},n=>{let{theme:e}=n;return e.colors.text.primary},!1,n=>{let{theme:e}=n;return e.colors.text.tertiary},n=>{let{theme:e}=n;return e.colors.text.tertiary},n=>{let{theme:e}=n;return e.colors.text.tertiary},n=>{let{theme:e}=n;return e.colors.background.grey.tertiary},n=>{let{theme:e}=n;return e.colors.text.accent.blue});e.Z=function(n){let{author:e,createdAt:t,setShowEditForm:r,postOwner:i,post:l,forProjectReview:v=!1}=n,w=(0,s.useMemo)(()=>(0,u.Z)(null==e?void 0:e.totalXp),[null==e?void 0:e.totalXp]),j=(0,s.useMemo)(()=>(0,d.F)(t),[t]),y=(0,s.useMemo)(()=>(0,d.i)(t),[t]),b=(0,h.v9)(m.S5),[N,V]=(0,s.useState)(!1);return(0,o.jsxs)(g,{children:[(0,o.jsxs)("div",{className:"author",children:[(0,o.jsx)("div",{className:"author-image",children:(0,o.jsx)(a(),{href:"/@".concat(null==e?void 0:e.username),prefetch:!1,children:(0,o.jsx)(x.Z,{src:null==e?void 0:e.photoURL,alt:"".concat(null==e?void 0:e.username,"'s profile picture"),style:{width:"32px",height:"32px",borderRadius:"50%"}})})}),(0,o.jsxs)("div",{className:"author-info",children:[(0,o.jsxs)("div",{className:"author-name",children:[(0,o.jsx)(a(),{href:"/@".concat(null==e?void 0:e.username),prefetch:!1,children:(0,o.jsx)("p",{className:"name ".concat((null==e?void 0:e.club)?"club":""),children:null==e?void 0:e.name})}),(0,o.jsxs)("div",{className:"rank-image",children:[(0,o.jsx)(p.Z,{text:"".concat(null==w?void 0:w.rankName," rank"),arrowDirection:"bottom"}),(0,o.jsx)("img",{src:null==w?void 0:w.badge,alt:"".concat(null==e?void 0:e.username," rank ")})]})]}),(0,o.jsxs)("div",{className:"author-username",children:[(0,o.jsx)(a(),{href:"/@".concat(null==e?void 0:e.username),prefetch:!1,children:(0,o.jsxs)("p",{className:"username",children:["@",null==e?void 0:e.username]})}),(0,o.jsx)("div",{className:"dot"}),(0,o.jsxs)("div",{className:"time-posted",children:[(0,o.jsx)(p.Z,{text:y,arrowDirection:"bottom"}),(0,o.jsx)("p",{className:"posted-since",children:j})]})]})]})]}),(i||b)&&(0,o.jsxs)("div",{className:"dropdown-toggle nes-pointer",onClick:n=>{n.preventDefault(),V(!N)},children:[(0,o.jsx)(c.Z,{className:"dots"}),N&&(0,o.jsx)(f.Z,{setShowEditForm:r,postOwner:i,post:l,forProjectReview:v})]})]})}},87094:function(n,e,t){"use strict";t.d(e,{Z:function(){return dropdown_PostDropDown}});var r=t(82729),o=t(85893),i=t(19521),s=t(16877),l=t(3649),a=t(9473),c=t(609),d=t(89205),u=t(21264),p=t(82159),m=t(73845),h=t(65919),f=t(39828),x=t(92369);async function updatePinned(n){let{uid:e,docId:t,communityName:r,pin:o}=n,{firestore:i}=(0,x.UM)();if(!e)throw Error("uid or pinnedprojects missing.");try{let n=(0,f.JU)(i,"users",e,"community","pins"),s=(0,f.JU)(i,"users",e,"community","pins",r,"pinnedPosts"),l=(0,f.JU)(i,"community",r,"posts",t);return o?(await (0,f.pl)(n,{pinned:(0,f.vr)(t)},{merge:!0}),await (0,f.pl)(s,{pinned:(0,f.vr)(t)},{merge:!0}),await (0,f.r7)(l,{pinnedByOwner:!0})):(await (0,f.r7)(n,{pinned:(0,f.Ab)(t)}),await (0,f.r7)(s,{pinned:(0,f.Ab)(t)}),await (0,f.r7)(l,{pinnedByOwner:!1})),{status:200}}catch(n){return{status:500,error:n}}}var g=t(67294),v=t(85673),w=t(11163);function _templateObject(){let n=(0,r._)(["\n  padding: 8px;\n  width: 200px;\n  position: absolute;\n  right: 0px;\n  top: 120%;\n\n  background-color: ",";
1\n\n  svg {\n    width: 20px;\n    height: 20px;\n  }\n"]);return _templateObject=function(){return n},n}let j=(0,i.default)(l.Z).withConfig({componentId:"sc-224b6c88-0"})(_templateObject(),n=>{let{theme:e}=n;return e.colors.background.grey.primary});var dropdown_PostDropDown=function(n){let{setShowEditForm:e,postOwner:t,post:r,forProjectReview:i=!1}=n,l=(0,m.T)(),f=(0,w.useRouter)(),x=(0,a.v9)(c.o4)||"dark",y=(0,a.v9)(c.S5),[b,N]=(0,g.useState)(!1);(0,g.useEffect)(()=>{N(null==r?void 0:r.pinnedByOwner)},[r]);let V=(0,g.useCallback)(async function(){let n="/community/".concat(null==r?void 0:r.communityName,"/").concat(null==r?void 0:r.postId),e=await fetch("/api/revalidate?path=".concat(encodeURIComponent(n))),t=await e.json();t.revalidated?f.reload():console.error("Failed to revalidate: ".concat(n),t.error)},[null==r?void 0:r.communityName,null==r?void 0:r.postId]);async function pinPost(){await updatePinned({uid:null==r?void 0:r.ownerUid,docId:null==r?void 0:r.id,communityName:null==r?void 0:r.communityName,pin:!b}),N(!b),l((0,v.fz)({message:b?"Post unpinned":"Post pinned"})),setTimeout(()=>{V()},3e3)}return(0,o.jsxs)(j,{borderColor:"dark"===x?"475569":"CBD5E1",children:[(t||y)&&(0,o.jsx)(s.Z,{svg:(0,o.jsx)(u.Z,{}),text:"Edit",onClick:()=>{e(n=>!n)}}),(t||y)&&(0,o.jsx)(s.Z,{svg:(0,o.jsx)(h.Z,{}),text:b?"Unpin to profile":"Pin to profile",onClick:()=>{pinPost()}}),(t||y)&&(0,o.jsx)(s.Z,{svg:(0,o.jsx)(p.Z,{}),text:"Delete",type:"delete",onClick:()=>{l((0,c.J)({type:"deleteOpcItem",status:"show",properties:{type:"post",post:{...r},forProjectReview:i}}))}}),(null==r?void 0:r.communityName)==="project-showcase"&&(0,o.jsx)(d.Z,{projectId:null==r?void 0:r.id,isUserAdmin:y,pinnedStatus:null==r?void 0:r.pinned})]})}},72351:function(n,e,t){"use strict";t.r(e),t.d(e,{default:function(){return course_projects}});var r=t(82729),o=t(85893),i=t(19521),s=t(99428),l=t(67294),a=t(44510),c=t(86121),d=t(58533),u=t(9473),p=t(609),m=t(25670),h=t(1791),f=t(41664),x=t.n(f),g=t(88090);function _templateObject(){let n=(0,r._)(["\n  padding: 24px;\n  transition-duration: 0.2s;\n  border: 2px solid ",';\n  border-radius: 8px;\n  display: flex !important;\n  justify-content: space-between;\n\n  p {\n    margin: 0px;\n  }\n\n  font-family: "Mulish", sans-serif;\n  display: flex;\n  align-items: center;\n  gap: 1rem;\n\n  .dropdown-toggle {\n    display: none;\n  }\n\n  .tags-container {\n    display: flex;\n    align-items: center;\n    gap: 8px;\n    margin-bottom: 0.5rem;\n\n    .tag {\n      padding: 5px 12px;\n\n      color: ',";\n      background-color: ",";\n      font-size: 12px;\n      font-style: normal;\n      font-weight: 700;\n      line-height: normal;\n      letter-spacing: 1.68px;\n      text-transform: uppercase;\n      border-radius: 100px;\n    }\n  }\n\n  ","\n"]);return _templateObject=function(){return n},n}let v=i.default.div.withConfig({componentId:"sc-dbdb1bee-0"})(_templateObject(),n=>{let{theme:e}=n;return e.colors.border.grey.medium},n=>{let{theme:e}=n;return e.colors.text.secondary},n=>{let{theme:e}=n;return e.colors.background.grey.tertiary},n=>{let{theme:e}=n;return"\n      :hover {\n        background-color: ".concat(e.colors.background.grey.secondary,";\n      }\n    ")});var course_projects_CourseProjectCard=function(n){let{post:e}=n;(0,u.v9)(p.o4);let t=(0,u.v9)((0,g._9)({courseName:null==e?void 0:e.internalCourseName}));return(0,o.jsx)(x(),{href:"/course-projects/".concat(null==e?void 0:e.uid,"/").concat(null==e?void 0:e.internalCourseName),target:"_blank",style:{all:"unset"},children:(0,o.jsxs)(v,{className:"nes-pointer",children:[(0,o.jsx)(h.Z,{author:null==e?void 0:e.authorData,createdAt:null==e?void 0:e.createdAt,postOwner:!0,post:e,setShowEditForm:()=>{}}),(0,o.jsxs)("div",{className:"tags-container",children:[(0,o.jsx)("div",{className:"tag",children:t}),(0,o.jsx)("div",{className:"tag needs-review",children:"Needs review"})]})]})})};function course_projects_templateObject(){let n=(0,r._)(["\n  min-height: 100vh;\n  height: fit-content;\n  min-width: 100vw;\n  background-color: ",";\n  padding-top: 7rem;\n  display: flex;\n  justify-content: center;\n\n  .inner-container {\n    width: calc(100% - 1rem);\n    max-width: 900px;\n\n    h1 {\n      color: ",';
1\n      font-family: "PixelGridM";\n      font-size: 32px;\n      font-style: normal;\n      font-weight: 700;\n      line-height: 140%;\n      letter-spacing: 0.96px;\n    }\n\n    .channel-posts {\n      padding: 0px 1rem;\n      padding-top: 24px;\n      display: flex;\n      flex-direction: column;\n      gap: 8px;\n    }\n  }\n']);return course_projects_templateObject=function(){return n},n}let w=i.default.div.withConfig({componentId:"sc-64e45f83-0"})(course_projects_templateObject(),n=>{let{theme:e}=n;return e.colors.background.grey.primary},n=>{let{theme:e}=n;return e.colors.text.primary});var course_projects=function(){(0,u.v9)(p.f8);let n="admin-projects-review",e=(0,l.useMemo)(()=>({"needs-review":{api:"/api/community/getCourseProjects?status=pending",displayText:"Needs review",internalName:"needs-review"},"requested-correction":{api:"/api/community/getCourseProjects?status=needs-edit",displayText:"Requested correction",internalName:"requested-correction"},completed:{api:"/api/community/getCourseProjects?status=completed",displayText:"Completed",internalName:"completed"}}),[]),[t,r]=(0,l.useState)("needs-review"),{posts:i,noMorePosts:h,currentPage:f}=(0,a.Z)({community:n,filter:e[t],refreshTrigger:null}),[x,g]=(0,l.useState)(i);(0,l.useEffect)(()=>{g(i)},[i]);let v=(0,l.useCallback)(async()=>{try{let r=e[t],o="".concat(n,"-").concat(r.internalName,"-").concat(null),i=JSON.parse(sessionStorage.getItem(o)),s=i.currentPage+1,l="".concat(r.api,"&page=").concat(s),a=await fetch(l),c=await a.json(),d=c.posts;0!=d.length&&(g(n=>[...n,...d]),i={posts:[...i.posts,...d],currentPage:s},sessionStorage.setItem(o,JSON.stringify({...i}))),d.length}catch(n){console.error("Error fetching more posts:",n)}},[e,t]);return(0,l.useEffect)(()=>{let n=setInterval(()=>{v()},1e3);return()=>clearInterval(n)},[v]),(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(s.Z,{}),(0,o.jsx)(w,{id:"admin-post-fetch",children:(0,o.jsxs)("div",{className:"inner-container",children:[(0,o.jsx)("h1",{children:"Review Project Submissions"}),(0,o.jsx)(c.Z,{filters:e,currentFilter:t,setCurrentFilter:r}),(0,o.jsx)(d.Z,{className:"channel-posts",dataLength:x.length,next:v,hasMore:!0,scrollThreshold:.2,loader:(0,o.jsx)(m.Z,{}),scrollableTarget:"admin-post-fetch",children:null==x?void 0:x.map((n,e)=>(0,o.jsx)(course_projects_CourseProjectCard,{post:n},null==n?void 0:n.postId))})]})})]})}}},function(n){n.O(0,[1272,8700,1057,4090,4153,1622,9280,9428,9774,2888,179],function(){return n(n.s=67978)}),_N_E=n.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.