Skip to content

PavlinaPs/NFT-preview-card-component

Repository files navigation

Frontend Mentor - NFT preview card component solution

This is a solution to the NFT 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 states for interactive elements

Screenshot

Desktop layout
Desktop layout
Desktop layout hover
Desktop layout
Mobile layout
Mobile layout

Links

My process

Built with

  • Semantic HTML5 markup
  • CSS custom properties
  • Flexbox
  • Mobile-first workflow

What I learned

Fist I tried to solve the image hover state by using z-index, but it didn't work out due to unexpected behaviour, at least for me as of now - some weird flashing occured.

Then I learned the hard way that there is a big difference in setting opacity:

.div {
  opacity: 0.5;
}

and

.div {
  background-color: hsl(178, 100%, 50%, 0.45);
}

I find this challenge very useful for me.

Continued development

I need to practice a lot to get faster.

Useful resources

When deciding how to make the horizontal line - with <hr> element or a <div> I checked out these two pages:

Author

Acknowledgments

It is great that I can solve Frontend Mentor's challenges. They are all very useful for me. Thank you!

Releases

No releases published

Packages

No packages published