TESTIMONIALS GRID SECTION - "Trying to master the css grid"
Design comparison
Community feedback
- @HassiaiPosted almost 2 years ago
Replace <div class="container">with the main tag to fix the accessibility issue. click here for more on web-accessibility and semantic html
To center .container on the page using grid, add min-height:100vh; display: grid place-items: center to the body.
To center .container on the page using grid: body{ min-height: 100vh; display: grid; place-items: center; }
Hope am helpful.
Well done for completing this challenge. HAPPY CODING
Marked as helpful1 - @MelvinAguilarPosted almost 2 years ago
Hello there π. Good job on completing the challenge !
I have some suggestions about your code that might interest you.
HTML π:
-
It is generally not recommended to use multiple <h1> tags on a single web page because the <h1> tag is used to mark the most important heading on a web page and it is considered the top-level heading in the document outline. It should be used only once on the page, typically for the title or main heading of the page.
You can read more about this here π.
-
The image with the testimonial author is not a decoration, you need to provide an alternative text to tell the user who is the author of the testimonial, its recommended to use the author's name as the
alt
attribute value. e.g.alt="Daniel Clifford"
If you want to learn more about the
alt
attribute, you can read this article. π.
-
To improve the semantics of your code you should use the
<blockquote>
tag to wrap the testimonial. e.g.:<figure> <blockquote> <p>"Example of a testimonial"</p> </blockquote> <figcaption> <p>Example of the author</p> </figcaption> </figure>
You can read more about the
<figure>
and<blockquote>
tags with this two links:
I hope you find it useful! π Above all, the solution you submitted is great!
Happy coding!
Marked as helpful0 -
Please log in to post a comment
Log in with GitHubJoin 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