div+css实现dna螺旋loading加载动画效果代码

代码语言:html

所属分类:加载滚动

代码描述:div+css实现dna螺旋loading加载动画效果代码

代码标签: div css dna 螺旋 loading 加载 动画

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en" >

<head>

  <meta charset="UTF-8">

  
  
<style>
* {
  box-sizing: border-box;
}

html {
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 100vw;
  min-height: 100vh;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 90vw;
  height: 90vh;
  background: grey;
}

.items {
  display: flex;
  flex-direction: column;
  align-items: center;
  perspective: 500px;
  animation: rotate infinite linear 20s;
}

.item {
  position: relative;
  display: inline-block;
  overflow: visible;
  width: 50px;
  height: 5px;
  margin: 2px 0;
  display: flex;
  justify-content: space-between;
  animation: rotate2 infinite linear 2s, hue linear infinite 2s;
  background: linear-gradient(0deg, transparent 0%, transparent 40%, #2a6ae9 50%, transparent 60%, transparent 100%);
}
.item:before, .item:after {
  content: "";
  position: relative;
  border-radius: 50%;
  width: 5px;
  height: 5px;
  display: block;
  background: white;
  box-shadow: 0px 0px 10px 2px #2a6ae9, 0px 0px 0px 1px black;
}
.item:before {
  animation-delay: 1s;
}

.item:nth-child(n+1) {
  animation-delay: -4.87s;
}

.item:nth-child(n+2) {
  animation-delay: -4.74s;
}

.item:nth-child(n+3) {
  animation-delay: -4.61s;
}

.item:nth-child(n+4) {
  animation-delay: -4.48s;
}

.item:nth-child.........完整代码请登录后点击上方下载按钮下载查看

网友评论0