Skip to content

Commit 2b10823

Browse files
committed
extracted execs section into a separate component
1 parent 5aa59df commit 2b10823

File tree

2 files changed

+25
-17
lines changed

2 files changed

+25
-17
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import { useState } from "react";
2+
import { EXECS } from "@/../public/data/execs";
3+
4+
const ExecDisplay = () => {
5+
return (
6+
<div className="my-5">
7+
<h2 className="text-xl font-bold mb-2">Execs</h2>
8+
<div className="grid grid-cols-2 md:grid-cols-4 gap-4">
9+
{EXECS.map(exec => (
10+
<div>
11+
<div>
12+
<p>{exec.name}</p>
13+
<p className="text-gray-500">{exec.role}</p>
14+
</div>
15+
</div>
16+
))}
17+
</div>
18+
</div>
19+
);
20+
}
21+
22+
export default ExecDisplay;

frontend/src/pages/about/execs-directors-subcoms.tsx

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import PortfolioDisplay from "@/components/About/PortfolioDisplay";
2+
import ExecDisplay from "@/components/About/ExecDisplay";
23
import Layout from "@/components/Layout";
34
import PageBody from "@/components/PageBody";
45
import PageTitle from "@/components/PageTitle";
@@ -24,19 +25,7 @@ const ExecsDirectorsSubcommitteesPage = () => {
2425
</div>
2526

2627
{/* EXECS */}
27-
<div className="my-5">
28-
<h2 className="text-xl font-bold mb-2">Execs</h2>
29-
<div className="grid grid-cols-2 md:grid-cols-4 gap-4">
30-
{EXECS.map(exec => (
31-
<div>
32-
<div>
33-
<p>{exec.name}</p>
34-
<p className="text-gray-500">{exec.role}</p>
35-
</div>
36-
</div>
37-
))}
38-
</div>
39-
</div>
28+
<ExecDisplay />
4029

4130
<div className="border-t border-gray-300 my-10"></div>
4231

@@ -50,10 +39,7 @@ const ExecsDirectorsSubcommitteesPage = () => {
5039
</div>
5140

5241
<PortfolioDisplay />
53-
54-
{/* <p className="text-xl bold my-5">
55-
Get to know them better <a href="https://media.csesoc.org.au/fyg24-meet-csesoc/" className="text-blue-500 hover:underline">here</a>!
56-
</p> */}
42+
5743
</div>
5844
</PageBody>
5945
</Layout>

0 commit comments

Comments
 (0)