1
+ import Link from 'next/link' ;
2
+
3
+ import { RecordTile , RecordTileProps } from '@/components/Tiles/RecordTile' ;
1
4
import BlurFade , { BLUR_FADE_DELAY } from '@/components/ui/BlurFade' ;
2
- import LinkWithArrow from '@/components/ui/LinkWithArrow' ;
3
- import { useMediaQuery } from '@/hooks/useMediaQuery' ;
4
5
import { cn } from '@/lib/utils' ;
5
6
6
7
export function Education ( ) {
7
- const isTablet = useMediaQuery ( '(min-width: 768px)' ) ;
8
+ const educationDetails = (
9
+ < p className = "mt-1 py-0 text-gray-700 dark:text-gray-300" >
10
+ < Link
11
+ href = "https://uwaterloo.ca/computational-mathematics/"
12
+ target = "_blank"
13
+ rel = "noopener noreferrer"
14
+ className = "mr-0.5 hover:text-black hover:underline hover:underline-offset-4 dark:hover:text-white"
15
+ >
16
+ Computational Mathematics
17
+ </ Link > { ' ' }
18
+ is a interdisplinary major that combines Mathematics, Statistics, Optimization and Computer
19
+ Science, offered by the Faculty of Mathematics.
20
+ { /* TODO: Insert all courses using a recursive React component */ }
21
+ </ p >
22
+ ) ;
23
+ const uwrecord : RecordTileProps = {
24
+ organizationLogo : '/images/uwaterlooLogo.png' ,
25
+ organizationName : 'University of Waterloo' ,
26
+ organizationLink : 'https://uwaterloo.ca/' ,
27
+ role : 'Bachelor of Mathematics, Computational Mathematics Major' ,
28
+ duration : 'Sept 2022 - Present' ,
29
+ details : educationDetails ,
30
+ organizationBeforeRole : true ,
31
+ } ;
8
32
return (
9
33
< section id = "education" className = "mb-12" >
10
34
< BlurFade delay = { BLUR_FADE_DELAY * 7 } >
@@ -18,62 +42,7 @@ export function Education() {
18
42
</ h2 >
19
43
</ BlurFade >
20
44
< BlurFade delay = { BLUR_FADE_DELAY * 8 } >
21
- < div className = "flex items-center" >
22
- < div className = "relative flex-grow md:pl-12" >
23
- < div className = { 'absolute left-[5px] aspect-square rounded-lg bg-white' } >
24
- { /* // center the bullet : `top-1/2 transform -translate-y-1/2` */ }
25
- < img
26
- src = "/images/uwaterlooLogo.png"
27
- alt = { 'University of Waterloo logo' }
28
- width = { isTablet ? 80 : 45 }
29
- height = { isTablet ? 80 : 45 }
30
- className = "rounded-md"
31
- />
32
- </ div >
33
- < div className = { 'pl-16 ' + ( isTablet && 'py-3' ) } >
34
- < div className = "mb-2 flex flex-col justify-between sm:flex-row md:items-start" >
35
- < div >
36
- < LinkWithArrow
37
- href = "https://uwaterloo.ca/"
38
- target = "_blank"
39
- rel = "noopener noreferrer"
40
- aria-label = { 'Link to University of Waterloo' }
41
- >
42
- < h2 className = "inline-flex items-center text-xl font-bold" >
43
- University of Waterloo
44
- </ h2 >
45
- </ LinkWithArrow >
46
- < h3 className = "text-lg font-semibold" >
47
- Bachelor of Mathematics, Computational Mathematics Major
48
- </ h3 >
49
- { ! isTablet && (
50
- < h3 className = "font-typewriter text-gray-600 dark:text-gray-400" >
51
- Sept 2022 - Present
52
- </ h3 >
53
- ) }
54
- </ div >
55
- { isTablet && (
56
- < h3 className = "font-typewriter text-gray-600 dark:text-gray-400" >
57
- Sept 2022 - Present
58
- </ h3 >
59
- ) }
60
- </ div >
61
- </ div >
62
- </ div >
63
- </ div >
64
- < p className = "mt-1 py-0 text-gray-700 dark:text-gray-300" >
65
- < LinkWithArrow
66
- href = "https://uwaterloo.ca/computational-mathematics/"
67
- target = "_blank"
68
- rel = "noopener noreferrer"
69
- className = "mr-0.5"
70
- >
71
- Computational Mathematics
72
- </ LinkWithArrow > { ' ' }
73
- is a interdisplinary major that combines Mathematics, Statistics, Optimization and
74
- Computer Science, offered by the Faculty of Mathematics.
75
- { /* TODO: Insert all courses using a recursive React component */ }
76
- </ p >
45
+ < RecordTile { ...uwrecord } />
77
46
</ BlurFade >
78
47
</ section >
79
48
) ;
0 commit comments