Skip to content

Commit 2f12aff

Browse files
committed
Capitalized letters to the project-names.
1 parent 271b1ae commit 2f12aff

2 files changed

Lines changed: 12 additions & 16 deletions

File tree

code/script.js

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ fetch(repos)
1414
console.log(data)
1515
//Fetching only the forked repos and the ones starts with "project" from my GitHub account.
1616
const forkedRepos = data.filter(repo => repo.fork && repo.name.startsWith('project'))
17-
// change back to only "project" later
18-
17+
18+
1919
//Username and userpic
2020
profileContainer.innerHTML+= `
2121
<img class="img" src="${data[0].owner.avatar_url}" alt="profile picture">
@@ -25,14 +25,19 @@ fetch(repos)
2525
// Repos and fetched pulls from the functions down under.
2626
forkedRepos.forEach((repo) => projects.innerHTML += `
2727
<div class="repos" id="repos">
28+
29+
2830
<a href="${repo.html_url}"><h3>${repo.name.substring(8).replace("-"," ")}</h3></a>
31+
32+
2933
<p>The default branch is: ${repo.default_branch}</p>
30-
<p>The latest push: ${new Date(repo.pushed_at).toLocaleDateString()}</p>
34+
<p>The latest push: ${new Date(repo.pushed_at).toLocaleDateString().capitalizeFirstLetter}</p>
3135
<p id="pull-${repo.name}">No pull request is yet made 🤷 </p>
3236
<p id="commits-${repo.name}">There are no commits yet...</p>
3337
</div>
3438
`)
35-
39+
40+
3641
drawChart(forkedRepos.length)
3742
getPullRequests(forkedRepos)
3843
})
@@ -75,15 +80,4 @@ const getCommitsForPullRequests = (pullRequests, repo) => {
7580

7681
})
7782
})
78-
}
79-
80-
81-
82-
83-
84-
85-
86-
87-
88-
89-
83+
}

code/style.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ a {
3333
text-align: center;
3434
text-decoration: none;
3535
line-height: 2.5em;
36+
text-transform:capitalize;
37+
3638
}
3739

3840
a:hover {

0 commit comments

Comments
 (0)