Skip to content
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 officer card data and semester data #35

Merged
merged 10 commits into from
Dec 13, 2023
Merged

Conversation

Phantom0110
Copy link
Contributor

@Phantom0110 Phantom0110 commented Nov 21, 2023

Added officer card and semester objects with Brian's help.

@Phantom0110 Phantom0110 requested a review from a team November 21, 2023 03:59
@Phantom0110 Phantom0110 marked this pull request as ready for review December 9, 2023 02:56
Copy link
Member

@WillBAnders WillBAnders left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes for a few things in the rendering logic

Looking at officer data, I'm noticing some quirks here with how this is designed. In the interest of time and drawing this to a close I'm going to open a PR off of this one to make improvements here and then we can merge that into this PR. That'll give you a chance to review it and highlight differences rather than correcting things here.


export default function About() {
const officerCards = officerCardData.map((cardData) => (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Nit]: Development comments like this should be cleaned up before merging under most situations.

([semester, officers]) => {
const officerCards = Object.entries(officers).map(
([position, officer]) => {
if (officer === undefined) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Please Change]: From our discussion the handling here has been changed and this check is no longer needed.


return (
<OfficerCard
key={`${semester} ${position}`}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Please Change]: We can use just position as the key here because it's unique within each semester. In other words; we don't need to ensure the keys are unique across both loops; just the current one.

);

return (
<React.Fragment key={semester}>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Comment]: Great use of React.Fragment here - definitely how I would have gone about this to avoid some unnecessary div wrapping.

@@ -41,7 +71,8 @@ export default function About() {
<section className={styles.officers}>
<div className={styles.container}>
<h2>Officers</h2>
<div className={styles.cardContainer}>{officerCards}</div>
{/* <div className={styles.cardContainer}>{officerCards}</div> */}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Nit]: Can be cleaned up as above.

@@ -26,7 +31,7 @@ const officerCardData: OfficerCardProps[] = [
],
},
{
position: "Treasurer",
position: "Tresurer",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Comment]: Some of the changes in here have spelling mistakes; also noticing the officer images added in this specific commit are invalid and can't be displayed - maybe this commit wasn't intended to be included?

See review summary notes - will address issues related to officer data separately.

Copy link
Member

@WillBAnders WillBAnders left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM following #37!

@Phantom0110 Phantom0110 merged commit 5f064b7 into master Dec 13, 2023
1 check passed
@Phantom0110 Phantom0110 deleted the feature/past-officers branch December 13, 2023 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Expand the Officers section to include past officers
3 participants