Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.
Open
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
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,13 @@
<hr>

#### Why do I exist?
### 2020 has been a challenging year for all of us.

### 2021 has been a challenging year for all of us.

As the year is ending, we thought to take a look back at all the contributions **you** as an individual
made to the open-source community, during these unprecedented times.

Also, since Spotify, Snapchat and other mass platforms have their own way of year wrap up, **why not us?**
Also, since Spotify, Snapchat and other mass platforms have their own way of year wrap up, **why not us?**

<center><pre><a href="https://githubwrapped.tech">githubwrapped.tech</a></pre></center>

Expand All @@ -31,7 +32,6 @@ You can also save your report as an image using the 'Save Report' button and sha

#### Project Structure


This project uses [React.Js](https://reactjs.org) and the contents are bundled using webpack.

The contents in this project follow the following structure.
Expand All @@ -48,6 +48,7 @@ The contents in this project follow the following structure.
```

Each individual component and container, follows this structure

```
section
├──index.jsx (main entry point)
Expand Down
6 changes: 3 additions & 3 deletions api/fetch.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const fetchTotalStars = (parameters, token) => {
const fetchTotalCommits = (variables, token) => {
return axios({
method: "get",
url: `https://api.github.com/search/commits?q=author:${variables.login}+committer-date:>2020-01-01`,
url: `https://api.github.com/search/commits?q=author:${variables.login}+committer-date:>2021-01-01`,
headers: {
"Content-Type": "application/json",
Accept: "application/vnd.github.cloak-preview",
Expand All @@ -52,7 +52,7 @@ const fetchTotalCommits = (variables, token) => {
const fetchTotalIssues = (params, token) => {
return axios({
method: "get",
url: `https://api.github.com/search/issues?q=author:${params.login}+is:issue+created:2020-01-01..2020-12-31`,
url: `https://api.github.com/search/issues?q=author:${params.login}+is:issue+created:2021-01-01..2021-12-31`,
headers: {
"Content-Type": "application/json",
Accept: "application/vnd.github.cloak-preview",
Expand All @@ -65,7 +65,7 @@ const fetchTotalIssues = (params, token) => {
const fetchTotalPRs = (params, token) => {
return axios({
method: "get",
url: `https://api.github.com/search/issues?q=author:${params.login}+is:pr+created:2020-01-01..2020-12-31`,
url: `https://api.github.com/search/issues?q=author:${params.login}+is:pr+created:2021-01-01..2021-12-31`,
headers: {
"Content-Type": "application/json",
Accept: "application/vnd.github.cloak-preview",
Expand Down
10 changes: 5 additions & 5 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#040d23" />
<!-- Primary Meta Tags -->
<title>Github Wrapped 2020</title>
<meta name="title" content="Github Wrapped 2020" />
<title>Github Wrapped 2021</title>
<meta name="title" content="Github Wrapped 2021" />
<meta
name="description"
content="Take a look back at all the contributions you as an individual made to the open-source community, during these unprecedented times."
Expand All @@ -30,7 +30,7 @@
<!-- Open Graph / Facebook -->
<meta property="og:type" content="website" />
<meta property="og:url" content="https://githubwrapped.tech/" />
<meta property="og:title" content="Github Wrapped 2020" />
<meta property="og:title" content="Github Wrapped 2021" />
<meta
property="og:description"
content="Take a look back at all the contributions you as an individual made to the open-source community, during these unprecedented times."
Expand All @@ -45,7 +45,7 @@
<meta propert="twitter:creator" content="@ishandeveloper" />
<meta propert="twitter:site" content="@githubwrapped" />
<meta property="twitter:url" content="https://githubwrapped.tech" />
<meta property="twitter:title" content="Github Wrapped 2020" />
<meta property="twitter:title" content="Github Wrapped 2021" />
<meta
property="twitter:description"
content="Take a look back at all the contributions you as an individual made to the open-source community, during these unprecedented times."
Expand All @@ -59,7 +59,7 @@
content="https://githubwrapped.tech/assets/images/link-preview.png"
/>

<title>GitHub Wrapped 2020</title>
<title>GitHub Wrapped 2021</title>
<style>
#wrapper {
position: relative;
Expand Down
22 changes: 10 additions & 12 deletions public/sitemap.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<urlset
xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">


<url>
<loc>https://githubwrapped.tech/</loc>
<lastmod>2020-12-26T14:37:12+00:00</lastmod>
</url>
<url>
<loc>https://githubwrapped.tech/</loc>
<lastmod>2021-12-26T14:37:12+00:00</lastmod>
</url>

<url>
<loc>https://githubwrapped.tech/api</loc>
<lastmod>2020-12-26T14:37:12+00:00</lastmod>
</url>
<url>
<loc>https://githubwrapped.tech/api</loc>
<lastmod>2021-12-26T14:37:12+00:00</lastmod>
</url>

</urlset>
2 changes: 1 addition & 1 deletion src/components/landing-header/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function LandingHeader({
return (
<>
<h2 className="landing__year__in__review">GitHub Wrapped</h2>
<h1 className="landing__2020">2020</h1>
<h1 className="landing__2021">2021</h1>

<p className="landing__p1">
This has been a challenging year for all of us.
Expand Down
11 changes: 9 additions & 2 deletions src/components/report/index.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
import React from "react";
import "./style.scss";

export default function Report({ username, commits, stars, pr, issues, reportReference }) {
export default function Report({
username,
commits,
stars,
pr,
issues,
reportReference,
}) {
const dataFormatter = (data) => {
if (data > 1000) {
return `${(data / 1000).toFixed(1)}k`;
Expand All @@ -18,7 +25,7 @@ export default function Report({ username, commits, stars, pr, issues, reportRef
<span className="highlight">{username}</span> 's
</h2>
<div className="report__header">
<h2>2020</h2>
<h2>2021</h2>
<h4>Year in review</h4>
</div>

Expand Down
4 changes: 1 addition & 3 deletions src/containers/landing/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
}
}

.landing__2020 {
.landing__2021 {
font-weight: 500;
font-size: 4rem;
}
Expand All @@ -49,8 +49,6 @@
font-weight: 300;
margin: 0.5rem 0;



@media screen and (max-width: 720px) {
font-size: 0.9rem;
}
Expand Down
2 changes: 1 addition & 1 deletion src/containers/profile/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ export default function ProfilePage() {
<a
target="_blank"
rel="noopener"
href={`https://twitter.com/intent/tweet?original_referer=https://githubwrapped.techF&ref_src=twsrc%5Etfw&text=In 2020 I made over ${report.commits}%2B commits and ${report.pullrequests} Pull Requests towards open-source! Check how your %23GithubWrapped up in 2020 at&tw_p=tweetbutton&url=githubwrapped.tech`}
href={`https://twitter.com/intent/tweet?original_referer=https://githubwrapped.techF&ref_src=twsrc%5Etfw&text=In 2021 I made over ${report.commits}%2B commits and ${report.pullrequests} Pull Requests towards open-source! Check how your %23GithubWrapped up in 2021 at&tw_p=tweetbutton&url=githubwrapped.tech`}
className="tweet-btn"
>
<img
Expand Down