@laryssacarvalho
Submitted
I'd like to know if there is a dynamic way to set the different colors for each summary item? Is this class naming convention ok? Besides that, I'd appreciate any kind of feedback. Thanks! :)
Looking to hire developers?
@Alejandro25AR
@laryssacarvalho
Submitted
I'd like to know if there is a dynamic way to set the different colors for each summary item? Is this class naming convention ok? Besides that, I'd appreciate any kind of feedback. Thanks! :)
@Alejandro25AR
Posted
Hello @laryssacarvalho congratulations for completing the challenge
// Block
.score-summary {...}
// Element
.score-summary__item {...}
// Modify
.score-summary__item--red {...}
.score-summary__item--blue {...}
I hope it helps you. Great job, keep practicing.
Marked as helpful
@rhyuen
Submitted
I couldn't get the list of choices to align with the left edge of the card using flexbox and justify-content: 'space-around'. flexbox and justify-content: "flex-start" with a hard coded margin-right also didn't look quite right, so I went with the former.
The background colour for the rating choices didn't seem to match any of the colours in the style guide so I extrapolated using the second darkest blue, the card's colour.
@Alejandro25AR
Posted
Hi @rhyuen.
You can't align the list of options to the left, because the inputs
are still visible and taking up space, so the justify-content:space-between
also affects them. To fix this you could place the hidden entries as follows:
.card-row input {
display:none;
}
// or you could
input[type="radio"] {
display:none;
}
That way they don't take up space and the list is already left-aligned.
Good job, keep up the good work!
Marked as helpful
@tylermaks
Submitted
Hi all,
Here is my solution for the Time Tracker Dashboard challenge. I enjoyed this project and used it as an opportunity to refine and clean up my code. Any thoughts or guidance on how I can improve in this area is appreciated. Specifically, I had a question about If Statements - is there anyways to shorten this code?
const convertTimeframe = () => {
if(props.timeframe === "Daily"){
return "Yesterday"
} else if (props.timeframe === "Weekly"){
return "Last week"
} else if (props.timeframe === "Monthly"){
return "Last month"
}
}
Thanks so much! -Tyler
@Alejandro25AR
Posted
Hi @tylermaksymiw. You can use an object to avoid the if, so you will have a much more scalable and clear code. series as follows:
const convertTimeframe = {
Daily: 'Yesterday',
Weekly: 'Last week',
Monthly: 'Last month'
}
let returnValue = convertTimeframe[props.timeframe];
And that would be all, I hope it helps you. Great job, keep practicing.
Marked as helpful
@MURRAY122
Submitted
Any feedback on this or anything else would be great. Thanks for viewing
@Alejandro25AR
Posted
Hi @murray122,
stroke
instead of fill
.font-weing
property when hovering the menu, as this increases the size of the box, causing a slight displacement of the other elements, which is not very pleasant visually.Good work, keep it up
@aditya-chakraborty
Submitted
Hello people of Frontend Mentor,
I took a desktop-first approach for this challenge. While the CSS I have written gets the job done, I know it can be better. Any tips or feedback on how to improve my CSS and code quality in general would be highly appreciated.
Thanks!
@Alejandro25AR
Posted
Hi, your desktop solution is fine, but you could:
Regarding CSS styles, I would advise you:
Keep practicing, good job.
Marked as helpful