css 文字光影特效

css 复制代码
 <style>
      .text-area{
          text-align: center;
      }
      span{
          font-weight: bold;
          font-size:70px;
          color:#faebd7;
          animation:shadowing 1s ease-in-out infinite alternate;
      }
      span:nth-child(n+2){
          animation-delay: 0.2s;
      }
      span:nth-child(n+3){
          animation-delay: 0.4s;
      }
      span:nth-child(n+4){
          animation-delay: 0.4s;
      }
      span:nth-child(n+5){
          animation-delay: 0.5s;
      }
      span:nth-child(n+6){
          animation-delay: 0.6s;
      }
      span:nth-child(n+7){
          animation-delay: 0.7s;
      }
      span:nth-child(n+8){
          animation-delay: 0.8s;
      }
      span:nth-child(n+9){
          animation-delay: 0.9s;
      }
      @keyframes shadowing {
          to{
              color:#ff020f;
              text-shadow: 20px 0 70px #ff020f;
          }

      }
  </style>
html 复制代码
<div class="text-area">
      <span>加</span>
      <span>加</span>
      <span>加</span>
      <span>加</span>
      <span>油</span>
      <span>未</span>
      <span>来</span>
      <span>可</span>
      <span>期</span>
 </div>
相关推荐
笔尖的记忆4 分钟前
【前端架构和框架】react组件化&数据流
前端·面试
zhangzelin88813 分钟前
TypeScript入门指南:JavaScript的类型化超集
前端·javascript·其他·typescript
lichenyang45321 分钟前
流式聊天界面实现解析:从零到一构建实时对话体验
前端
天蓝色的鱼鱼21 分钟前
Turbopack vs Webpack vs Vite:前端构建工具三分天下,谁将胜出?
前端·webpack
软件技术NINI31 分钟前
html css js网页制作成品——化妆品html+css+js (7页)附源码
javascript·css·html
用户8417948145632 分钟前
vxe-table 实现列头授权自定义插槽模板,自定义输入框
前端
im_AMBER37 分钟前
Web 开发 24
前端·笔记·git·学习
小小前端_我自坚强39 分钟前
前端算法相关详解
前端·算法
小小前端_我自坚强1 小时前
UniApp 微信小程序流水线发布全流程
前端·架构
小小前端_我自坚强1 小时前
vue提高技术 高级语法相关
前端·vue.js·前端框架