Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

responsive blog preview page using flexbox

jmortada 50

@jmortada

Desktop design screenshot for the Blog preview card coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


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

i did mobile fist

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

no challenges encountered, it was a good practice

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

any feedback is appreciated

Community feedback

@krushnasinnarkar

Posted

Hi @jmortada,

Congratulations on successfully completing the challenge!

Your solution looks nice, though there are a couple of things you can improve which I hope will be helpful!

1. Using max-width for .main

Instead of using percentage-based width and height for .main, which is not a best practice, you can use max-width: 400px; (or a width of your choice). This will give the card a fixed maximum width and reduce the card width if the screen size is smaller than the specified width.

.main {
    max-width: 400px;
    width: 100%;
}

2. Improving Content Alignment Inside .main

The technique you used for aligning content inside .main can be improved. Instead of using:

justify-content: space-evenly;
align-content: space-around;
flex-wrap: wrap;

You can use the gap property to add gaps and padding for more effective alignment:

.main {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
}

3. Adding Border and Increasing Border Radius

Add a border to .main and increase the border radius to make it more curvy at the corners:

.main {
    border: 1px solid #ccc;
    border-radius: 15px;
}

Summary

  1. Use max-width for .main instead of percentage-based width.
  2. Use the gap property and padding for effective alignment inside .main.
  3. Add a border and increase the border radius for a more polished look.

I hope you find this helpful, and I would greatly appreciate it if you could mark my comment as helpful if it was.

Feel free to reach out if you have more questions or need further assistance.

Happy coding!

Marked as helpful

0

jmortada 50

@jmortada

Posted

@krushnasinnarkar thank u for the feedback I will definitely use those in the upcoming challenge although I am not familiar with (gap) I will look into it since it will prove useful again thanks for the feedback

0

Please log in to post a comment

Log in with GitHub
Discord logo

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