Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted 11 months ago

CSS Grid, nth-child(#), selectors, class, flex, blockqoute,

P
Nico•330
@Nico243
A solution to the Testimonials grid section 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?

This was my greatest challenge I've had. It took mistakes and errors and constantly adapting to new techniques and methods to help me through this. The inspection tool was my best friend for the grid layout.

Now that I have an Idea how the structure is going to look and how I could achieve the layout, I'm going to look a little more deeper on how I could right this code cleaner for readability and accessibility.

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

CSS Layout Alignment

Challenge: One of the difficult parts initially in aligning elements within the testimonial grid and handling images and text properly.

Solution: By playing around with CSS properties such as display: grid, grid-template-areas, and using flexbox (display: flex), I was able to control the layout and position elements next to each other. For precise positioning, I've learnt how to adjust margins, padding and align-items.

Background Image Positioning

Challenge: There was a problem of getting the SVG (quotation pattern) to appear at the right place in the first testimonial.

Solution: After trial and error, I have learned that adjusting background-position and background-size can put SVGs where they should be. This needed deep knowledge on functioning of CSS background properties as well as exactly how pictures ought to be aligned.

Media Queries for Responsive Design

Challenge: It was complicated because my layout shifted dramatically when applying different screen sizes, making it hard to use grid-template-areas in media queries for responsive design of testimonial layouts.

Solution: I tried out several alternatives for grid-template-areas setups and found that by changing configurations differently for certain screen width ranges, you could keep things consistent across all devices.

Font Sizing and styling in css

Challenge: Ensuring font size and weight using CSS variables and the second had different styling.

I've learned how to apply specific classes and make use of CSS ('var(()') to manage typography. I've also used inline styles to override inherited styles when needed

SVG handling & Positioning

Challenge: Intergration of SVG image inside a specific testimonial and aligning it perfectly.

Solution: using a testimonial:nth-child(1) to place the svg in it's correct container

Frustration and Overwhelmed

Challenge: Feeling overwhelmed by the complex system of CCS layouts, when smaller changes would drastically alter my design.

Solution: I've persisted through, frequently asking questions to gain clarification, watching tutorial videos. By breaking the challenges into smaller, more manageable tasks, I made progress step by step.

using advanced CSS techniques

Challenge: The us of advanced techniques like nth-child, grid-template-areas and media queries felt unfamiliar and difficult to implement

Solution: I've practiced wit examples, Adjust my layout based on feedback from others, and slowly became more comfortable using these techniques.

It comes down to persistence to testing different solutions, asking the correct questions, breaking the complex layout into smaller tasks which helped me overcome these challenges

Code
Couldn’t fetch repository

Please log in to post a comment

Log in with GitHub

Community feedback

  • SemptechVzla•150
    @SemptechVzla
    Posted 11 months ago

    Very nice!

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