diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 00000000..afb61c74 Binary files /dev/null and b/.DS_Store differ diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..a76fd6e1 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +code./secret.js \ No newline at end of file diff --git a/README.md b/README.md index 1613a3b0..7442a16e 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,21 @@ # GitHub Tracker -Replace this readme with your own information about your project. +In this project we were suppose to build a tracker of all our projects related to Technigo using GitHub API. The site should include: + + +- A list of all repos forked from Technigo +- Username and profile picture +- Most recent push for each repo +- Default branch for each repo +- URL to the actual GitHub repo +- Number of commits per repo +- Chart showing completed projects/total. -Start by briefly describing the assignment in a sentence or two. Keep it short and to the point. ## The problem -Describe how you approached to problem, and what tools and techniques you used to solve it. How did you plan? What technologies did you use? If you had more time, what would be next? +In order to solve the problem I've worked with API's and a personal token. A challening project where there still are things needed to be fixed (when the chart is showing only 2 out of 5 projects are visible). ## View it live -Every project should be deployed somewhere. Be sure to include the link to the deployed project so that the viewer can click around and see what it's all about. +https://jolly-hopper-ee7c71.netlify.app/ diff --git a/code/chart.js b/code/chart.js index 92e85a30..fbb0037e 100644 --- a/code/chart.js +++ b/code/chart.js @@ -1,4 +1,28 @@ //DOM-selector for the canvas 👇 const ctx = document.getElementById('chart').getContext('2d') -//"Draw" the chart here 👇 + +//CHART + +const drawChart = (number) => { + const config = { + type: "doughnut", + data: { + labels: ["DONE", "LEFT TO DO"], + datasets: [ + {label: "PROJECT CHART", + data: [number, 19 - number], + backgroundColor: ["#ff874e", "#db738e"], + hoverOffset: 4, + borderColor: [ + 'rgba(255, 99, 132, 1)', + 'rgba(255, 206, 86, 1)', + ], + borderWidth: 4 + }, + ], + }, + }; + const myChart = new Chart(ctx, config); + }; + \ No newline at end of file diff --git a/code/index.html b/code/index.html index 2fb5e0ae..4183d251 100644 --- a/code/index.html +++ b/code/index.html @@ -4,18 +4,43 @@ -