Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted about 1 year ago

Blog preview card (HTML and CSS)

P
ComputerEnjoyer•160
@ComputerEnjoyer
A solution to the Blog preview card challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


What are you most proud of, and what would you do differently next time?

Proud of:

  • It went quick
  • Really feeling like I'm getting flexbox (with some exceptions)

Would do differently:

  • Not really sure. This was pretty straightforward.
What challenges did you encounter, and how did you overcome them?

The design file doesn't give very clear guidance on breakpoints so I'm hoping my solution aligns with what the designers are asking for.

I really struggled with getting the flex container on the card to actually shrink with a change in the viewport size. This is because I didn't have the img width set to 100% 😅

I tried setting a breakpoint with a @container query but it was doing very wonky things with the card component so I abandoned that idea for a simple media query on the screen.

What specific areas of your project would you like help with?

Is there a more elegant way to handle changes to the presentation of the .blog-preview-card element?

Code
Loading...

Please log in to post a comment

Log in with GitHub

Community feedback

No feedback yet. Be the first to give feedback on ComputerEnjoyer's solution.

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

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner
  • Use cases

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License