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

Blog preview card

Jhonne•90
@Jhonneg
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?

Most of the design look clean of first try

What challenges did you encounter, and how did you overcome them?

Not many challenges, had to rewrite some of the code because of bad practices but the design was easy.

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

Any feedback on good practices would be good.

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Rebecca Padgett•2,100
    @bccpadge
    Posted over 1 year ago

    Hello @Jonee2. Congratulations on completing this challenge!!!🎉

    You can wrap the the img and name in a div and then use flexbox to align them. Be sure to change the h3 to a h2 because heading tags must be used in chronological order. You can use gap property to add space between the elements as well.

    div{
     display: flex;
     align-items: center;
    }
    

    I hope you find this useful and don't hesitate to reach out if you have any questions.

  • Grace•32,130
    @grace-snow
    Posted over 1 year ago

    This needs a lot of the same changes as your QR code solution. Apply those here.

    The only additional issues I note are:

    • if using inline svgs they need to either be aria-hidden if they are decorative images, or they need to be accessibly named. This article explains different ways to accessibly name svgs smashingmagazine.com/2021/05/accessible-svg-patterns-comparison. Although, personally I would just use an img tag here.
    • There is no link to the blog, which would make this card unusable. Whenever you see a hover style in a design that means something is interactive (clickable). It's our job as frontend developers to choose the appropriate element depending on what the click would do. In this case it would navigate to a blog post, which means the element must be an anchor (link).
    • I think this design showed that the whole card should be clickable in this case. That means you'd need to use the content-pseudo trick on the link when you add it, as explained on the inclusive components site
    • Don't use <br> to try and create vertical space. Use margin.
  • anass-lamiri•320
    @Anass-Lamiri
    Posted over 1 year ago

    Hi, I suggest you make the profile pic and the name in a div and then make a display flex, with a align-item center.

        display: flex;
        align-items: center;
        gap: 16px;
    

    you can adjust the gap according to the design.

    I hope this feedback is helpful.

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
Frontend Mentor logo

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

Frontend Mentor

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

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

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

How does the accessibility report work?

When a solution is submitted, we use axe-core to run an automated audit of your code.

This picks out common accessibility issues like not using semantic HTML and not having proper heading hierarchies, among others.

This automated audit is fairly surface level, so we encourage to you review the project and code in more detail with accessibility best practices in mind.

How does the CSS report work?

When a solution is submitted, we use stylelint to run an automated check on the CSS code.

We've added some of our own linting rules based on recommended best practices. These rules are prefixed with frontend-mentor/ which you'll see at the top of each issue in the report.

The report will audit all CSS, SCSS and Less files in your repository.

How does the HTML validation report work?

When a solution is submitted, we use html-validate to run an automated check on the HTML code.

The report picks out common HTML issues such as not using headings within section elements and incorrect nesting of elements, among others.

Note that the report can pick up “invalid” attributes, which some frameworks automatically add to the HTML. These attributes are crucial for how the frameworks function, although they’re technically not valid HTML. As such, some projects can show up with many HTML validation errors, which are benign and are a necessary part of the framework.

How does the JavaScript validation report work?

When a solution is submitted, we use eslint to run an automated check on the JavaScript code.

The report picks out common JavaScript issues such as not using semicolons and using var instead of let or const, among others.

The report will audit all JS and JSX files in your repository. We currently do not support Typescript or other frontend frameworks.

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Frontend Mentor for Teams

Frontend Mentor for Teams helps companies and schools onboard and train developers through project-based learning. Our industry-standard projects give developers hands-on experience tackling real coding problems, helping them master their craft.

If you work in a company or are a student in a coding school, feel free to share Frontend Mentor for Teams with your manager or instructor, as they may use it to help with your coding education.

Learn more

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub