Refactor body into multiple files
This commit is contained in:
parent
36db4c2c0c
commit
a513e3786c
10 changed files with 168 additions and 151 deletions
42
src/Body/Fetch/Description.tsx
Normal file
42
src/Body/Fetch/Description.tsx
Normal file
|
@ -0,0 +1,42 @@
|
|||
import { Highlight } from "./utils";
|
||||
|
||||
type HeaderProps = {
|
||||
user: string;
|
||||
hostname: string;
|
||||
};
|
||||
|
||||
const Header = ({ user, hostname }: HeaderProps) => (
|
||||
<>
|
||||
<p>
|
||||
<Highlight>{user}</Highlight>@<Highlight>{hostname}</Highlight>
|
||||
</p>
|
||||
<p>{"-".repeat(user.length + 1 + hostname.length)}</p>
|
||||
</>
|
||||
);
|
||||
|
||||
type InfoLineProps = {
|
||||
label: string;
|
||||
value: string;
|
||||
};
|
||||
|
||||
const InfoLine = ({ label, value }: InfoLineProps) => (
|
||||
<p>
|
||||
<span className="text-highlight">{label}</span>: {value}
|
||||
</p>
|
||||
);
|
||||
|
||||
const Description = () => (
|
||||
<div className="invisible-div">
|
||||
<Header user="website" hostname="MichaelBradley" />
|
||||
<InfoLine label="Degree" value="Bachelor of Computer Science" />
|
||||
<InfoLine label="University" value="Carleton" />
|
||||
<InfoLine label="Major CGPA" value="11.52/12 (A+)" />
|
||||
<InfoLine label="Languages" value="C/C++, Python, TypeScript" />
|
||||
<InfoLine label="Skills" value="Linux, Git, Testing" />
|
||||
<InfoLine label="Work Experience" value="2 years" />
|
||||
<InfoLine label="Applying for" value="Full-time job" />
|
||||
<InfoLine label="Location" value="Toronto or Remote" />
|
||||
</div>
|
||||
);
|
||||
|
||||
export default Description;
|
Loading…
Add table
Add a link
Reference in a new issue