1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="68697da6-74ff-4124-a17d-531077e706c4",e._sentryDebugIdIdentifier="sentry-dbid-68697da6-74ff-4124-a17d-531077e706c4")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4671],{69379:(e,t,n)=>{n.d(t,{A:()=>v});var i=n(74848),o=n(4743),r=n(42413),s=n(29382),l=n(32608),a=n(96540),d=n(30),p=n(93286),c=n(18826),x=n(58707),u=n(36277),g=n(86715),h=n(28781),f=n(26029),m=n(18151);let b=(0,c.n9)()(e=>({bannerWrapper:{backgroundImage:"url(/images/sparkle.svg)",backgroundSize:"auto",backgroundPosition:"right",backgroundRepeat:"no-repeat",backgroundColor:"#FFDA94",width:"stretch",display:"flex",flexDirection:"column",justifyContent:"flex-start",alignItems:"flex-start",padding:"25px 30px",gap:"20px",borderRadius:"10px 10px 0px 0px",[e.breakpoints.down("md")]:{padding:"25px 20px",backgroundSize:"240px 140px"}},bannerDetailSection:{display:"flex",flexDirection:"column",justifyContent:"flex-start",alignItems:"flex-start",gap:"12px",color:"#000000",[e.breakpoints.down("md")]:{gap:"4px"}},bannerTitle:{fontWeight:700,fontSize:"24px",lineHeight:"32px",[e.breakpoints.down("md")]:{fontSize:"20px"}},bannerDescription:{fontWeight:400,fontSize:"16px",lineHeight:"24px",[e.breakpoints.down("md")]:{fontSize:"14px"}},datesContainer:{border:"1px solid #FFF4E0",boxShadow:"0px 3px 0px 0px #FFF4E0",backgroundColor:"#FFE6B6",width:"fit-content",display:"flex",alignItems:"center",justifyContent:"center",flexDirection:"row",borderRadius:"8px"},dates:{padding:"12px",backgroundColor:"transparent",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:"4px",width:"fit-content",border:"1px solid #FFF4E0"},dateTitle:{color:"#5C6469",fontSize:"10px",fontWeight:500,width:"100%"},dateStat:{color:"#000000BA",fontWeight:700,fontSize:"12px",width:"100%"},tournamentDetail:{display:"flex",flexDirection:"column",gap:"2px"},tournamentHeading:{display:"flex",gap:"4px"},tournamentPages:{display:"flex",justifyContent:"space-between",width:"90vw",maxWidth:"500px"}})),v=(0,u.PA)(e=>{var t,n,c,u;let{onTournamentChange:v,selectedTournamentId:y,assignmentType:j}=e,{classes:A}=b(),C=(0,g.useRouter)(),{tournamentStore:w,contestStore:F}=(0,l.gy)(),[D,N]=(0,a.useState)(0),S=(0,a.useRef)(!0),k=(0,a.useRef)(!1),T=(null==w?void 0:null===(t=w.activeTournament)||void 0===t?void 0:t[D])||null,{currentWeek:E,totalWeeks:R}=(0,h.Ge)((null==T?void 0:T.start_date)||"",(null==T?void 0:T.end_date)||"");return(0,a.useEffect)(()=>{if(S.current){let e=C.query.page;if(e){let t=parseInt(e)-1;t>=0&&N(t)}S.current=!1}},[C.query.page]),(0,a.useEffect)(()=>{(null==T?void 0:T.tournament_id)&&!k.current&&(v&&v(T.tournament_id),F.resetFilters())},[null==T?void 0:T.tournament_id,v,F]),(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.A,{className:A.bannerWrapper,children:[(0,i.jsx)(o.A,{className:A.bannerDetailSection,children:(0,i.jsxs)(o.A,{children:[(0,i.jsx)(o.A,{className:A.bannerTitle,children:"Tournament & Contests"}),(0,i.jsx)(o.A,{className:A.bannerDescription,children:"Track your tournament and contest details effortlessly with our comprehensive dashboard."})]})}),T&&(0,i.jsxs)(o.A,{className:A.tournamentDetail,children:[(0,i.jsxs)(o.A,{className:A.tournamentPages,children:[(0,i.jsxs)(o.A,{className:A.tournamentHeading,children:[(0,i.jsx)(f.A,{sx:{mt:"5px"},title:(0,i.jsx)(r.A,{variant:"subtitle2",sx:{mt:.5},children:"This Displays the total number of active tournaments"}),arrow:!0,children:(0,i.jsx)(x.A,{sx:{width:"16px",height:"16px",color:"#5C6469",mt:"3px"}})}),(0,i.jsx)(o.A,{sx:{color:"#5C6469",fontSize:"14px",fontWeight:600},children:"TOURNAMENT"})]}),(0,i.jsxs)(o.A,{sx:{display:"flex",alignItems:"center",gap:"8px",marginTop:"5px"},children:[(0,i.jsx)(o.A,{onClick:()=>{if(D>0){var e;let t=D-1,n=null==w?void 0:null===(e=w.activeTournament)||void 0===e?void 0:e[t];n&&(k.current=!0,C.push({query:{...C.query,page:t+1}},void 0,{shallow:!0}).then(()=>{N(t),v&&v(n.tournament_id),F.resetFilters(),k.current=!1}))}},sx:{display:"flex",alignItems:"center",cursor:D>0?"pointer":"default",opacity:D>0?1:.5},children:(0,i.jsx)(d.A,{sx:{fontSize:"16px",color:"#000000"}})}),(0,i.jsxs)(r.A,{sx:{color:"#000000",fontSize:"14px",fontWeight:600},children:[D+1," / ",(null==w?void 0:null===(n=w.activeTournament)||void 0===n?void 0:n.length)||0]}),(0,i.jsx)(o.A,{onClick:()=>{var e,t;if(D<((null==w?void 0:null===(e=w.activeTournament)||void 0===e?void 0:e.length)||0)-1){(0,m.jHq)(y,j);let e=D+1,n=null==w?void 0:null===(t=w.activeTournament)||void 0===t?void 0:t[e];n&&(k.current=!0,C.push({query:{...C.query,page:e+1}},void 0,{shallow:!0}).then(()=>{N(e),v&&v(n.tournament_id),F.resetFilters(),k.current=!1}))}},sx:{display:"flex",alignItems:"center",cursor:D<((null==w?void 0:null===(c=w.activeTournament)||void 0===c?void 0:c.length)||0)-1?"pointer":"default",opacity:D<((null==w?void 0:null===(u=w.activeTournament)||void 0===u?void 0:u.length)||0)-1?1:.5},children:(0,i.jsx)(p.A,{sx:{fontSize:"16px",color:"#000000"}})})]})]}),(0,i.jsx)(r.A,{sx:{color:"#000000",fontSize:"18px",fontWeight:"bold",marginTop:"-5px"},children:T.name}),(0,i.jsxs)(o.A,{className:A.datesContainer,children:[(0,i.jsxs)(o.A,{className:A.dates,sx:{borderRadius:"8px 0px 0px 8px"},children:[(0,i.jsx)("div",{className:A.dateTitle,children:"TOURNAMENT STARTED ON:"}),(0,i.jsx)("div",{className:A.dateStat,children:(0,s.GP)(new Date(null==T?void 0:T.start_date),"dd MMM, yyyy")})]}),(0,i.jsxs)(o.A,{className:A.dates,children:[(0,i.jsx)("div",{className:A.dateTitle,children:"TOURNAMENT CLOSE ON:"}),(0,i.jsx)("div",{className:A.dateStat,children:(0,s.GP)(new Date(null==T?void 0:T.end_date),"dd MMM, yyyy")})]}),(0,i.jsxs)(o.A,{className:A.dates,sx:{borderRadius:"0px 8px 8px 0px"},children:[(0,i.jsx)("div",{className:A.dateTitle,children:"CURRENT PROGRESS"}),(0,i.jsx)("div",{className:A.dateStat,children:"Week ".concat(E," of ").concat(R)})]})]})]}),(0,i.jsxs)(o.A,{alignItems:"center",display:"flex",gap:"5px",children:[(0,i.jsx)(x.A,{height:1,width:1,fontSize:"inherit"}),(0,i.jsx)(r.A,{fontSize:12,fontWeight:400,color:"#000000",children:"Note: This configuration dates are managed by org admins"})]})]})})})}
1,72233:(e,t,n)=>{n.d(t,{A:()=>m});var i=n(74848),o=n(4743),r=n(53384),s=n(42413),l=n(96540),a=n(18826),d=n(58707),p=n(32608),c=n(79520),x=n(7721),u=n(26029),g=n(36277),h=n(18151);let f=(0,a.n9)()(e=>({root:{display:"flex",flexDirection:"row",gap:"30px",width:"90%",position:"relative",alignItems:"center",justifyContent:"flex-start",[e.breakpoints.down("md")]:{gap:"12px"}},trophyContainer:{svg:{fill:"#2ABDF0",width:"43px",height:"48px",[e.breakpoints.down("md")]:{width:"30px",height:"33px"}}},contestCompletedDesc:{fontWeight:700,fontSize:"18px",lineHeight:"26px",display:"flex",flexDirection:"row",gap:"8px",alignItems:"center",[e.breakpoints.down("md")]:{fontSize:"14px"}},progressWrapper:{display:"flex",flexDirection:"column",gap:"8px",width:"100%"},progressContainer:{display:"flex",flexDirection:"row",gap:"12px",overflow:"auto",maxWidth:"100%",[e.breakpoints.down("md")]:{gap:"8px"}},progress:{minWidth:"30px",height:"30px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",fontWeight:700,fontSize:"14px",lineHeight:"21px",color:"#5C6469",svg:{fill:"#FFFFFF"}},progressCompleted:{border:"2px solid #00C472",backgroundColor:"#00C472"},progressRedeemed:{border:"2px solid #2ABDF0",backgroundColor:"#2ABDF0",color:"#FFFFFF"},progressExpired:{border:"2px solid #E25D5D",backgroundColor:" #FFE2E2",color:"#D43131"},progressUpcoming:{border:"2px solid #E1E1E1",backgroundColor:"#E1E1E1",color:"#5C6469"},progressOngoing:{border:"2px solid #FFD363",backgroundColor:"#FFF1CC",color:"#F0B51F"}})),m=(0,g.PA)(()=>{let{classes:e,cx:t}=f(),{contestStore:n}=(0,p.gy)(),a=(0,l.useRef)(null),g=n.filteredContests.filter(e=>e.isCompleted).length;return(0,i.jsxs)(o.A,{className:e.root,children:[(0,i.jsx)(o.A,{className:e.trophyContainer,children:(0,i.jsx)(c.A,{})}),(0,i.jsxs)(o.A,{className:e.progressWrapper,children:[(0,i.jsxs)(o.A,{className:e.contestCompletedDesc,onClick:()=>(0,h.ojs)(),children:[g," Contest module",g>1?"s":""," ","completed!",(0,i.jsx)(u.A,{enterTouchDelay:0,leaveTouchDelay:5e3,title:(0,i.jsxs)(r.A,{p:"8px",gap:"10px",children:[(0,i.jsx)(s.A,{variant:"subtitle1",children:"Contest Streaks"}),(0,i.jsx)(s.A,{variant:"subtitle2",children:"Earn DT points by completing multiple contest modules in a row within a single announcement period. Each completed module adds to your streak, increasing your DT points reward!"})]}),arrow:!0,children:(0,i.jsx)(d.A,{sx:{color:"#5C6469",fontSize:"13px"}})})]}),(0,i.jsx)(o.A,{ref:a,className:e.progressContainer,onScroll:()=>{(0,h.dnK)()},children:n.filteredContests.slice().reverse().map((n,r)=>(0,i.jsx)(o.A,{className:t(e.progress,{[e.progressCompleted]:n.isCompleted,[e.progressRedeemed]:n.isRedeemed,[e.progressExpired]:n.isExpired,[e.progressOngoing]:n.isOngoing||n.isSubmitted,[e.progressUpcoming]:n.isUpcoming}),children:["completed"].includes(n.contestStatus)?(0,i.jsx)(x.A,{}):"".concat(r<9?"0":"").concat(r+1)},n.questionnaire_id))})]})]})})}}]);
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.