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

3-column-preview-component-card

batuhan•60
@bacayo
A solution to the 3-column preview card component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


  • I am unsure of mobile design. It could be better implemented.
Code
Couldn’t fetch repository

Please log in to post a comment

Log in with GitHub

Community feedback

  • IRVINE MESA•1,835
    @DrMESAZIM
    Posted over 3 years ago

    hi @bacayo .To help you with mobile responsiveness of the site here are some steps I took

    1. In that fact I cant make changes to your GitHub code I downloaded the code first

    2. style.css line 29, line 34 , line 35 and line 107 remove everything

    3. style.css line 31 set height to 80%

    4.Add this media query at the bottom of style.css file or line 132

     @media screen and (min-width: 1000px) {
    

    .card {display: flex; }

    }

    let me know how this changes will work out

    Marked as helpful
  • Yemisrach•1,430
    @Yemisrach15
    Posted over 3 years ago

    Hey Batuhan

    The mobile design looks ok. However, on the desktop the icons and buttons are outside of their section. Remove height: 50% on .card to correct it. As Samuel said above, only one element can have the same id in a page. Instead use classes to give multiple elements the same style. It's great that you've used semantic HTML👏🏾

    Happy coding!

    Marked as helpful
  • Samuel M. Setiawan•200
    @samuelms21
    Posted over 3 years ago

    Hey there. You might want to add some padding to your columns and customize your right and left padding for your buttons. Here is how you can do it:

    1. Buttons : Instead of writing padding: 17px, you can write padding: 17px 30px. This will expand your x-axis padding (left and right) so your text can stay on the same line!
    2. Columns: You can add padding to your columns (all three of them) by writing
    .card > * {
        padding: 20px;
    }
    

    The code .card > * just means that you are selecting all child elements of the element with the class card.

    Also, I think your understanding of classes and ids might be a little off. You can only have an id for a single element. No other element should have that id. Classes however, you can use it for several elements in your HTML. If you want to have an id for every single column element you have, then you have to put different id names for every one of them.

    Marked as 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

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

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