新年快乐文字描边动画效果
代码语言:html
所属分类:动画
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<html lang="en"> <head> <meta charset="UTF-8"> <style> @keyframes stroke { 10% { stroke-dashoffset: 600; } 70% { stroke-dashoffset: 0; fill: #FFF; } 80% { stroke-dashoffset: 0; fill: #092951; } 100% { stroke-dashoffset: 0; fill: #092951; } } @-webkit-keyframes stroke { 10% { stroke-dashoffset: 600; } 70% { stroke-dashoffset: 0; fill: #FFF; } 80% { stroke-dashoffset: 0; fill: #092951; } 100% { stroke-dashoffset: 0; fill: #092951; } } * { margin: 0; padding: 0; border: none; } body, html { width: 100%; min-width: 500px; height: 100%; min-height: 400px; overflow: hidden; } #wrap { width: 500px; height: 400px; position: absolute; top: 50%; left: 50%; margin: -200px 0 0 -250px; } #wrap path { stroke: #092951; fill: #FFF; stroke-width: 1; stroke-dasharray: 600; stroke-dashoffset: 600; animation: stroke 6s linear infinite.........完整代码请登录后点击上方下载按钮下载查看
网友评论0