十六种炫酷纯css加载动画(一)

2023-10-27

一个好的开篇,会给你这个项目增加不少分值。

有没有遇到过打开页面加载一段时间,页面内容才加载出来。在等待加载的过程中页面却是空白页,给用户的体验特别不好,会让项目降一个档次。下面的十六种炫酷炸裂的css加载动画,会让你在等待的过程中,体验视觉盛宴,给用户不一般的加载体验,对,就是纯css3的炫酷加载动画,请看效果!

码字不易,且行且珍惜。

加载1

在这里插入图片描述

css源码

.title{
    width: 100%;
    text-align: center;
    margin:60px 0;
    font-size: 18px;
    color: #999;
}
.loadingOne{
    width: 80px;
    height: 40px;
    margin: 0 auto;
}
.loadingOne span{
    display: inline-block;
    width: 8px;
    height: 100%;
    border-radius: 4px;
    background: lightgreen;
    -webkit-animation: load 1s ease infinite;
    animation: load 1s ease infinite;
}
@-webkit-keyframes load{
    0%,100%{
        height: 40px;
        background: lightgreen;
    }
    50%{
        height: 70px;
        margin: -15px 0;
        background: lightblue;
    }
}
.loadingOne span:nth-child(2){
    -webkit-animation-delay:0.2s;
    animation-delay:0.2s;
}
.loadingOne span:nth-child(3){
    -webkit-animation-delay:0.4s;
    animation-delay:0.4s;
}
.loadingOne span:nth-child(4){
    -webkit-animation-delay:0.6s;
    animation-delay:0.6s;
}
.loadingOne span:nth-child(5){
    -webkit-animation-delay:0.8s;
    animation-delay:0.8s;
}

html源码

<div class="loadingOne">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载2

在这里插入图片描述

css源码

.loadingTwo{
    width: 150px;
    height: 4px;
    border-radius: 2px;
    margin: 0 auto;
    margin-top:100px;
    position: relative;
    background: lightgreen;
    -webkit-animation: changeBgColor 1.04s ease-in infinite alternate;
    animation: changeBgColor 1.04s ease-in infinite alternate;
}
.loadingTwo span{
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: lightgreen;
    position: absolute;
    margin-top: -7px;
    margin-left:-8px;
    -webkit-animation: changePosition 1.04s ease-in infinite alternate;
    animation: changePosition 1.04s ease-in infinite alternate;
}
@-webkit-keyframes changeBgColor{
    0%{
        background: lightgreen;
    }
    100%{
        background: lightblue;
    }
}
@-webkit-keyframes changePosition{
    0%{
        background: lightgreen;
    }
    100%{
        margin-left: 142px;
        background: lightblue;
    }
}

html源码

<div class="loadingTwo">
    <span></span>
</div>

加载3

在这里插入图片描述

css源码

.loadingThree{
    width: 150px;
    height: 15px;
    margin: 0 auto;
    margin-top:100px;
}
.loadingThree span{
    display: inline-block;
    width: 15px;
    height: 100%;
    margin-right: 5px;
    border-radius: 50%;
    background: lightgreen;
    -webkit-animation: load 1.04s ease infinite;
}
.loadingThree span:last-child{
    margin-right: 0px;
}
@-webkit-keyframes load{
    0%{
        opacity: 1;
    }
    100%{
        opacity: 0;
    }
}
.loadingThree span:nth-child(1){
    -webkit-animation-delay:0.13s;
}
.loadingThree span:nth-child(2){
    -webkit-animation-delay:0.26s;
}
.loadingThree span:nth-child(3){
    -webkit-animation-delay:0.39s;
}
.loadingThree span:nth-child(4){
    -webkit-animation-delay:0.52s;
}
.loadingThree span:nth-child(5){
    -webkit-animation-delay:0.65s;
}

html源码

<div class="loadingThree">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载4

在这里插入图片描述

css源码

