A Pen by JowayYoung on CodePen.
Created
November 3, 2019 12:16
-
-
Save mqxu/eafb4e02ad5601a50acf118aa403f9c7 to your computer and use it in GitHub Desktop.
【iCSS:色彩】使用linear-gradient控制文本渐变
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="bruce flex-ct-x"> | |
<h1 class="gradient-text">Full Stack Developer</h1> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.gradient-text { | |
background-image: linear-gradient(90deg, #f66, #f90); | |
background-clip: text; | |
line-height: 60px; | |
font-size: 60px; | |
animation: hue 5s linear infinite; | |
-webkit-text-fill-color: transparent; | |
} | |
@keyframes hue { | |
from { | |
filter: hue-rotate(0); | |
} | |
to { | |
filter: hue-rotate(-1turn); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link href="https://yangzw.vip/static/css/reset.css" rel="stylesheet" /> | |
<link href="https://yangzw.vip/static/css/main.css" rel="stylesheet" /> | |
<link href="https://yangzw.vip/static/css/theme.scss" rel="stylesheet" /> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment