Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Social Proof Page

Trey 290

@willetto

Desktop design screenshot for the Social proof section coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Please no copy/paste comments. :)

I would love to know a better way of adding the rating stars without pasting the <img> tag 15 times.

What do you think was the most elegant way to offset/stagger the ratings and purple cards? I ended up using translateX and Y.

Community feedback

@florianstancioiu

Posted

Hi,

I don't think there's a better way of adding the stars (there is another way of adding the images that would not involve writing them multiple times but the click functionality would be lost and without it, the ratings are useless).

As for the ratings, I used position: relative and set the left property to a negative value. The ratings could have been done also using a negative margin but I think the way you did it with translate is probably the most elegant way.

Keep on coding!

Marked as helpful

1

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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