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

update-contributors-section #64

Merged
merged 7 commits into from
Feb 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 6 additions & 18 deletions src/components/Members.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,10 @@ function Members() {
{ id: 5, firstName: 'Sarah', lastName: 'Lilly-Bruland', title: 'Admin Emeritus', imgUrl: 'https://avatars.githubusercontent.com/u/17872422?v=4' },
{ id: 6, firstName: 'Justin', lastName: 'Woodward', title: 'Admin Emeritus', imgUrl: 'https://avatars.githubusercontent.com/u/17994108?v=4' },
]
const members = [
{ id: 0, name: 'John', imgUrl: '/head.png' },
{ id: 1, name: 'Ismael', imgUrl: '/head.png' },
{ id: 2, name: 'Nirvignesh', imgUrl: '/head.png' },
{ id: 3, name: 'Tijana', imgUrl: '/head.png' },
{ id: 4, name: 'Jennifer', imgUrl: '/head.png' },
{ id: 5, name: 'Kellan', imgUrl: '/head.png' },
]

return (
<div>
<div className="members">
<div className="admins">
<h3>Meet the Admins</h3>
<div className="row">
{admin.map((member) =>
Expand All @@ -30,16 +23,11 @@ function Members() {
)}
</div>
</div>
<div className="members">
<div className="contributors">
<h3>Meet the Contributors</h3>
<div className="row">
{members.map((member) =>
<div key={member.id}>
<img className='avatar member-avatar' src={member.imgUrl} alt={`beautiful headshot of ${member.name}.`} />
<h4>{member.name}</h4>
</div>
)}
</div>
<a className="contributors-link" href="https://github.com/FCCColumbus/cbus-web/graphs/contributors" rel="noreferrer" target="_blank">
<img className='contributors-avatar' src='https://contrib.rocks/image?repo=FCCColumbus/cbus-web' alt='beautiful headshots of our members' />
</a>
</div>
</div>
);
Expand Down
29 changes: 13 additions & 16 deletions src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -187,12 +187,17 @@ th {
width: 33%;
}

.members {
.admins,
.contributors {
display: flex;
flex-flow: column nowrap;
align-items: center;
}

.contributors {
margin-bottom: 25px;
}

.row {
display: flex;
flex-direction: row;
Expand All @@ -211,17 +216,15 @@ th {
width: 140px;
}

.member-avatar {
height: 100px;
width: 100px;
border-radius: 50%;
.members-avatar, .contributors-avatar {
width: 1000px;
}

.members h4 {
.admins h4 {
margin: 5px 0 5px 0;
}

.members h5 {
.admins h5 {
margin-top: 15px;
}

Expand Down Expand Up @@ -256,13 +259,7 @@ footer img {
max-width: 100%;
}

/* Responsive adjustments */
@media (min-width: 768px) {
.splash {
grid-template-columns: 1fr 1fr; /* 2 columns for wider screens */
}

.byline, .splash img {
grid-column: auto; /* Resets to default grid behavior */
}
.contributors-link {
text-decoration: none;
color: #707070;
}
78 changes: 13 additions & 65 deletions src/test/components/__snapshots__/Members.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
exports[`Members renders 1`] = `
<div>
<div
className="members"
className="admins"
>
<h3>
Meet the Admins
Expand Down Expand Up @@ -126,75 +126,23 @@ exports[`Members renders 1`] = `
</div>
</div>
<div
className="members"
className="contributors"
>
<h3>
Meet the Contributors
</h3>
<div
className="row"
<a
className="contributors-link"
href="https://github.com/FCCColumbus/cbus-web/graphs/contributors"
rel="noreferrer"
target="_blank"
>
<div>
<img
alt="beautiful headshot of John."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
John
</h4>
</div>
<div>
<img
alt="beautiful headshot of Ismael."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
Ismael
</h4>
</div>
<div>
<img
alt="beautiful headshot of Nirvignesh."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
Nirvignesh
</h4>
</div>
<div>
<img
alt="beautiful headshot of Tijana."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
Tijana
</h4>
</div>
<div>
<img
alt="beautiful headshot of Jennifer."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
Jennifer
</h4>
</div>
<div>
<img
alt="beautiful headshot of Kellan."
className="avatar member-avatar"
src="/head.png"
/>
<h4>
Kellan
</h4>
</div>
</div>
<img
alt="beautiful headshots of our members"
className="contributors-avatar"
src="https://contrib.rocks/image?repo=FCCColumbus/cbus-web"
/>
</a>
</div>
</div>
`;