纯css实现文字闪烁动画效果
代码语言:html
所属分类:动画
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>BFW NEW PAGE</title> <style> @import url('https://fonts.googleapis.com/css?family=Fira+Mono:400'); body{ display: flex; width: 100vw; height: 100vh; align-items: center; justify-content: center; margin: 0; background: #131313; color: #fff; font-size: 96px; font-family: 'Fira Mono', monospace; letter-spacing: -7px; } div{ animation: glitch 1s linear infinite; } @keyframes glitch{ 2%,64%{ transform: translate(2px,0) skew(0deg); } 4%,60%{ transform: translate(-2px,0) skew(0deg); } 62%{ transform: translate(0,0) skew(5deg); } } div:before, div:after{ content: attr(title); position: absolute; left: 0; } div:before{ anima.........完整代码请登录后点击上方下载按钮下载查看
网友评论0