Submitted almost 3 years ago
time tracking dashboard main [using: json , mobile-first]
@maym42
Design comparison
SolutionDesign
Solution retrospective
Hi, i would like to get feedback on my code 🧐💻
Community feedback
- @A-amonPosted almost 3 years ago
Hello! It's a very good job~ 😀
Here are a few tiny changes I would suggest:
- Use
<a>
or<button>
for thetime
buttons: Daily, weekly, monthly. (Those on the side) This will let screen reader users to know they are to be clicked. 😉 - Maybe you forgot to set the current
time
button's color when the page first loads. - I noticed there are repetitive Js code. Maybe, you can create a single function that can replace the showWeekly, showMonthly, etc. For example:
function showCardContent(time, data){ for (let i = 0; i < cardsTitles.length; i++) { currents[i].innerText = data[i].current + "hrs"; prevs[i].innerText = `Last ${time}- ` + data[i].previous + "hrs"; } /*play the animation */ addAnimationFadeIn(); }
The code above may or may not work but the general idea is there! 😁
Marked as helpful0 - Use
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord