Skip to content

Commit 166d382

Browse files
committed
Create StaffCard component
1 parent b28185b commit 166d382

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

src/routes/About/StaffCard.tsx

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
interface Props {
2+
staff: Staff;
3+
}
4+
5+
export default function StaffCard({ staff }: Props) {
6+
return (
7+
<div className="outer mx-auto border border-solid border-transparent rounded-2xl max-h-60 p-2.5">
8+
<div className="inner rounded-lg py-6 px-4 text-secondary flex flex-col">
9+
<div className="flex items-center">
10+
<img
11+
className="size-20 rounded-full mr-3"
12+
src={`/images/${staff.name.toLowerCase()}.png`}
13+
alt={staff.name}
14+
/>
15+
<div className="flex flex-col">
16+
<h4 className="text-4xl">{staff.name}</h4>
17+
<p>{`${staff.preferredLanguage} - ${staff.yearsExp.toString()} years`}</p>
18+
</div>
19+
</div>
20+
<p className="mt-4">{staff.bio}</p>
21+
</div>
22+
</div>
23+
);
24+
}

0 commit comments

Comments
 (0)