Picture hover effect with pseudo-elements

Developer
Size
2,749 Kb
Views
30,360

How do I make an picture hover effect with pseudo-elements?

What is a picture hover effect with pseudo-elements? How do you make a picture hover effect with pseudo-elements? This script and codes were developed by Twikito on 11 September 2022, Sunday.

Picture hover effect with pseudo-elements Previews

Picture hover effect with pseudo-elements - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Picture hover effect with pseudo-elements</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <link rel="stylesheet" href="css/style.css">
</head>
<body> <a href="https://dribbble.com/Fran6" title="Francis on Dribbble">	<img src="https://d13yacurqjgara.cloudfront.net/users/635/screenshots/2008392/dribbble2_1x.jpg" alt="NYC">
</a>
</body>
</html>

Picture hover effect with pseudo-elements - Script Codes CSS Codes

a { position: relative; display: inline-block; margin: auto;
}
a::before, a::after { content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; z-index: -1; background: center no-repeat;
}
a::before { background-image: url(https://d13yacurqjgara.cloudfront.net/users/635/screenshots/1372944/wisibility_dribbble_1x.png); -webkit-transform: rotate(-1deg); transform: rotate(-1deg);
}
a::after { background-image: url(https://d13yacurqjgara.cloudfront.net/users/635/screenshots/1755027/silence_dribbble_1x.png); -webkit-transform: rotate(1.5deg); transform: rotate(1.5deg);
}
a img { display: block; padding: 1em; -webkit-transform: rotate(-3deg); transform: rotate(-3deg);
}
a::before, a::after, a img { background-color: white; box-shadow: 0 1px 5px rgba(0, 0, 0, 0.3); -webkit-transition: all .2s ease-out; transition: all .2s ease-out;
}
a:hover::before, a:hover::after, a:focus::before, a:focus::after { -webkit-filter: brightness(0.95); filter: brightness(0.95);
}
a:hover::before, a:focus::before { -webkit-transform: rotate(-5deg) translateX(-12em); transform: rotate(-5deg) translateX(-12em);
}
a:hover::after, a:focus::after { -webkit-transform: rotate(5deg) translateX(12em); transform: rotate(5deg) translateX(12em);
}
a:hover img, a:focus img { -webkit-filter: brightness(1.1); filter: brightness(1.1); box-shadow: 0 10px 10px rgba(0, 0, 0, 0.2); -webkit-transform: rotate(0) scale(1.1); transform: rotate(0) scale(1.1);
}
/* BLAH BLAH */
html, body { height: 100%;
}
body { background: url(http://subtlepatterns2015.subtlepatterns.netdna-cdn.com/patterns/noisy_grid.png) repeat; display: -webkit-box; display: -ms-flexbox; display: flex;
}
Picture hover effect with pseudo-elements - Script Codes
Picture hover effect with pseudo-elements - Script Codes
Home Page Home
Developer Twikito
Username Twikito
Uploaded September 11, 2022
Rating 3
Size 2,749 Kb
Views 30,360
Do you need developer help for Picture hover effect with pseudo-elements?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Twikito (Twikito) Script Codes
Create amazing marketing copy with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!