Design comparison
Solution retrospective
I am proud that I was able to use CSS grid effectively to finish the challenge.
What challenges did you encounter, and how did you overcome them?Some challenges I faced included, getting the image on the same line as the and as well as figuring out the CSS grid layout, and trying to get the SVG image on the purple card to work accordingly. I overcame all of these buy practicing and looking online.
What specific areas of your project would you like help with?I am curious how I can get the SVG image to work accordingly during the changing of the width. I originally used img."quotation" to make sure that it bypassed any other styles, however this also caused it to bypass the responsiveness and resulted in it not working accordingly. What was causing the "quotation" class to not working the way it should be intended.
Community feedback
- Account deleted
Hello, good job. Here are some recommendations I'd like to share:
-
Try setting
position: relative
to .card instead of .cards img, and addtop: 0
to mg.quotation so that it stays in the correct position relative to the .card container. This might solve the overflow issue you are experiencing when reducing the screen size. -
To ensure everything is centered on the screen, I recommend adding
min-height: 100vh; display: grid; place-items: center
to the body element. -
Additionally, instead of using
grid-template-columns
withorder
for the cards, you could implement the following css lines:
.cards { grid-auto-columns: 1fr; grid-template-areas: 'one one two three' 'four five five three' ; } And for each '.card', do something like: .purple { grid-area: one; } .grey { grid-area: two; } ...
- Additionally, I believe you could benefit from adopting a CSS naming convention such as the BEM Methodology. For more info, visit BEM
I hope this helps. Good luck!
1 -
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