1、html 部分:
<div id="refershDiv" class="refershDiv">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100">
<rect transform="rotate(0 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(30 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.083s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(60 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.166s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(90 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.25s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(120 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.333s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(150 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.416s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(180 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.5s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(210 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.583s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(240 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.666s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(270 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.75s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(300 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.833s" repeatCount="indefinite"></animate>
</rect>
<rect transform="rotate(330 50 50) translate(0 -25)">
<animate attributeName="opacity" from="1" to="0" dur="1s" begin="0.916s" repeatCount="indefinite"></animate>
</rect>
</svg>
</div>

2、css部分:

#refershDiv{text-align: center;position: absolute;width: 100%;left:;top: 45%;}
.refershDiv svg {
fill: #a0a0a0;
width: 80px;
height: 80px;
}
.refershDiv svg rect {
x: 47.5;
y:;
rx:;
ry:;
width: 5px;
height: 18px;
}

不需要图片,css+svg绘制动态loading加载图标的更多相关文章

  1. CSS动画实例:Loading加载动画效果(一)

    一些网站或者APP在加载新东西的时候,往往会给出一个好看有趣的Loading图,大部分的Loading样式都可以使用CSS3制作出来,它不仅比直接使用gif图简单方便,还能节省加载时间和空间.下面介绍 ...

  2. CSS动画实例:Loading加载动画效果(三)

    3.小圆型Loading 这类Loading动画的基本思想是:在呈现容器中定义1个或多个子层,再对每个子层进行样式定义,使得其均显示为一个实心圆形,最后编写关键帧动画控制,使得各个实心圆或者大小发生改 ...

  3. 使用SVG图像作为loading加载 以保证图像高清不模糊

    使用教程 接下来设计达人网小编为大家讲解这个使用方法,其实是相当简单的. STEP 1: 复制你想要的SVG加载动画代码到<body>里面,小编随意复制一个代码如下:<svg ver ...

  4. css 动态导入css文件 @import 动态js加载 都是静态的

    @import "http://apps.bdimg.com/libs/bootstrap/3.3.4/css/bootstrap.css" /*-防止各大cdn公共库加载地址失效 ...

  5. JS获取图片的缩略图,并且动态的加载多张图片

    找了好多资料也没有找到该死的ie的解决办法,最后放弃了ie <!DOCTYPE html> <html> <head> <meta charset=" ...

  6. 判断脚本,图片,CSS,iframe等是否加载完成

    1.图片 <img id="MyImg" src="src"/>jquery实现:$("#MyImg").load(functi ...

  7. QT自定义控件系列(二) --- Loading加载动画控件

    本系列主要使用Qt painter来实现一些基础控件.主要是对平时自行编写的一些自定义控件的总结. 为了简洁.低耦合,我们尽量不使用图片,qrc,ui等文件,而只使用c++的.h和.cpp文件. 由于 ...

  8. jquery加载数据时显示loading加载动画特效

    插件下载:http://www.htmleaf.com/jQuery/Layout-Interface/201505061788.html 插件使用: 使用该loading加载插件首先要引入jQuer ...

  9. loading加载和layer.js

    layer.js中的loading加载 l本篇主要介绍layerjs中的loading加载在实际项目中的应用 1.使用的技术 前端:HTML5+CSS3+JS+layer.js 后端:.net 2.遇 ...

随机推荐

  1. git的安装方法

    下载:https://git-scm.com/downloads

  2. 洛谷P1603 斯诺登的密码

    https://www.luogu.org/problem/P1603 #include<bits/stdc++.h> using namespace std; struct s { st ...

  3. 手动添加ubuntu服务

    在/etc/init.d/目录下创建一个简单的服务脚本,假设脚本名为hello #!/bin/sh case "$1" in start) # start 的代码 ;; stop) ...

  4. 安装php-zbarcode的步骤方法

    1 安装ImageMagick依赖 yum install ImageMagick ImageMagick-devel 2 安装zbar拓展 wget -c http://jaist.dl.sourc ...

  5. 基于Java+HttpClient+TestNG的接口自动化测试框架(八)------ 针对文件的处理

    在实际的接口测试中,有时需要根据情况进行文件的上传和下载.在文件数量比较小的时候,我们当然可以直接处理(比如若干个接口都用一个文件).但是,如果我们上传的文件需要使用不同文件夹里不同的文件,而且数量又 ...

  6. linux 创建svn版本库,并在svn上配置checkstyle做代码风格检查

    一.创建SVN版本库 1.安装svn服务器 yum install subversion 2.查看版本 svnserve --version 3.建立SVN版本库目录(即你的SVN服务器里面的文件存放 ...

  7. Android 开发 assets和raw

    在Android Project中,有两个文件夹的数据是不会被编译,以原型的方式打包到APK中,这两个文件夹就是 assets 和 res/raw/ 相同点: 1.数据不会编译成二进制字节码. 2.可 ...

  8. JQ 获取浏览器窗口宽高

    $(window).height(); // 浏览器时下窗口可视区域高度 $(document).height(); //浏览器时下窗口文档的高度 $(document.body).height(); ...

  9. 不能暴露服务给外部环境,因为nginx-ingress-control启动失败

    不能暴露服务给外部环境,因为nginx-ingress-control启动失败 待办 rancher 和k8s中的端口冲突,nginx-ingress-control都需要使用80端口 以及443端口 ...

  10. 路飞-git操作

    复习 """ 1.pip换源 - 采用国内源下载,速度快 2.虚拟环境 - 可以为项目单独配置开发环境,方便管理依赖模块及模块的版本迭代 3.后台项目重构目录结构 4.后 ...