zoukankan      html  css  js  c++  java
  • CSS文字渐变

    <!DOCTYPE html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Document</title>
        <style type="text/css">
            html,body{
                padding: 0;
                margin: 0;
                width: 100%;
                height: 100%;
    
            }
            body{
                display: flex;
            
                align-items:center;
                justify-content:center;
                
            }
            .wrap{
                height: 250px;
                width: 40px;
                line-height: 40px;
                font-size: 30px;
                word-break: break-all;
                word-wrap: break-word;
                background-image: -webkit-linear-gradient(top,#FFFAF0,#FFEC8B 25%,#FFC125 50%,#FFA500 75%,#FF7F24);
                -webkit-text-fill-color:transparent;
                -webkit-background-clip: text;
                -webkit-background-size: 100% 200%;
                  -webkit-animation: text-change 2s infinite linear;
            }
            
            @-webkit-keyframes text-change {
                 0%{ background-position: 0 0;}
                 100% { background-position:0 -100%;}
            }
        </style>
    </head>
    <body>
        <div class="wrap a">文字渐变测试</div>
        <div class="wrap a b">文字渐变测试</div>
    </body>
    </html>
  • 相关阅读:
    如何知道电脑是几核?
    宝塔服务器管理助手Linux面版使用教程
    阿里云服务器怎么更换系统盘

    MoonScript
    webmin
    requests 0.7.6
    盘古搜索
    c练习总结
    Download a webpage using CURL in C
  • 原文地址:https://www.cnblogs.com/tylz/p/11304229.html
Copyright © 2011-2022 走看看