Design comparison
Solution retrospective
The background image won't apply to the whole page, like it's indicated in the file, so i put a background color instead.
Edit: -Fixed background image issue -Changed button background color -Fixed accessibility
Community feedback
- @katrien-sPosted about 3 years ago
The background-image doesn't load because you didn't set your path right. Try this:
background-image: url("../images/pattern-background-desktop.svg");
You need to escape the css-folder and dive into images, hence the 2
..
Marked as helpful1@B0R155Posted about 3 years ago@graficdoctor Thanks a lot! Any other comments about the code in general? This is my first project ever, so really anything could be useful.
0 - @kens-visualsPosted about 3 years ago
Hey @B0R155 👋🏻
I have some suggestions on that will help you fix the accessibility issues and, perhaps, get rid of some unused pieces of code.
- In your markup <div class="card">...</div> should be <main class="card">...</main>, so this will fix the accessibility issues. Don't forget to generate a new report once you fix it.
- For the image, this is the only code you need:
.card img { display: block; width: 100%; margin-bottom: 10px; }
<h2>
should be<h1>
because it's the heading, and probably you forgot to include bolderfont-weight
, that's why this line doesn't workfont-weight: 900;
box-sizing: border-box;
should be inhtml
, so it affects the whole document, instead of adding to individual items.- Also, I'd suggest tweaking the
background-color
of the button.
I hope this was helpful 👨🏻💻 for the very first project, you did a great job, keep practicing. Cheers 👾
Marked as helpful0@B0R155Posted about 3 years ago@kens-visuals Thanks a lot for the feedback! I will try to update the code as soon as i can.
0
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