首页 > 其他分享 >简单的Css动画---攀爬效果

简单的Css动画---攀爬效果

时间:2022-09-04 21:14:54浏览次数:60  
标签:box rgba 攀爬 --- 5px 15px 20px Css 255

<!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>攀爬效果2</title>     <style>         *{             margin: 0;             padding: 0;             box-sizing: border-box;         }         body{             display: flex;             justify-content: center;             align-items: center;             background: #edf1f4;             min-height: 100vh;         }         .loader{             display: flex;             flex-direction: row;
        }         .loader div{             position: relative;             width: 40px;             height: 200px;             margin: 20px;             overflow: hidden;             border-radius: 40px;             background: linear-gradient(to bottom,  rgba(0,0,0,0.05),#edf1f4);             border: 2px solid #edf1f4;             box-shadow: 15px 15px 20px rgba(0, 0, 0, 0.1),             -15px -15px 20px#fff,             inset -5px -5px 5px rgba(255,255,255,0.5),             inset 5px 5px 5px rgba(0, 0, 0.05);
        }         .loader div::before{             content: '';             position: absolute;             top: 0;             left: 0;             width: 100%;             height: 100%;             z-index: 10;             border-radius: 40px;             box-shadow: 15px 15px 20px rgba(0, 0, 0, 0.1),                         -15px -15px 20px#fff,                         inset -5px -5px 5px rgba(255,255,255,0.5),                         inset 5px 5px 5px rgba(0, 0, 0.05);         }         .loader div::after{             content: '';             position: absolute;             top: 0;             left: 0;             width: 36px;             height: 36px;             background: #fff;             border-radius: 50%;             box-shadow: inset -5px -5px 5px rgba(0, 0, 0, 0.2),                         0 420px 0 400px #2196f3;             animation: animate 2.5s ease-in-out infinite;             transform: translateY(160px);             animation-delay: calc(-0.5s * var(--i));         }         @keyframes  animate{             0%{                 transform: translateY(160px);                 filter: hue-rotate(180deg);             }             50%{                 transform: translateY(0px);             }             100%{                 transform: translateY(160px);                 filter: hue-rotate(0deg);             }         }     </style> </head> <body>     <div class="loader">         <div style="--i:0"></div>         <div style="--i:1"></div>         <div style="--i:2"></div>         <div style="--i:3"></div>         <div style="--i:4"></div>     </div> </body> </html> 结果:

 

 

标签:box,rgba,攀爬,---,5px,15px,20px,Css,255
From: https://www.cnblogs.com/wangshileiwu/p/16656082.html

相关文章

  • Docker-Compose常用命令
    Docker-Compose常用命令docker-composeup1.用于部署一个Compose应用。2.默认情况下该命令会读取名为docker-compose.yml或docker-compose.yaml的文件。3.当......
  • 前端学习之------浏览器兼容(移动端)
    1、禁止IOS识别长串数字为电话<metacontent="telephone=no"name="format-detection">2、禁止IOS弹出各种操作窗口.box{ -webkit-touch-callout:none;}3、禁......
  • 算法--链表
       方法一:构造链表如果此类型的题出现在笔试中,如果内存要求不高,可以采用如下方法:可以先用一个vector将单链表的指针都存起来,然后再构造链表。此方法简单易懂,代码好......
  • 2022-2023-1 20221408《计算机基础与程序设计》第一周学习总结
    班级:https://edu.cnblogs.com/campus/besti/2022-2023-1-CFAP作业链接:https://www.cnblogs.com/zhanquanchen/p/16654783.html作业目标:快速浏览教材作业正文:https://www.cn......
  • Typescript类型体操 - Tuple To Union
    题目中文实现泛型TupleToUnion<T>,它返回元组所有值的合集。例如typeArr=['1','2','3']typeTest=TupleToUnion<Arr>//expectedtobe'1'|'2'|'3'Eng......
  • Flask 学习-45.Flask-RESTX 自定义参数校验和自定义错误内容 error_msg 使用
    前言在校验请求参数的时候,除了一些基本的required=True,type类型外,还会遇到一些校验,比如是否为空,字符串长度,以及一些自定义的参数规则。add_argument参数classArgumen......
  • python-------assign的使用方法
    https://blog.csdn.net/qq_42240729/article/details/105628595?ops_request_misc=&request_id=&biz_id=102&utm_term=python%20assign&utm_medium=distribute.pc_search_r......
  • 请求参数中文乱码-解决方式
    POST:    调用setCharacterEncoding()这样就解决POST乱码问题 GET:  优化:   ......
  • CSS常用属性
    ​ /**作者:呆萌老师*☑csdn认证讲师*☑51cto高级讲师*☑腾讯课堂认证讲师*☑网易云课堂认证讲师*☑华为开发者学堂认证讲师*☑爱奇艺千人名师计划成员*在这里......
  • Flask 学习-44.Flask-RESTX 请求参数校验reqparse.RequestParser()
    前言Flask-RESTX的整个请求解析器部分将被删除,并将被有关如何与其他可以更好地执行输入/输出内容的包(例如marshmallow)集成的文档所取代。这意味着它将保持到2.0,但认为......