先来看看静态的效果图,动态效果更好
实例代码
复制代码代码如下:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>rollcat</title>
<style type="text/css">
*{
margin: 0;padding: 0;
}
body{
background: #333;font-family: "Helvetica Neue",Helvetica,"microsoft yahei",STHeiTi,sans-serif;
}
h1{
width: 100%;height: 80px;line-height: 80px;text-align: center;color: green;margin: 50px auto;font-size: 5em;font-weight: normal;
background-image: -webkit-linear-gradient(left, #167993, #fbe500 25%, #167993 50%, #fbe500 75%, #167993);
background-size: 200% 100%;
-webkit-text-fill-color: transparent;
-webkit-background-clip: text;
-webkit-animation: mask 4s infinite linear;
}
/******不太想做IE等浏览器的兼容的分割线******/
@-webkit-keyframes mask {
0% { background-position: 0 0;}
100% { background-position: -100% 0;}
}
p{
width: 100%;height: 80px;line-height: 80px;text-align: center;color: #999;margin: 50px auto;font-size: 2em;
background-image: -webkit-linear-gradient(left, #999, #999 5%,#fff 10%, #999 15%, #999);
background-size: 200%;
-webkit-text-fill-color: transparent;
-webkit-background-clip: text;
-webkit-animation: anim 3s infinite;
}
@-webkit-keyframes anim{
0%{
background-position: 0 0;
}
100%{
background-position: -100% 0;
}
}
</style>
</head>
<body></p>
<p><h1>风乍起,吹皱一池春水</h1></p>
<p><p>最是那一低头的温柔,恰似一朵海莲花不胜凉风的娇羞</p></p>
<p></body>
</html>
以上就是利用CSS实现文字高光水波渐变动态效果的全部内容,希望对大家的学习和工作能有所帮助。
css,动态,文字,高光,水波
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
更新日志
- 谢采妘.2016-邓丽君名曲专辑【丰荣】【WAV+CUE】
- 张含韵.2007-一人一梦【天中文化】【WAV+CUE】
- 蟑螂乐队.1999-帮个忙【福茂】【WAV+CUE】
- 张宇.2001-替身【EMI百代】【WAV+CUE】
- 班得瑞原装进口《第六张新世纪专辑:日光海岸》1CD[APE/CUE分轨][339.5MB]
- 班得瑞原装进口《第七张新世纪专辑:梦花园》1CD[APE/CUE分轨][331.4MB]
- 班得瑞原装进口《第八张新世纪专辑:琉璃湖畔》1CD[APE/CUE分轨][286.4MB]
- 魏如萱.2011-在哪里(EP)【添翼创越】【WAV+CUE】
- 群星.1981-新金曲奖·青年创作园地12合辑(喜玛拉雅复刻版)【歌林】【WAV+CUE】
- 麦洁文.1989-新曲与精丫新艺宝】【WAV+CUE】
- SNH48《薄荷糖 (Mint Candy)》[320K/MP3][33.72MB]
- SNH48《薄荷糖 (Mint Candy)》[FLAC/分轨][78.59MB]
- 刘美麟《同生》[320K/MP3][70.99MB]
- 群星.1994-宝丽金最流行3CD【宝丽金】【WAV+CUE】
- 群星.2024-聆听“某某”影视原声带【华纳】【FLAC分轨】