File tree 6 files changed +127
-1
lines changed
6 files changed +127
-1
lines changed Original file line number Diff line number Diff line change
1
+ import { NavBar } from "@/components/judging/Navbar" ;
2
+
3
+ const AssignedTeamsPage = ( ) => {
4
+ const assignedTeams = [
5
+ { id : 1 , name : "Team Alpha" } ,
6
+ { id : 2 , name : "Team Beta" } ,
7
+ { id : 3 , name : "Team Gamma" } ,
8
+ ] ;
9
+
10
+ return (
11
+ < div >
12
+ < NavBar />
13
+ < h1 > Put assinged teams here Assigned Teams</ h1 >
14
+ < ul >
15
+ { assignedTeams . map ( ( team ) => (
16
+ < li key = { team . id } > { team . name } </ li >
17
+ ) ) }
18
+ </ ul >
19
+ </ div >
20
+ ) ;
21
+ } ;
22
+
23
+ export default AssignedTeamsPage ;
Original file line number Diff line number Diff line change 1
1
import type { Metadata } from "next" ;
2
2
3
+ import { NavBar } from "@/components/judging/Navbar" ;
4
+
3
5
import JudgingDashboard from "./JudgingDashboard" ;
4
6
5
7
export const dynamic = "force-dynamic" ;
@@ -20,6 +22,7 @@ export const metadata: Metadata = {
20
22
export default function Judging ( ) {
21
23
return (
22
24
< main className = "flex w-full flex-1 flex-col gap-4 bg-dashboard-grey" >
25
+ < NavBar />
23
26
< JudgingDashboard />
24
27
</ main >
25
28
) ;
Original file line number Diff line number Diff line change
1
+ import { NavBar } from "@/components/judging/Navbar" ;
2
+
3
+ const RubricPage = ( ) => {
4
+ return (
5
+ < div >
6
+ < NavBar />
7
+ < h1 > Judging Rubric here</ h1 >
8
+ < ul > </ ul >
9
+ </ div >
10
+ ) ;
11
+ } ;
12
+
13
+ export default RubricPage ;
Original file line number Diff line number Diff line change
1
+ "use client" ;
2
+
3
+ import { useEffect , useState } from "react" ;
4
+
5
+ interface Schedule {
6
+ teamName : string ;
7
+ timeSlot : string ;
8
+ }
9
+
10
+ const SchedulePage = ( ) => {
11
+ const [ schedule , setSchedule ] = useState < Schedule [ ] > ( [ ] ) ;
12
+
13
+ useEffect ( ( ) => {
14
+ // Fetch schedule data from an API or define it statically
15
+ // Template for when we will fetch the schedule
16
+ const fetchSchedule = async ( ) => {
17
+ const response = await fetch ( "/api/schedule" ) ;
18
+ const data = await response . json ( ) ;
19
+ setSchedule ( data ) ;
20
+ } ;
21
+
22
+ fetchSchedule ( ) ;
23
+ } , [ ] ) ;
24
+
25
+ return (
26
+ < div >
27
+ < h1 > Judging Schedule</ h1 >
28
+ < table >
29
+ < thead >
30
+ < tr >
31
+ < th > Team Name</ th >
32
+ < th > Time Slot</ th >
33
+ </ tr >
34
+ </ thead >
35
+ < tbody >
36
+ { schedule . map ( ( item , index ) => (
37
+ < tr key = { index } >
38
+ < td > { item . teamName } </ td >
39
+ < td > { item . timeSlot } </ td >
40
+ </ tr >
41
+ ) ) }
42
+ </ tbody >
43
+ </ table >
44
+ </ div >
45
+ ) ;
46
+ } ;
47
+
48
+ export default SchedulePage ;
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ export default function Header() {
68
68
) : user . type === UserType . Admin ? (
69
69
< Link href = "/admin" > Admin Dashboard</ Link >
70
70
) : user . type === UserType . Judge ? (
71
- < Link href = "/judging" > Judge Dashboard </ Link >
71
+ < Link href = "/judging" > </ Link >
72
72
) : null }
73
73
</ >
74
74
) : (
Original file line number Diff line number Diff line change
1
+ "use client" ;
2
+
3
+ import Link from "next/link" ;
4
+
5
+ export function NavBar ( ) {
6
+ // Will add the actual routes when the pages are
7
+ const navigation = [
8
+ {
9
+ name : "Dashboard" ,
10
+ href : "/judging" ,
11
+ } ,
12
+ {
13
+ name : "Schedule" ,
14
+ href : "/judging/schedule" ,
15
+ } ,
16
+ {
17
+ name : "Assigned Teams" ,
18
+ href : "/judging/assigned-teams" ,
19
+ } ,
20
+ {
21
+ name : "Rubric" ,
22
+ href : "/judging/rubric" ,
23
+ } ,
24
+ ] ;
25
+
26
+ return (
27
+ < nav className = "border-b bg-white text-awesomer-purple" >
28
+ < div className = "mx-auto flex h-20 items-center justify-center space-x-48 pl-8" >
29
+ { navigation . map ( ( item ) => {
30
+ return (
31
+ < Link key = { item . name } href = { item . href } className = "text-2xl" >
32
+ { item . name }
33
+ </ Link >
34
+ ) ;
35
+ } ) }
36
+ </ div >
37
+ </ nav >
38
+ ) ;
39
+ }
You can’t perform that action at this time.
0 commit comments