1
1
// src/components/SubmitApplicationEvaluation/SubmitApplicationEvaluationPage.tsx
2
2
import { useEffect , useState } from "react" ;
3
3
4
-
5
-
6
4
import { Hex } from "viem" ;
7
5
8
6
import { ApplicationBadge , ApplicationStatus } from "@/components/Badges" ;
9
7
import EvaluationForm from "@/components/EvaluationForm/EvaluationForm" ;
10
8
import { IconLabel } from "@/components/IconLabel" ;
11
9
import { PoolSummary } from "@/components/pool/components/PoolSummary/PoolSummary" ;
12
10
import { ProjectBanner } from "@/components/project/components/ProjectBanner/ProjectBanner" ;
11
+ import { ProjectSummary } from "@/components/project/components/ProjectSummary/ProjectSummary" ;
13
12
import { useToast } from "@/hooks/use-toast" ;
14
13
import { formatDate , DateFormat } from "@/lib/dates/formatDate" ;
15
14
import { Accordion } from "@/primitives/Accordion" ;
@@ -18,7 +17,7 @@ import { Icon, IconType } from "@/primitives/Icon";
18
17
import { ListGrid , ListGridColumn } from "@/primitives/ListGrid" ;
19
18
import { Markdown } from "@/primitives/Markdown/Markdown" ;
20
19
21
- import { useCredentialverification , useGetPastApplications , useInitialize } from "~checker/hooks" ;
20
+ import { useGetPastApplications , useInitialize } from "~checker/hooks" ;
22
21
import { useApplicationOverviewEvaluations } from "~checker/hooks/useApplicationEvaluations" ;
23
22
import { PastApplication } from "~checker/services/allo" ;
24
23
import { EVALUATION_STATUS , EvaluationBody } from "~checker/services/checker/api" ;
@@ -65,7 +64,6 @@ export const SubmitApplicationEvaluationPage = ({
65
64
const [ isModalOpen , setIsModalOpen ] = useState ( false ) ;
66
65
const { application, evaluationQuestions } =
67
66
useApplicationOverviewEvaluations ( { applicationId } ) || { } ;
68
- const { isTwitterVerified, isGithubVerified } = useCredentialverification ( application ) ;
69
67
70
68
const [ toastShowed , setToastShowed ] = useState ( false ) ;
71
69
const dispatch = useCheckerDispatchContext ( ) ;
@@ -102,6 +100,7 @@ export const SubmitApplicationEvaluationPage = ({
102
100
if ( ! application || ! evaluationQuestions ) return null ;
103
101
104
102
const project = application . metadata . application . project ;
103
+
105
104
const groups = evaluationQuestions . map ( ( q ) => ( {
106
105
id : q . questionIndex . toString ( ) ,
107
106
heading : q . question ,
@@ -238,65 +237,7 @@ export const SubmitApplicationEvaluationPage = ({
238
237
/>
239
238
}
240
239
isOpen = { true }
241
- content = {
242
- < div className = "flex flex-col gap-4" >
243
- < div className = "flex flex-wrap items-start gap-10" >
244
- < div className = "flex flex-col gap-4" >
245
- { application . metadata . application . recipient && (
246
- < IconLabel
247
- type = "address"
248
- address = { application . metadata . application . recipient }
249
- />
250
- ) }
251
- { project . website && (
252
- < IconLabel type = "social" platform = "website" link = { project . website } />
253
- ) }
254
- { project . projectTwitter && (
255
- < IconLabel
256
- type = "social"
257
- platform = "twitter"
258
- link = {
259
- project . projectTwitter . includes ( "https://" )
260
- ? project . projectTwitter
261
- : `https://x.com/${ project . projectTwitter } `
262
- }
263
- isVerified = { isTwitterVerified }
264
- />
265
- ) }
266
- { project . projectGithub && (
267
- < IconLabel
268
- type = "social"
269
- platform = "github"
270
- link = {
271
- project . projectGithub . includes ( "https://" )
272
- ? project . projectGithub
273
- : `https://github.com/${ project . projectGithub } `
274
- }
275
- isVerified = { isGithubVerified }
276
- />
277
- ) }
278
- </ div >
279
- < div className = "flex flex-col gap-4" >
280
- < IconLabel
281
- type = "dateWithPrefix"
282
- prefix = "Applied on:"
283
- date = { new Date ( project . createdAt ) }
284
- />
285
- { project . projectGithub && (
286
- < IconLabel
287
- type = "social"
288
- platform = "github"
289
- link = {
290
- project . projectGithub . includes ( "https://" )
291
- ? project . projectGithub
292
- : `https://github.com/${ project . projectGithub } `
293
- }
294
- />
295
- ) }
296
- </ div >
297
- </ div >
298
- </ div >
299
- }
240
+ content = { < ProjectSummary projectMetadata = { project } application = { application } /> }
300
241
variant = "default"
301
242
border = "none"
302
243
padding = "none"
@@ -386,4 +327,4 @@ export const SubmitApplicationEvaluationPage = ({
386
327
</ div >
387
328
</ div >
388
329
) ;
389
- } ;
330
+ } ;
0 commit comments