.loadingFour{
		width: 150px;
		height: 15px;
		margin: 0 auto;
		margin-top:100px;
		text-align: center;
	}
	.loadingFour span{
		display: inline-block;
		width: 15px;
		height: 100%;
		margin-right: 5px;
		background: lightgreen;
		-webkit-animation: load 1.04s ease infinite;
	}
	.loadingFour span:last-child{
		margin-right: 0px;
	}
	@-webkit-keyframes load{
		0%{
			opacity: 1;
		}
		100%{
			opacity: 0;
		}
	}
	.loadingFour span:nth-child(1){
		-webkit-animation-delay:0.13s;
	}
	.loadingFour span:nth-child(2){
		-webkit-animation-delay:0.26s;
	}
	.loadingFour span:nth-child(3){
		-webkit-animation-delay:0.39s;
	}
	.loadingFour span:nth-child(4){
		-webkit-animation-delay:0.52s;
	}
	.loadingFour span:nth-child(5){
		-webkit-animation-delay:0.65s;
	}.loadingTwo{
    width: 150px;
    height: 4px;
    border-radius: 2px;
    margin: 0 auto;
    margin-top:100px;
    position: relative;
    background: lightgreen;
    -webkit-animation: changeBgColor 1.04s ease-in infinite alternate;
    animation: changeBgColor 1.04s ease-in infinite alternate;
}
.loadingTwo span{
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: lightgreen;
    position: absolute;
    margin-top: -7px;
    margin-left:-8px;
    -webkit-animation: changePosition 1.04s ease-in infinite alternate;
    animation: changePosition 1.04s ease-in infinite alternate;
}
@-webkit-keyframes changeBgColor{
    0%{
        background: lightgreen;
    }
    100%{
        background: lightblue;
    }
}
@-webkit-keyframes changePosition{
    0%{
        background: lightgreen;
    }
    100%{
        margin-left: 142px;
        background: lightblue;
    }
}

html源码

<div class="loadingFour">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载5

在这里插入图片描述

css源码

.loadingFive{
    width: 150px;
    height: 15px;
    margin: 0 auto;
    margin-top:100px;
}
.loadingFive span{
    display: inline-block;
    width: 15px;
    height: 100%;
    margin-right: 5px;
    background: lightgreen;
    -webkit-transform-origin: right bottom;
    -webkit-animation: load 1s ease infinite;
}
.loadingFive span:last-child{
    margin-right: 0px;
}
@-webkit-keyframes load{
    0%{
        opacity: 1;
    }
    100%{
        opacity: 0;
        -webkit-transform: rotate(90deg);
    }
}
.loadingFive span:nth-child(1){
    -webkit-animation-delay:0.13s;
}
.loadingFive span:nth-child(2){
    -webkit-animation-delay:0.26s;
}
.loadingFive span:nth-child(3){
    -webkit-animation-delay:0.39s;
}
.loadingFive span:nth-child(4){
    -webkit-animation-delay:0.52s;
}
.loadingFive span:nth-child(5){
    -webkit-animation-delay:0.65s;
}.loadingTwo{
    width: 150px;
    height: 4px;
    border-radius: 2px;
    margin: 0 auto;
    margin-top:100px;
    position: relative;
    background: lightgreen;
    -webkit-animation: changeBgColor 1.04s ease-in infinite alternate;
    animation: changeBgColor 1.04s ease-in infinite alternate;
}
.loadingTwo span{
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: lightgreen;
    position: absolute;
    margin-top: -7px;
    margin-left:-8px;
    -webkit-animation: changePosition 1.04s ease-in infinite alternate;
    animation: changePosition 1.04s ease-in infinite alternate;
}
@-webkit-keyframes changeBgColor{
    0%{
        background: lightgreen;
    }
    100%{
        background: lightblue;
    }
}
@-webkit-keyframes changePosition{
    0%{
        background: lightgreen;
    }
    100%{
        margin-left: 142px;
        background: lightblue;
    }
}.loadingFive{
    width: 150px;
    height: 15px;
    margin: 0 auto;
    margin-top:100px;
}
.loadingFive span{
    display: inline-block;
    width: 15px;
    height: 100%;
    margin-right: 5px;
    background: lightgreen;
    -webkit-transform-origin: right bottom;
    -webkit-animation: load 1s ease infinite;
}
.loadingFive span:last-child{
    margin-right: 0px;
}
@-webkit-keyframes load{
    0%{
        opacity: 1;
    }
    100%{
        opacity: 0;
        -webkit-transform: rotate(90deg);
    }
}
.loadingFive span:nth-child(1){
    -webkit-animation-delay:0.13s;
}
.loadingFive span:nth-child(2){
    -webkit-animation-delay:0.26s;
}
.loadingFive span:nth-child(3){
    -webkit-animation-delay:0.39s;
}
.loadingFive span:nth-child(4){
    -webkit-animation-delay:0.52s;
}
.loadingFive span:nth-child(5){
    -webkit-animation-delay:0.65s;
}

html源码

<div class="loadingFive">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载6

在这里插入图片描述

css源码

.loadingSix{
    width: 100px;
    height: 100px;
    position: relative;
    margin: 0 auto;
    margin-top:100px;
}
.loadingSix span{
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: lightgreen;
    position: absolute;
    -webkit-animation: load 1.04s ease infinite;
}
@-webkit-keyframes load{
    0%{
        opacity: 1;
    }
    100%{
        opacity: 0.2;
    }
}
.loadingSix span:nth-child(1){
    left: 0;
    top: 50%;
    margin-top:-8px;
    -webkit-animation-delay:0.13s;
}
.loadingSix span:nth-child(2){
    left: 14px;
    top: 14px;
    -webkit-animation-delay:0.26s;
}
.loadingSix span:nth-child(3){
    left: 50%;
    top: 0;
    margin-left: -8px;
    -webkit-animation-delay:0.39s;
}
.loadingSix span:nth-child(4){
    top: 14px;
    right:14px;
    -webkit-animation-delay:0.52s;
}
.loadingSix span:nth-child(5){
    right: 0;
    top: 50%;
    margin-top:-8px;
    -webkit-animation-delay:0.65s;
}
.loadingSix span:nth-child(6){
    right: 14px;
    bottom:14px;
    -webkit-animation-delay:0.78s;
}
.loadingSix span:nth-child(7){
    bottom: 0;
    left: 50%;
    margin-left: -8px;
    -webkit-animation-delay:0.91s;
}
.loadingSix span:nth-child(8){
    bottom: 14px;
    left: 14px;
    -webkit-animation-delay:1.04s;
}

html源码

<div class="loadingSix">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载7

在这里插入图片描述

css源码

.loadingSeven{
    width: 80px;
    height: 40px;
    margin: 0 auto;
    margin-top:100px;
}
.loadingSeven span{
    display: inline-block;
    width: 8px;
    height: 100%;
    border-radius: 4px;
    background: lightgreen;
    -webkit-animation: loadsaven 1.04s ease infinite;
}
@-webkit-keyframes loadsaven{
    0%,100%{
        height: 40px;
        background: lightgreen;
    }
    50%{
        height: 60px;
        margin-top: -20px;
        background: lightblue;
    }
}
.loadingSeven span:nth-child(2){
    -webkit-animation-delay:0.13s;
}
.loadingSeven span:nth-child(3){
    -webkit-animation-delay:0.26s;
}
.loadingSeven span:nth-child(4){
    -webkit-animation-delay:0.39s;
}
.loadingSeven span:nth-child(5){
    -webkit-animation-delay:0.52s;
}

html源码

<div class="loadingSeven">
    <span></span>
    <span></span>
    <span></span>
    <span></span>
    <span></span>
</div>

加载8

在这里插入图片描述

css源码

.loadingEight{
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto;
    margin-top:100px;
    position: relative;
    border:5px solid lightgreen;
    -webkit-animation: turn 2s linear infinite;
}
.loadingEight span{
    display: inline-block;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: lightgreen;
    position: absolute;
    left: 50%;
    margin-top: -15px;
    margin-left: -15px;
    -webkit-animation: changeBgColor 2s linear infinite;
}
@-webkit-keyframes changeBgColor{
    0%{
        background: lightgreen;
    }
    100%{
        background: lightblue;
    }
}
@-webkit-keyframes turn{
    0%{
        -webkit-transform: rotate(0deg);
        border-color: lightgreen;
    }
    100%{
        -webkit-transform: rotate(360deg);
        border-color: lightblue;
    }
}

html源码

<div class="loadingEight">
    <span></span>
</div>

搬你想搬,盖你所需,码字不易,且行且珍惜!

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

十六种炫酷纯css加载动画(一) 的相关文章

  • 程序员必读书目推荐

    1 Effective Java Joschua 稍许过时 但没有替代java方面的书 2 Effectvie C Scott Meyer 3 More Effective C Scott Meyer的书是非常非常好书 每次读都感到汗颜 自

随机推荐

  • Vue 动态锚点

    这是封装的组件 判断容器的滚动 接收父组件传来的Tab参数
  • Qt Quick里的图形效果——混合(Blend)

    Blend 元素用指定的模式混合两个 Item 在我们使用 QPainter 绘图时 支持 Composition Modes Blend 干的事儿与此类似 使用 Blend 需要 import QtGraphicalEffects 1 0
  • IDEA导入MySQL的jdbc驱动出现“java.lang.ClassNotFoundException: com.mysql.cj.jdbc.Driver”

    目录 一 一般的解决思路 1 JDBC下载链接 2 选择下载内容 并进行下载 3 将驱动导入java项目 二 依然导入驱动失败怎么办 当我们在idea中使用java操作mysql数据库时会出现 Exception in thread mai
  • 自动驾驶多边形iou计算Shapely库笔记

    参考 https cloud tencent com developer ask 42755 https blog csdn net u014421797 article details 89501572 https www itransl
  • MMDetection= Cuda10.0.130 + Pytorch1.4.0 + torchvision0.5.0 + mmcv-full1.1.6 + mmdet2.5.0

    1 版本选取 MMDetection的版本选择 安装的时候 需要选择合适的版本 下载不同版本的MMDetection 从 Github 的历史版本中选择合适的版本 https github com open mmlab mmdetectio
  • Python之线程编程(Thread)

    线程基本概念 1 什么是线程 1 线程被称为轻量级的进程 2 线程也可以使用计算机多核资源 是多任务编程方式 3 线程是系统分配内核的最小单元 4 线程可以理解为进程的分支任务 2 线程特征 1 一个进程中可以包含多个线程 2 线程也是一个
  • Untiy UDP局域网 异步发送图片

    同步画面有问题 传图片吧 using System Text using System Net Sockets using System Collections using System Collections Generic using
  • WSL2 Ubuntu中apt update命令报错,无法解析域名解决方法

    参考链接 参考链接 1 sudo apt get update失败 在ubuntu16中 当我们输入sudo apt get update会失败 这里有很多原因 1 网络原因 先检查网络好不好用 2 ubuntu16 自带的源不好用 或者有
  • 大数据技术学习代码记录——Scala

    文章目录 一 Scala 二 Day01代码记录 2 1 HelloWord scala 2 1 1 TestHelloWorld scala 2 2 ifelse scala 2 3 PrintStudentInfo scala 三 Da
  • LayUI中的内置模块之 常用元素操作 - layui.element

    前言 最近在准备找工作的事项 但是作为一个后台也是需要了解一些前端框架的 就目前的来说有大火的VUE 但是VUE还是存在一定的学习成本 所以决定先从对后台友好的LayUI开始入手先做一些小项目练练手 后面会考虑使用VUE ElementUI
  • 字符串压缩(小知识点)

    当对字符串进行修改的时候 需要使用 StringBuffer 和 StringBuilder 类 和 String 类不同的是 StringBuffer 和 StringBuilder 类 的对象能够被多次的修改 并且不产生新的未使用对象
  • Maven 项目的配置与程序的运行

    Maven 是一个 Java 包管理工具 需要下载和安装 通过配置 Maven 以后建立项目时就不需要再创建 lib 目录并导入相关的包 只需要在它的配置文件 pom xml 文件中进行包的配置 这样的配置方法提供了便利 大大节约了资源 在
  • Zookeeper入门

    Zookeeper概念 Zookeeper是一个开源的 分布式的项目 是apache的一个项目 从设计模式的角度理解 Zookeeper是基于观察者模式的 它负责存储大家都关心的数据 然后接受观察者的注册 一旦这些数据发生变化 则会通知已注
  • 华为OD机试 - 区块链文件转储系统(Java)

    题目描述 区块链底层存储是一个链式文件系统 由顺序的N个文件组成 每个文件的大小不一 依次为F1 F2 Fn 随着时间的推移 所占存储会越来越大 云平台考虑将区块链按文件转储到廉价的SATA盘 只有连续的区块链文件才能转储到SATA盘上 且
  • Unity Animation ---Unity中录制某个物体的运动到AnimationClip(一)

    在某些情况下 我们需要把物体的运动状态 材质变化等信息录制下来存储到Clip中 比如说 用到ITween DoTween等插件控制物体运动 然后想把运动的过程记录下来 就需要在Editor Runtime下进行一些操作来达到我们的目的 所幸
  • VsCode远程调试c++

    1 WSL安装 ubuntu18 04 或者直接连接远程的ubuntu服务器 windows10 安装WSL 参考文档 Install WSL Microsoft Docs 开始使用 WSL VS Code Microsoft Docs i
  • jq单击button修改input的value

    HTML代码 div 内容来源 div
  • 【深度学习】基于卷积神经网络(tensorflow)的人脸识别项目(二)

    活动地址 CSDN21天学习挑战赛 目录 前言 基本思路 关于环境 通过anaconda导入配置 数据集 训练集 验证机与测试集 划分规则 预处理 从指定路径读取训练数据 设置标签 按照指定图像大小调整尺寸 数据归一化 最值归一化 norm
  • 用户分享|当我升级了 CloudQuery 2.2.0 后......

    导读 7 月 13 日 CloudQuery 下文简称 CQ 2 2 0 版本正式发布 在看到官方文档对新版本的介绍后 马上进行安装测试 本文主要为大家介绍从 CQ 1 4 2 升级到 2 2 的考量因素 测试情况 分享一些实践经验 给大家
  • 十六种炫酷纯css加载动画(一)

    一个好的开篇 会给你这个项目增加不少分值 有没有遇到过打开页面加载一段时间 页面内容才加载出来 在等待加载的过程中页面却是空白页 给用户的体验特别不好 会让项目降一个档次 下面的十六种炫酷炸裂的css加载动画 会让你在等待的过程中 体验视觉