Expanding Photo Stack
How do I make an expanding photo stack?
Expanding photo stack made in pure CSS.. What is a expanding photo stack? How do you make a expanding photo stack? This script and codes were developed by Miro Karilahti on 07 July 2022, Thursday.
Expanding Photo Stack - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Expanding Photo Stack</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <h1><div>Expanding</div>Photo Stack</h1>
<div id="imgstack"> <a href="#"><img src="http://lorempixel.com/300/250/animals/1/" alt /></a> <a href="#"><img src="http://lorempixel.com/300/250/animals/2/" alt /></a> <a href="#"><img src="http://lorempixel.com/300/250/animals/3/" alt /></a>
</div> <script src="js/index.js"></script>
</body>
</html>
Expanding Photo Stack - Script Codes CSS Codes
/*Simple CSS-reset that removes margin and padding from every element*/
*{margin:0;padding:0;}
body{ background:#346; font-family:Arial,sans-serif; color:#f0f0f0;
}
h1{ margin-top:3%; font-size:320%; text-align:center;
}
h1 div{ font-size:60%; font-weight:700; text-align:center; line-height:24px; color:#c0c0c0;
}
/*The actual photo stack starts here*/
#imgstack{ width:300px; margin:0 auto; margin-top:2%;
}
#imgstack a{ width:288px; height:200px; position:absolute; display:block; border:6px solid #f0f0f0; border-radius:2px; box-shadow:0 0 10px rgba(0,0,0,.3); transition:margin .5s; -webkit-transition:margin .5s;
}
#imgstack img{ width:288px; max-height:100%;
}
#imgstack a:first-of-type{ margin-top:-5px; margin-left:-20px; z-index:2; transform:rotate(-3deg); -webkit-transform:rotate(-3deg);
}
#imgstack a:nth-of-type(2){ margin-top:-5px; margin-left:-10px; z-index:1;
}
#imgstack a:last-of-type{ transform:rotate(3deg); -webkit-transform:rotate(3deg);
}
#imgstack:hover a:first-of-type{ margin-left:-310px; margin-top:5px;
}
#imgstack:hover a:nth-of-type(2){margin-top:-5px;}
#imgstack:hover a:last-of-type{ margin-left:290px; margin-top:5px;
}
#imgstack a:first-of-type:hover,#imgstack a:last-of-type:hover{margin-top:-5px;}
#imgstack a:nth-of-type(2):hover{margin-top:-10px;}
Expanding Photo Stack - Script Codes JS Codes
/* No JavaScript! */
Developer | Miro Karilahti |
Username | miroot |
Uploaded | July 07, 2022 |
Rating | 4.5 |
Size | 2,083 Kb |
Views | 54,648 |
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!
Name | Size |
Simple personal profile | 2,856 Kb |
Long Shadow Calendar Icon | 1,856 Kb |
Flat sidebar | 2,664 Kb |
Color changing text | 2,068 Kb |
Background change in pure CSS | 3,236 Kb |
Single element Nexus 5 | 2,159 Kb |
Calendar | 2,033 Kb |
Navigation | 2,298 Kb |
Pure CSS Gallery | 3,817 Kb |
Button with sliding information | 2,387 Kb |
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!
Name | Username | Size |
A Pen by John Malc | F789gh | 1,420 Kb |
My Starter Kit For Codepen | Dkdesign | 2,012 Kb |
Subtle site navigation with description | Necks | 3,206 Kb |
Twinner Spinner II | Katydecorah | 2,974 Kb |
Portfolio Layout Flex | Lahvjal | 3,489 Kb |
Display properties | Hamzaerbay | 1,886 Kb |
Spin | Elalemanyo | 8,262 Kb |
Navier Stoke Fluid Simulation | Esimov | 8,584 Kb |
Jstam.com Home Page | Jstam | 10,558 Kb |
Hovers with popups | Zacharyolson | 2,380 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!