Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted about 3 years ago

Responsive Web Design with BEM, Flexbox, Semantic Tags HTML5, CSS3

accessibility
Vikram Ingleshwar•280
@vikramvi
A solution to the Profile card component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


  • Please review for BEM and Flexbox best practices
  • HTML5 SEO and Accessibility good practices
  • I'm breaking down styling into small chunks possible and doing regular commits, which is helping me a lot. You can check those in commits
  • Any other suggestion is welcome as well.
  • Had faced challenge with placing multiple background images, but could solve it after lots of proper googling and reading answers patiently
Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Fluffy Kas•7,655
    @FluffyKas
    Posted about 3 years ago

    Hello,

    Your solution looks pretty good! Your code is easy enough to read so well done on that part. I do have some suggestions though:

    1. There are a few html elements here that you're not using correctly: a) <figure> isn't needed for wrapping images, if you're not going to pair it with a figcaption. Either just use a div or don't use a wrapper for the image at all (if you can avoid). b) <summary> is used as a sort of heading for the <details> element. If you would like to wrap things in something for styling, div serves exactly this purpose. c) Same goes for the <section> element. It's being overused, even though it's not a semantic element by itself. I suggest swapping most of your sections for divs, except maybe the outer one named "profile" that could actually be an <article>.

    2. For the alt text of the profile pic, it's best to replace it with the person's name. So "Victor Crest." would be the most appropriate alt text for this.

    3. If you'd like to give the body some height, you should use min-height instead so you don't lock it to a fixed value.

    4. There's actually a super easy way to solve the background circles! They can all be added to the same element (body) and then you can use viewport units to position them, much like how I did it in my solution(please forgive me for linking it here, I'm not fishing for likes, just thought it might be easier if you check out the actual code ^^).

    Everything else seems really good! I'm not an expert on BEM, I rarely use it but from my little experience, your naming seems fine and it's easy to follow. Happy coding! ^^

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 1st-party linked stylesheets, and styles within <style> tags.

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.

Oops! 😬

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

Log in with GitHub