Skip to content

This is a solution to the [Product preview card component challenge on Frontend Mentor](https://www.frontendmentor.io/challenges/product-preview-card-component-GO7UmttRfa). Frontend Mentor challenges help you improve your coding skills by building realistic projects.

Notifications You must be signed in to change notification settings

LucasDeSousaR/product-preview-card-component-main

Repository files navigation

Frontend Mentor - Product preview card component solution

This is a solution to the Product preview card component challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.

Table of contents

Overview

The challenge

Users should be able to:

  • View the optimal layout depending on their device's screen size
  • See hover and focus states for interactive elements

Links

My process

Built with

  • Semantic HTML5 markup
  • CSS custom properties
  • Flexbox
  • CSS Grid

What I learned

Use this section to recap over some of your major learnings while working through this project. Writing these out and providing code samples of areas you want to highlight is a great way to reinforce your own knowledge.

To see how you can add code snippets, see below:

Below is the code I used to change the image according to the user's screen size.

<img srcset="images/image-product-desktop.jpg 600w, images/image-product-mobile.jpg 686w"
          sizes="(max-width: 600px) 686px, 300px" src="images/image-product-desktop.jpg"
          alt="Perfume Gabrielle Chanel Paris">

This CSS snippet was used to import external fonts into my web site.

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,700&family=Montserrat:wght@500;700&display=swap');

Worrying again about the responsiveness of the site, in the CSS file, I used @media to work with different configurations for screens of different proportions.

@media only screen and (max-width: 600px) {}

Author

About

This is a solution to the [Product preview card component challenge on Frontend Mentor](https://www.frontendmentor.io/challenges/product-preview-card-component-GO7UmttRfa). Frontend Mentor challenges help you improve your coding skills by building realistic projects.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published