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

feat: add publication date field for each contributor #39

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
1 change: 1 addition & 0 deletions gatsby-node.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ exports.createPages = ({ graphql, actions }) => {
slug
}
pageAttributes {
datepublished
name
pronouns
location
Expand Down
1 change: 1 addition & 0 deletions src/pages/contributors/alexander-brandes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
:page-pronouns: He/Him
:page-location: Kassel, Germany
:page-firstcommit: 2019
:page-datepublished: 2023-11-29
:page-featured: true
:page-intro: Alexander Brandes is an open-source contributor and maintainer and serves on the Jenkins governance board. He has made contributions to multiple aspects of the Jenkins project including Jenkins Core, multiple plugins, weekly and Long Term Support releases, and the community.

Expand Down
11 changes: 11 additions & 0 deletions src/pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,16 @@ const IndexPage = (props) => {
<Typography variant={"h5"} textAlign={isDesktop ? "left" : "center"}>First Commit: {contributor.node.pageAttributes.firstcommit}</Typography>
</Box>

<Box
marginTop={1}
marginBottom={1}
display={"flex"}
flexDirection={"column"}
width={"100%"}
>
<Typography variant={"h5"} textAlign={isDesktop ? "left" : "center"}>Date Published: <br/>{contributor.node.pageAttributes.datepublished}</Typography>
</Box>

<Box
marginTop={1}
marginBottom={1}
Expand Down Expand Up @@ -202,6 +212,7 @@ export const pageQuery = graphql`
slug
}
pageAttributes {
datepublished
name
pronouns
location
Expand Down
6 changes: 6 additions & 0 deletions src/templates/contributor-details.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,11 @@ function ContributorDetails(props) {
{"First Commit: " + props.data.asciidoc.pageAttributes.firstcommit ?? "Unknown"}
</Typography>
</Box>
<Box sx={{paddingBottom: 1.5}}>
<Typography variant={"h6"} textAlign={"center"}>
{"Date Published: " + props.data.asciidoc.pageAttributes.datepublished}
</Typography>
</Box>
<Box display={"flex"} alignItems={"center"} justifyContent={"center"} gap={1} sx={{paddingBottom: 2}}>
{props.data.asciidoc.pageAttributes.linkedin !== ""
&& <Link to={`https://www.linkedin.com/in/${props.data.asciidoc.pageAttributes.linkedin}`}><LinkedInIcon/></Link>}
Expand Down Expand Up @@ -105,6 +110,7 @@ export const pageQuery = graphql`
main
}
pageAttributes {
datepublished
name
pronouns
location
Expand Down