1
1
import DefaultLayout from "@/components/layout/Default" ;
2
+ import SubmissionPopup from "@/components/popups/submission" ;
3
+ import Header from "@/components/sections/communities/_partials/Header" ;
4
+ import Wrapper from "@/components/sections/courses/Wrapper" ;
5
+ import MetaData from "@/components/ui/MetaData" ;
2
6
import useSubmissionNavigation from "@/hooks/useSubmissionNavigation" ;
3
7
import { wrapper } from "@/store" ;
4
8
import { fetchAllSubmission , fetchChallenge } from "@/store/services/communities/challenges" ;
@@ -7,10 +11,10 @@ import { Submission as SubmissionType } from "@/types/bounty";
7
11
import { Community } from "@/types/community" ;
8
12
import { Challenge } from "@/types/course" ;
9
13
import { NotFoundError } from "@/utilities/errors/NotFoundError" ;
10
- // import { he } from "date-fns/locale";÷
11
14
import { GetServerSideProps } from "next" ;
12
15
import { useTranslation } from "next-i18next" ;
13
16
import { serverSideTranslations } from "next-i18next/serverSideTranslations" ;
17
+ import Head from "next/head" ;
14
18
import { ReactElement , useMemo } from "react" ;
15
19
16
20
/**
@@ -36,21 +40,19 @@ export default function Submission(props: { pageProps: { currentCommunity: Commu
36
40
37
41
if ( ! submissions ) return < > </ > ;
38
42
39
- console . log ( submissions , challenge , selectedSubmission , handleCloseSubmission , showPopup , headerPaths ) ;
40
-
41
43
return (
42
44
< >
43
- { /* <Head>
45
+ < Head >
44
46
< title > { `${ t ( "communities.submission.title" ) } ${ challenge ?. name } ` } </ title >
45
47
< MetaData description = { challenge ?. description as string } />
46
- </Head> */ }
47
- { /* <Wrapper paths={headerPaths}> */ }
48
+ </ Head >
49
+ < Wrapper paths = { headerPaths } >
48
50
< div className = "flex flex-col py-4 space-y-8 text-gray-700" >
49
- { /* <Header title={challenge?.name} subtitle={t("communities.submission.title")} isTeamChallenge={challenge?.isTeamChallenge} isHackathon={challenge?.isHackathon} /> */ }
51
+ < Header title = { challenge ?. name } subtitle = { t ( "communities.submission.title" ) } isTeamChallenge = { challenge ?. isTeamChallenge } isHackathon = { challenge ?. isHackathon } />
50
52
{ /* <SubmissionList /> */ }
51
53
</ div >
52
- { showPopup && "Hello" }
53
- { /* </Wrapper> */ }
54
+ { showPopup && < SubmissionPopup show = { showPopup } onClose = { handleCloseSubmission } submissionId = { selectedSubmission ?. id } /> }
55
+ </ Wrapper >
54
56
</ >
55
57
) ;
56
58
}
0 commit comments