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

i use css grid for resposive

#node#react#vue#axios

@MUKEBUDAVID

Desktop design screenshot for the Product preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


for those who want to access the website, be aware that the images may not load, I don't know why it's on the github page but on my pc it works.

Community feedback

Lucas 👾 104,580

@correlucas

Posted

🗡️Hello Mukebo, congratulations for your solution!

I can see that you're an Aktsuki developer since you've used SCSS, that's amazing. You've forgot only a small detail when you've imported the photo using the background-image property. Remember to indicate the image location when you're not working locally, you need to use ./ to indicate the image is one level folder and ../ to indicate a subfolder. See the code with this fixes below:

background-image: url(". /images/image-product-desktop.jpg");

.img { 
     object-fit: cover; 
     background-color:$Dark_cyan; 
     background-image: url(". /images/image-product-desktop.jpg"); 
     background-repeat: no-repeat; 
     background-size: cover; 
     grid-column: 1; 
     grid-row: 1; 
     border-radius: 10px 0px 0px 10px; 
 }

Hope it helps you ninjadev, keep it up!

Marked as helpful

0
David 8,000

@DavidMorgade

Posted

Hello congrats on finishing the challenge!

I'm not 100% sure, but I think that your image isn't loading because you didn't specify the path correctly, since is in your CSS you need to define the route from your CSS file to the images folder, try with url("../../images/image-product-desktop.jpg") with this you will go up from the CSS folder, go up from the Public folder and finally access your images folder, I tried it on the browser with this path and the image loaded perfectly!.

As a last advice in this types of images I would directly go for an html img instead of using a CSS background-img.

Hope my answer helps you!

Marked as helpful

0

@MUKEBUDAVID

Posted

@DavidMorgade thanks for the comment, i'll try again and it works !!!!!!!!!!

1

@Talhakhan-Developer

Posted

Congrats for completing the challenge but as i go to your card it not develop for mobile and pic is not loading. but once again good try

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