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

A product preview card made using CSS and HTML

@mouhibeddine

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


-so i have a problem with the font-weight , it doesn't change anything when i change the value

  • how can i create the cart icon -i don't why the pictures in my code don't appear when i create the website link i will appreciate any notes

Community feedback

Lucas ๐Ÿ‘พโ€ข 104,420

@correlucas

Posted

๐Ÿ‘พHello Mouhibeddine, congratulations for your solution!

Answering your question:

1.Your images are not displaying due the fact you didn't add the dot . before the folder, when you use your repository as local, your computer recognize the folders, but the same thing doesn't happen in the live site.

So make sure you indicate correctly the location of your assets see how it should be written bellow:

.p-img { background: url(./imgpro.jpg); }

Note: ./imgpro.jpg

Use one dot for one folder ./ and two dots if is a sub folder ../

2.About your font sizes I didnt a inspection with dev tools and the fonts are changing, pay attention that the fonts are being managed using id not class so this is some you might know. Use id as a specific selector for forms and class for styling.

Here's the id you've used for the h1, for example:\

#title {
    font-family: 'Fraunces';
    font-size: 40px;
    margin-top: 30px;
    line-height: 37px;
    color: hsl(212, 21%, 14%);
}```

Hope it helps, happy coding!

Marked as helpful

3

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