84669 人學習
152542 人學習
20005 人學習
5487 人學習
7821 人學習
359900 人學習
3350 人學習
180660 人學習
48569 人學習
18603 人學習
40936 人學習
1549 人學習
1183 人學習
32909 人學習
#網址 http://zm.163.com/
這個效果怎麼實現的
就是一個簡單CSS3 動畫
.light_pc { width: 93px; height: 9px; position: absolute; top: 0; left: 50%; margin-left: -46px; background: url(https://zm.res.netease.com/pc/fab/20161226201931/img/light_pc_f3d5dee.png?_sprite) no-repeat; -moz-animation: light_pc 4s linear 0s infinite; -webkit-animation: light_pc 4s linear 0s infinite; -o-animation: light_pc 4s linear 0s infinite; -ms-animation: light_pc 4s linear 0s infinite; animation: light_pc 4s linear 0s infinite } @-webkit-keyframes light_pc { 0% { top: 0 } 50% { top: 83px } 100% { top: 0 } } @-moz-keyframes light_pc { 0% { top: 0 } 50% { top: 83px } 100% { top: 0 } } @-ms-keyframes light_pc { 0% { top: 0 } 50% { top: 83px } 100% { top: 0 } } @-o-keyframes light_pc { 0% { top: 0 } 50% { top: 83px } 100% { top: 0 } } @keyframes light_pc { 0% { top: 0 } 50% { top: 83px } 100% { top: 0 } }
查看元素,具體了解下css的animation
二維碼圖片外面有一個p和圖片高度大小一致用:before做出一條橫線寫css3動畫移動
我也曬一下我的動畫
demo { transform: translate3d(0, 0, 0); animation: bounce 0.8s infinite ease-out; } @-webkit-keyframes bounce { 50% { transform: translate3d(0, -0.2rem, 0); } }
就是一個簡單CSS3 動畫
查看元素,具體了解下css的animation
二維碼圖片外面有一個p和圖片高度大小一致
用:before
做出一條橫線
寫css3動畫移動
我也曬一下我的動畫