超火 3D 照片墙

index.html

<!--
 * @Author: coder-jason
 * @Date: 2022-04-20 11:38:07
 * @LastEditTime: 2022-04-20 12:27:05
-->
<!DOCTYPE html>
<html lang="en">

<head>
      <meta charset="UTF-8">
      <meta http-equiv="X-UA-Compatible" content="IE=edge">
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <title>超火🔥照片墙</title>
      <link rel="stylesheet" href="./style.css">
      <link rel="icon" type="image/png" href="https://coder-jason.cn/images/favicon-32x32.png">
</head>

<body>
      <div class="perspective">
            <div class="wrap" id="imgwrap">
                  <img src="./img/1.jpg" alt="demo">
                  <img src="./img/2.jpg" alt="demo">
                  <img src="./img/3.jpg" alt="demo">
                  <img src="./img/4.jpg" alt="demo">
                  <img src="./img/5.jpg" alt="demo">
                  <img src="./img/6.jpg" alt="demo">
                  <img src="./img/7.jpg" alt="demo">
                  <img src="./img/8.jpg" alt="demo">
                  <img src="./img/9.jpg" alt="demo">
                  <img src="./img/10.jpg" alt="demo">
                  <img src="./img/11.jpg" alt="demo">
                  <img src="./img/12.jpg" alt="demo">
                  <img src="./img/13.jpg" alt="demo">
                  <img src="./img/14.jpg" alt="demo">
                  <img src="./img/15.jpg" alt="demo">
                  <img src="./img/16.jpg" alt="demo">
                  <img src="./img/17.jpg" alt="demo">
                  <img src="./img/18.jpg" alt="demo">
                  <img src="./img/19.jpg" alt="demo">
                  <img src="./img/20.jpg" alt="demo">
            </div>
      </div>
      <script type="text/javascript" src="script.js"></script>
</body>

</html>

style.css

/* 
 * @Author: coder-jason
 * @Date: 2022-04-20 11:38:07
 * @LastEditTime: 2022-04-20 12:27:38
*/
* {
      margin: 0; 
      padding: 0;
}

body {
      background: #222;
      overflow: hidden;
      user-select: none;
      background-image: url(./img/bgi.png);
}

.perspective {
      perspective: 800px;
}

.wrap {
      width: 95px;
      height: 200px;
      margin: 100px auto;
      position: relative;
      transform: rotateX(-20deg) rotateY(0deg);
      transform-style: preserve-3d;
}

.wrap img {
      display: block;
      position: absolute;
      width: 100%;
      height: 100%;
      transform: rotateY(0deg) translateZ(0px);
      background: transparent;
      box-shadow: 0 0 4px #fff;
      border-radius: 5px;
}

.wrap p {
      width: 1200px;
      height: 1200px;
      background: -webkit-radial-gradient(center center, 600px 600px, rgba(122, 122, 122, .5), rgba(0, 0, 0, 0));
      position: absolute;
      border-radius: 50%;
      left: 50%;
      top: 100%;
      margin-left: -600px;
      margin-top: -600px;
      transform: rotateX(90deg);
}

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值