css彩色加载进度条

css彩色加载进度条

HTML代码

code

  1. <div class=”progress”>
  2.   <span class=”progress-bar” style=”width: 75%”></span>
  3. </div>

CSS代码

code

  1. * {
  2.   box-sizing: border-box;
  3. }
  4. body {
  5.   min-height: 100vh;
  6.   display: -webkit-box;
  7.   display: flex;
  8.   -webkit-box-pack: center;
  9.           justify-content: center;
  10.   -webkit-box-align: center;
  11.           align-items: center;
  12.   background: #191919;
  13. }
  14. .progress {
  15.   width: 100%;
  16.   max-width: 260px;
  17.   height: 6px;
  18.   background: #e1e4e8;
  19.   border-radius: 3px;
  20.   overflow: hidden;
  21. }
  22. .progress .progress-bar {
  23.   display: block;
  24.   height: 100%;
  25.   background: -webkit-gradient(linear, left top, right top, from(#ffd33d), color-stop(17%, #ea4aaa), color-stop(34%, #b34bff), color-stop(51%, #01feff), color-stop(68%, #ffd33d), color-stop(85%, #ea4aaa), to(#b34bff));
  26.   background: linear-gradient(90deg, #ffd33d, #ea4aaa 17%, #b34bff 34%, #01feff 51%, #ffd33d 68%, #ea4aaa 85%, #b34bff);
  27.   background-size: 300% 100%;
  28.   -webkit-animation: progress-animation 2s linear infinite;
  29.           animation: progress-animation 2s linear infinite;
  30. }
  31. @-webkit-keyframes progress-animation {
  32.   0% {
  33.     background-position: 100%;
  34.   }
  35.   100% {
  36.     background-position: 0;
  37.   }
  38. }
  39. @keyframes progress-animation {
  40.   0% {
  41.     background-position: 100%;
  42.   }
  43.   100% {
  44.     background-position: 0;
  45.   }
  46. }
1. 本站所有资源来源于用户上传和网络,如有侵权请邮件联系站长!270968671@qq.com
2. 您必须在下载后的24个小时之内,从您的电脑中彻底删除上述内容资源!
3. 如果你也有好源码或者教程,可以到审核区发布,分享有金币奖励和额外收入!
4. 本站提供的源码、模板、插件等等其他资源,都不包含技术服务请大家谅解!
5. 如有链接无法下载、失效或广告,请联系管理员处理!
6. 本站资源售价只是赞助,收取费用仅维持本站的日常运营所需!
7. 本站不保证所提供下载的资源的准确性、安全性和完整性,源码仅供下载学习之用!
8. 如用于商业或者非法用途,与本站无关,一切后果请用户自负!

启辰源码 - 一站式源码与模板下载平台 » css彩色加载进度条

提供最优质的资源集合

立即查看 了解详情