-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add BoardCard & Board Component #109
Changes from 2 commits
3359a11
2440de4
3b054f8
1a22a43
163d4d3
b3f74f6
ac4a641
9428702
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this looks right |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,11 @@ | ||
import Board from "@/components/board/Board"; | ||
|
||
const Page = () => { | ||
return <div className="bg-csa-tan-100"></div>; | ||
return ( | ||
<div className="bg-csa-tan-100"> | ||
<Board /> | ||
</div> | ||
); | ||
}; | ||
|
||
export default Page; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
"use client"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. not needed, also this file should be a tsx file |
||
import BoardCard from "./BoardCard"; | ||
import { boardInfo } from "@/data/boardInfo.ts"; | ||
|
||
const Board = () => { | ||
return ( | ||
<> | ||
<div className="mb-[16%] mt-[5%] grid grid-cols-3 gap-2 md:grid-cols-3"> | ||
{boardInfo.map((CARD) => ( | ||
<BoardCard | ||
name={CARD.name} | ||
title={CARD.title} | ||
image={CARD.image} | ||
color={CARD.color} | ||
/> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. make sure you're assigning a key to every mapped CARD. |
||
))} | ||
</div> | ||
</> | ||
); | ||
}; | ||
export default Board; |
This file was deleted.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this needs to be a tsx file |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import Image from "next/image"; | ||
import redDiamond from "@/public/board/redDiamond.webp"; | ||
|
||
const BoardCard = ({ image, name, title, color }) => { | ||
return ( | ||
<div className=""> | ||
<div className="= flex justify-center"> | ||
<Image | ||
src={redDiamond} | ||
alt="redDiamond" | ||
className="" | ||
width={600} | ||
height={600} | ||
/> | ||
<Image | ||
src={image} | ||
alt="picture of person" | ||
className="absolute object-cover" | ||
width={300} | ||
height={300} | ||
/> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this will need to be positioned absolutely within a relative diamond. to make your photo into a diamond feel free to copy this code into the globals.css file and you can use it by typing diamond into the tailwind css classnames
|
||
</div> | ||
<p | ||
className={`flex justify-center text-center text-3xl text-[90%] md:text-4xl ${color}`} | ||
> | ||
{name} | ||
</p> | ||
<p className="flex justify-center text-center text-2xl text-[90%] md:text-4xl"> | ||
{title} | ||
</p> | ||
</div> | ||
); | ||
}; | ||
export default BoardCard; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import Brianna from "@/public/board/Briana_Lam.webp"; | ||
import Ryan_Lew from "@/public/board/Ryan_Lew.webp"; | ||
import Megan from "@/public/board/Megan_Ho.webp"; | ||
import Renne from "@/public/board/Renne_Sanchex.webp"; | ||
import Renne from "@/public/board/Renne_Sanchez.webp"; | ||
import Marcus from "@/public/board/Marcus_Lee.webp"; | ||
import Dominic from "@/public/board/Dominic_Rivera.webp"; | ||
import Alex from "@/public/board/Alex_Sin.webp"; | ||
|
@@ -15,18 +15,18 @@ import Yuhan from "@/public/board/Yuhan_Shi.webp"; | |
import Joshua from "@/public/board/Joshua_Yu.webp"; | ||
import Anson from "@/public/board/Anson_Gao.webp"; | ||
import Kathy from "@/public/board/Kathy_Liu.webp"; | ||
import Connor from "@/public/board/Connor_Lao.webp"; | ||
import Connor from "@/public/board/Connor_Lau.webp"; | ||
import Mia from "@/public/board/Mia_Chiang.webp"; | ||
import Samantha from "@/public/board/Samantha_Lee.webp"; | ||
import Nathan from "@/public/board/Nathan_Cheung.webp"; | ||
import Peter from "@/public/board/Peter_Hsia.webp"; | ||
import Andy from "@/public/board/Andy_Banh.webp"; | ||
import Kaelyn from "@/public/board/Kaelyn_Lam.webp"; | ||
import Aidan from "@/public/board/Aidan_Lam.webp"; | ||
import Andrew from "@public/board/Andrew_Zhang.webp"; | ||
import Andrew from "@/public/board/Andrew_Zhang.webp"; | ||
import Caitlyn from "@/public/board/Caitlyn_Hang.webp"; | ||
import Ryan_Nguyen from "@/public/board/Ryan_Nguyen.webp"; | ||
import Stephanie from "@/public/board/Stephanie_Huang.webp"; | ||
// import Stephanie from "@/public/board/Stephanie_Huang.webp"; | ||
|
||
export const boardInfo = [ | ||
{ | ||
|
@@ -197,10 +197,10 @@ export const boardInfo = [ | |
title: "Philanthropy Chair", | ||
color: "csa-yellow-300", | ||
}, | ||
{ | ||
image: Stephanie, | ||
name: "Stephanie Huang", | ||
title: "Academic Chair", | ||
color: "csa-yellow-300", | ||
}, | ||
// { | ||
// image: Stephanie, | ||
// name: "Stephanie Huang", | ||
// title: "Academic Chair", | ||
// color: "csa-yellow-300", | ||
// }, | ||
Comment on lines
+200
to
+205
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why'd you comment this out? |
||
]; |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,6 +22,13 @@ | |
}, | ||
"incremental": true | ||
}, | ||
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], | ||
"include": [ | ||
"next-env.d.ts", | ||
"**/*.ts", | ||
"**/*.tsx", | ||
".next/types/**/*.ts", | ||
"src/components/board/Board.js", | ||
"src/components/board/BoardCard.js" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. remove since you should be using tsx files |
||
], | ||
"exclude": ["node_modules"] | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all the other colored diamonds will need to be added