Skip to content

Conversation

@Evip88
Copy link

@Evip88 Evip88 commented Oct 14, 2025

@JennieDalgren JennieDalgren self-assigned this Oct 26, 2025
Copy link

@JennieDalgren JennieDalgren left a comment

Choose a reason for hiding this comment

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

Great job with this project! Your meeting the requirements and some stretch goals.

Your code is well structured and easy to follow, you use enough amount of comments and you are working really good with functions!

I would like to see more commits for upcoming projects. It's a great way to follow your process and learning curve. Both for you, us, fellow students and future recruiters.

Keep up the good work 💪


.controls__container > button {
color: #0018a4;
border: none;

Choose a reason for hiding this comment

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

To avoid the "jumping" of the buttons when you hover over them you could change the border: none; to border: 2px solid transparent;


function setActiveSort(direction) {
// Validate: asc | desc
const dir = direction === "asc" ? "asc" : "desc";

Choose a reason for hiding this comment

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

nice to use ternary operators here.

const dir = direction === "asc" ? "asc" : "desc";
sortQueryParam = `&sort=time&sortDirection=${dir}`;

const btn = document.getElementById(`sort__${dir}`);

Choose a reason for hiding this comment

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

clever to use the variable to get the correct element from the DOM

Comment on lines +72 to +78
function formatTime(totalMinutes) {
const h = Math.floor(totalMinutes / 60);
const m = totalMinutes % 60;
if (h && m) return `${h}h ${m}m`;
if (h) return `${h}h`;
return `${m}m`;
}

Choose a reason for hiding this comment

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

nice

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