新增 动画
This commit is contained in:
parent
6a6a855373
commit
d0b2815367
|
@ -0,0 +1,59 @@
|
||||||
|
<template>
|
||||||
|
<div class="dots">
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
<div />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.dots {
|
||||||
|
width: 3em;
|
||||||
|
height: 3em;
|
||||||
|
display: grid;
|
||||||
|
grid-template-rows: repeat(3, 1fr);
|
||||||
|
grid-template-columns: repeat(3, 1fr);
|
||||||
|
justify-items: center;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dots > div {
|
||||||
|
width: 0.5em;
|
||||||
|
height: 0.5em;
|
||||||
|
background-color: #3cefff;
|
||||||
|
border-radius: 50%;
|
||||||
|
animation: fade 1.5s alternate ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dots > div:nth-of-type(2),
|
||||||
|
.dots > div:nth-of-type(4) {
|
||||||
|
animation-delay: 0.25s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dots > div:nth-of-type(3),
|
||||||
|
.dots > div:nth-of-type(5),
|
||||||
|
.dots > div:nth-of-type(7) {
|
||||||
|
animation-delay: 0.5s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dots > div:nth-of-type(6),
|
||||||
|
.dots > div:nth-of-type(8) {
|
||||||
|
animation-delay: 0.75s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dots > div:nth-of-type(9) {
|
||||||
|
animation-delay: 1s;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fade {
|
||||||
|
to {
|
||||||
|
opacity: 0.2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,44 @@
|
||||||
|
<template>
|
||||||
|
<div />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
div {
|
||||||
|
position: relative;
|
||||||
|
width: 2em;
|
||||||
|
height: 2em;
|
||||||
|
border: 3px solid #3cefff;
|
||||||
|
overflow: hidden;
|
||||||
|
animation: spin 3s ease infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
div::before {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
top: -3px;
|
||||||
|
left: -3px;
|
||||||
|
width: 2em;
|
||||||
|
height: 2em;
|
||||||
|
background-color: hsla(185, 100%, 62%, 0.75);
|
||||||
|
transform-origin: center bottom;
|
||||||
|
transform: scaleY(1);
|
||||||
|
animation: fill 3s linear infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes spin {
|
||||||
|
50%,
|
||||||
|
100% {
|
||||||
|
transform: rotate(360deg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fill {
|
||||||
|
25%,
|
||||||
|
50% {
|
||||||
|
transform: scaleY(0);
|
||||||
|
}
|
||||||
|
100% {
|
||||||
|
transform: scaleY(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,51 @@
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<span />
|
||||||
|
<span />
|
||||||
|
<span />
|
||||||
|
<span />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
div {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: row nowrap;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
width: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
width: 0.3em;
|
||||||
|
height: 1em;
|
||||||
|
background-color: #3cefff;
|
||||||
|
}
|
||||||
|
|
||||||
|
span:nth-of-type(1) {
|
||||||
|
animation: grow 1s -0.45s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
span:nth-of-type(2) {
|
||||||
|
animation: grow 1s -0.3s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
span:nth-of-type(3) {
|
||||||
|
animation: grow 1s -0.15s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
span:nth-of-type(4) {
|
||||||
|
animation: grow 1s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes grow {
|
||||||
|
0%,
|
||||||
|
100% {
|
||||||
|
transform: scaleY(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
50% {
|
||||||
|
transform: scaleY(2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
Loading…
Reference in New Issue