Initial commit
This commit is contained in:
54
src/portfolio/helpers/Education.tsx
Normal file
54
src/portfolio/helpers/Education.tsx
Normal file
@@ -0,0 +1,54 @@
|
||||
import {FC} from "react";
|
||||
import styles from "../styling/achievements.module.scss";
|
||||
|
||||
export type EducationArgs = {
|
||||
institution : string,
|
||||
startDate : string,
|
||||
title : string,
|
||||
subtitle : string,
|
||||
city : "Warsaw" | "London" | "Edinburgh",
|
||||
endDate? : string,
|
||||
notes? : string[]
|
||||
useWith? : true,
|
||||
}
|
||||
|
||||
const Education : FC<EducationArgs> = (props) => {
|
||||
|
||||
const getCountryEmoji = () => {
|
||||
switch (props.city) {
|
||||
case "Warsaw":
|
||||
return "🇵🇱";
|
||||
case "London":
|
||||
return "🏴";
|
||||
case "Edinburgh":
|
||||
return "🏴";
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<div style={{fontSize: "1.1em"}} className={styles.education} data-aos={"fade-right"}>
|
||||
<div>
|
||||
<span className={styles.title}>{props.title}</span> in <b>{props.subtitle}</b>
|
||||
<br/>
|
||||
at <i>{props.institution}</i>
|
||||
{props.notes?
|
||||
<ul className={styles.notes}>
|
||||
{props.notes.map((note, index) =>
|
||||
<li key={index}>
|
||||
{note}
|
||||
</li>
|
||||
)}
|
||||
</ul>
|
||||
: ""
|
||||
}
|
||||
</div>
|
||||
<span className={styles.otherDetails}>
|
||||
<div className={styles.location}>{props.city} {getCountryEmoji()}</div>
|
||||
<hr/>
|
||||
{props.endDate ? props.startDate + " - " + props.endDate : "Since " + props.startDate}
|
||||
</span>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default Education;
|
||||
Reference in New Issue
Block a user