Design comparison
Solution retrospective
Any feedback would be greatly appreciated!
Community feedback
- @correlucasPosted about 2 years ago
๐พHello @dhdbrud318, Congratulations on completing this challenge!
Your component is perfect, but is not responsive yet, this is due the
fixed width
you've applied to the container.Look both
width
andmax-width
the main difference between these properties is that the first(width) is fixed and the second(max-width) isflexible
, for example, a component withwidth: 320px
will not grow or shrink because the size will be ever the same, but a container withmax-width: 320px
ormin-width: 320px
can grow or contract depending of the property you've set for the container. So if you want a responsive block element, never usewidth
choose ormin-width
ormax-width
.To improve the card overall responsibility, you can start to add
flex-wrap
inside the class that manage the section for therating numbers button
and make the adjust to fit in different rows while the container scales down, not that without this property the container doesn't shrink. Here's the code applying these changes:.score-row { display: flex; justify-content: space-between; margin-bottom: 0.5rem; flex-wrap: wrap; }
โ๏ธ I hope this helps you and happy coding!
Marked as helpful0 - @hyrongennikePosted about 2 years ago
Hi @dhdbrud318,
Congrats on completing the challenge
Instead of using a browser alert box which is bad for user experience I would suggest just disabling the button until a rating is selected this can be done by adding the disabled attribute on the button and removing it when the rating is clicked.
Also check the report above there are quite a bit of issues.
Hope this is helpful, let me know if you have any other question.
Marked as helpful0
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