网页特效栏目收集了最全最新的前端网页插件,包括最流行的jQuery,Bootstrap,Js,Css,Vue等主流特效插件。
纯css3D照片墙特效,当鼠标悬停在图片上时,有一个3D翻转的特效,非常炫酷。
3D照片墙css样式代码
* {
margin:0; padding:0;
box-sizing:border-box;
}
html, body {
background:#E2E2E2;
overflow:hidden;
height:100%;
}
#main-wrapper {
display: flex;
justify-content: center;
align-items: center;
height: 100%;
}
#list {
display: flex;
justify-content: center;
align-items: center;
position: relative;
width: 740px;
flex-wrap: wrap;
transform:rotateX(54deg) rotateY(0deg) rotateZ(-37deg);
transform-style: preserve-3d;
}
.photo {
width: 300px;
position: relative;
margin: 2em;
}
.photo div {
transform-style: preserve-3d;
transition:all .6s linear;
}
.photo:hover div{
transform: translateZ(2em) rotateX(170deg);
transform-origin: center center;
z-index: 1;
}
.photo img {
width: 100%;
display: block;
position: relative;
z-index: 1;
backface-visibility: hidden;
}
.photo .card {
position: absolute;
top: 0;
background: #1C0F13;
width: 100%;
height: 100%;
display: flex;
padding: 1.4em 2em;
color: #FFF;
justify-content: flex-end;
font-size: 14px;
transform: rotateX(180deg);
flex-direction: column;
font-family:"Open Sans", Roboto, sans-serif;
}
.author {
font-size: 19px;
font-weight: 800;
text-transform: uppercase;
}
转载请注明来源:CSS3D照片墙 图片库特效
本文永久链接地址:https://www.moyouyouw.cn/code/935.html
郑重声明:本站所有主题/文章除标明原创外,均来自网络转载,版权归原作者所有,如果有侵犯到您的权益,请联系本站删除,谢谢!我们不承担任何技术及版权问题,且不对任何资源负法律责任。
上一篇
下一篇
已有 位小伙伴发表了看法
欢迎 你 发表评论