Skip to content

Week 7 Github Tracker by Lousanne#56

Open
loulunds wants to merge 16 commits intoTechnigo:mainfrom
loulunds:main
Open

Week 7 Github Tracker by Lousanne#56
loulunds wants to merge 16 commits intoTechnigo:mainfrom
loulunds:main

Conversation

@loulunds
Copy link
Copy Markdown

@loulunds loulunds commented Oct 4, 2021

This project is both challenging and fun to do! Getting to use a more complex API like Github's made me realize that it can be very intimidating to use in the beginning. I would say that I really llike how my project turned out this week. I also got to really learn how to use grid. I also made a light and dark mode inspired by Github's page by using toggle.

Copy link
Copy Markdown

@ebbadelsol ebbadelsol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The website looks and functions very well. Great job!! The search-function and light/dark-mode is extra impressive. I also like that you fetched for individual and teams-projects.

Overall your code was really nice and easy to go thru since it was well formatted and you have added great descriptive comments. You have also succeeded in doing more advanced code. Great job!!

Comment on lines +24 to +25
"Individual Projects",
"Team Projects",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really like that you added individual and team projects to you chart!

code/index.html Outdated
Comment on lines +13 to +77
<!-- mobile nav -->
<nav class="nav-mobile">
<img id="nav-sub" class="nav-menu" src="images/menu (1).png" alt="menu" />
<div class="nav-links">
<input
id="navInputMobile"
class="nav-input"
type="text"
placeholder="Search"
/>
<a href="#">Pulls</a>
<a href="#">Issues</a>
<a href="#">Marketplace</a>
<a href="#">Explore</a>
</div>
<a class="nav-icon" href="https://github.com/" target="_blank"
><img src="images/GitHub-Mark-Light-32px.png" alt="github"
/></a>

<button id="btn-light-nav">
<img class="nav-notif" src="images/notification.png" alt="bell" />
</button>
</nav>

<!-- desktop nav -->
<nav class="nav-desktop">
<a class="nav-icon" href="https://github.com/" target="_blank"
><img
id="nav-github-img"
src="images/GitHub-Mark-Light-32px.png"
alt="github"
/></a>
<input id="navInput" class="nav-input" type="text" placeholder="Search" />
<div class="nav-a">
<a href="#">Pulls</a>
<a href="#">Issues</a>
<a href="#">Marketplace</a>
<a href="#">Explore</a>
</div>
<button id="btn-light">
<img class="nav-notif" src="images/notification.png" alt="bell" />
</button>
</nav>

<!-- main content -->
<main>
<!-- where the user info is -->
<section id="userInfo"></section>

<!-- where the repos are -->
<section id="projects">
<h2 class="project-title">My Project Repositories with Technigo</h2>
<div id="project-box"></div>
</section>
</main>

<!-- This will be used to draw the chart 👇 -->
<section class="canvas-box"><canvas id="chart"></canvas></section>

<footer><img src="images/mylogo.png" alt="logo" /></footer>

<script src="./script.js"></script>
<script src="./chart.js"></script>
</body>
</html>
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great that you added descriptive comments to your code! Makes it really nice and easy to go thru.

code/script.js Outdated
Comment on lines +10 to +11
const turnLightMode = document.getElementById("btn-light");
const turnLightModeMobile = document.getElementById("btn-light-nav");
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love the light and dark mode!!

Comment on lines +173 to +186
// turns the light mode on
const toLightMode = () => {
document.body.classList.toggle("light");
document.getElementById("userSpan").classList.toggle("user-span-light");
document.getElementById("userSpanSub").classList.toggle("user-span-light");
};

turnLightMode.addEventListener("click", (e) => {
toLightMode();
});

turnLightModeMobile.addEventListener("click", (e) => {
toLightMode();
});
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love this!! Great job!!

code/style.css Outdated
body {
background: #FFECE9;
} No newline at end of file
@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500&family=Roboto&display=swap");
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I usually put the link to the fonts in the head of the html. Is there a specific reason for why you put it in the stylesheet or is it just a preference?

padding: 5rem;
}

.nav-links > * {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool!

.nav-menu {
grid-area: menu;
height: 2rem;
z-index: 10;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you only need to use z-index: 1; for this. Everything else should be on z-index 0.

Comment on lines +152 to +171
// event listener
input.addEventListener("keypress", (event) => {
if (event.key === "Enter" && input.value) {
let userName = "";
userName = input.value;
getUserData(userName);
fetchRepos(userName);
}
});

// for mobile input
inputMobile.addEventListener("keypress", (event) => {
if (event.key === "Enter" && inputMobile.value) {
let userName = "";
userName = inputMobile.value;
getUserData(userName);
fetchRepos(userName);
toggleNav();
}
});
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome and inspiring that you did advanced level of code (by implementing a search field)!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants