css3+html5实现用户界面加载效果

源码 

<!doctype html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<style>
			@font-face {
				font-family: "font_wrl";
				src: url(img/rtrxnfht.TTF);
			}

			@keyframes myprogress {
				0% {
					opacity: 0.2;
					border-color: yellowgreen;
					background: yellowgreen;
					width: 0%;
				}

				60% {
					opacity: 0.6;
					border-color: yellowgreen;
					background: yellowgreen;
					width: 60%;
				}

				100% {
					opacity: 1.0;
					border-color: yellowgreen;
					background: yellowgreen;
					width: 100%;
				}
			}

			@keyframes myTransform {
				0% {
					transform: scaleY(1);
				}

				20% {
					transform: scaleY(2);
				}

				21% {
					transform: scaleY(1);
				}

				100% {
					transform: scaleY(1);
				}
			}

			* {
				margin: 0;
				padding: 0;
			}

			#divMain {
				position: fixed;
				background: rgba(0, 0, 0, .45);
				width: 100%;
				height: 100%;
			}

			ul {
				width: auto;
				position: fixed;
				top: 50%;
				left: 50%;
				margin-left: -22px;
			}

			ul>li {
				list-style: none;
				margin: auto 2px;
				float: left;
				height: 20px;
				width: 5px;
				background: yellowgreen;
				transform-origin: 50% 70%;
			}

			li:nth-child(1) {
				animation: myTransform 1.5s ease-in-out 0s infinite backwards;
			}

			li:nth-child(2) {
				animation: myTransform 1.5s ease-in-out .2s infinite backwards;
			}

			li:nth-child(3) {
				animation: myTransform 1.5s ease-in-out .4s infinite backwards;
			}

			li:nth-child(4) {
				animation: myTransform 1.5s ease-in-out .6s infinite backwards;
			}

			li:nth-child(5) {
				animation: myTransform 1.5s ease-in-out .8s infinite backwards;
			}

			.loadtext {
				width: 150px;
				color: yellowgreen;
				position: fixed;
				left: 50%;
				margin-left: -60px;
				top: 50%;
				margin-top: 30px;
				text-align: center;
				font-family: "font_wrl";
				letter-spacing: 2px;
			}

			#myprogress {
				height: 20px;
				border: 1px solid yellowgreen;
				position: fixed;
				bottom: 50px;
				border-radius: 5px;
				background: #9ACD32;
				animation: myprogress 5s linear infinite;
			}

			#myprogressborder {
				height: 20px;
				width: 100%;
				border: 1px solid yellowgreen;
				position: fixed;
				bottom: 50px;
				border-radius: 20px;
				line-height: 20px;
				color: #fff;
				font-family: "font_wrl";
				text-align: center;
				box-shadow: 0 0 0.5em #fff;
			}
		</style>
	</head>

	<body>
		<div style="background: url(https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1600749017341&di=af5b9b0e1f839dcdb98836c711dded87&imgtype=0&src=http%3A%2F%2Fyouimg1.c-ctrip.com%2Ftarget%2Ftg%2F457%2F111%2F427%2F5b4fcb385d7d4bbdb96938e8090503b4.jpg) no-repeat; background-size: cover;height: 100%; width: 100%;display: block;position: absolute;"></div>
		<div id="divMain">
			<ul>
				<li></li>
				<li></li>
				<li></li>
				<li></li>
				<li></li>
			</ul>
			<span class="loadtext">用户界面加载中...</span>

			<div id="myprogress">
			</div>
			<div id="myprogressborder">
				当前进度:100%
			</div>
		</div>
	</body>

</html>

 

  • 2
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

JackieDYH

谢谢您嘞!我会继续加油地

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值