Skip to content

bccpadge/nft-preview-card-component

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

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

nft preview card component

Links

My process

Built with

  • Semantic HTML5 markup
  • CSS custom properties (variables)
  • Flexbox
  • CSS Grid
  • Mobile-first workflow

What I learned

I learned how to use the after pseudo-element to add the icon view image in CSS only.

.nft-banner::after {
  --accent-clr-alt: hsla(178, 100%, 50%, 0.5);
  content: url("../images/icon-view.svg");
  position: absolute;
  inset: 0;
  background-color: var(--accent-clr-alt);
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity var(--transition);
}

Useful resources

Author

Acknowledgments

I used this Youtube nft preview card component video tutorial.

About

Frontend Mentor - NFT preview card component using HTML and CSS

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published