console
function* gen() {
const num1 = yield 1
console.log(num1)
const num2 = yield 2
console.log(num2)
return 3
}
const g = gen()
console.log(g.next()) // { value: 1, done: false }
console.log(g.next(11111))
// 11111
// { value: 2, done: false }
console.log(g.next(22222))
// 22222
// { value: 3, done: true }
<div class="plus">
<a href="#" class="bdr-ripple-ani-btn"><i class="fa fa-link"></i></a>
<div class="tooltip">
<p>Click Here</p>
<i class="fa fa-play"></i>
</div>
</div>
<a href="#" class="bdr-ripple-ani-btn pink two"><i class="fa fa-cog"></i></a>
<div class="glow-shadow"></div>
body {
background: #f2f2f2;
font-family: sans-serif;
}
.bdr-ripple-ani-btn {
display: block;
background: #FFF;
width: 48px;
height: 48px;
line-height: 48px;
text-align: center;
border-radius: 100%;
box-sizing: border-box;
color: #666;
animation: at-ripple 0.6s linear infinite;
overflow: hidden;
}
.bdr-ripple-ani-btn.pink {
background: #ff4081;
color:white;
animation: at-ripple-pink 0.6s linear infinite;
}
.bdr-ripple-ani-btn.two {
right: 300px;
z-index: 2;
position: fixed;
bottom: 50px;
}
.bdr-ripple-ani-btn i {
transform: rotate(0deg);
transition: 0.5s ease;
}
.bdr-ripple-ani-btn:hover i {
transform: rotate(180deg);
}
@-webkit-keyframes at-ripple {
0% {
box-shadow: 0 4px 10px rgba(102, 102, 102, 0.1), 0 0 0 0 rgba(102, 102, 102, 0.1), 0 0 0 5px rgba(102, 102, 102, 0.1), 0 0 0 10px rgba(102, 102, 102, 0.1);
}
100% {
box-shadow: 0 4px 10px rgba(102, 102, 102, 0.1), 0 0 0 5px rgba(102, 102, 102, 0.1), 0 0 0 10px rgba(102, 102, 102, 0.1), 0 0 0 20px rgba(102, 102, 102, 0);
}
}
@keyframes at-ripple {
0% {
box-shadow: 0 4px 10px rgba(102, 102, 102, 0.1), 0 0 0 0 rgba(102, 102, 102, 0.1), 0 0 0 5px rgba(102, 102, 102, 0.1), 0 0 0 10px rgba(102, 102, 102, 0.1);
}
100% {
box-shadow: 0 4px 10px rgba(102, 102, 102, 0.1), 0 0 0 5px rgba(102, 102, 102, 0.1), 0 0 0 10px rgba(102, 102, 102, 0.1), 0 0 0 20px rgba(102, 102, 102, 0);
}
}
@-webkit-keyframes at-ripple-pink {
0% {
box-shadow: 0 4px 10px rgba(255, 65, 130, 0.1), 0 0 0 0 rgba(255, 65, 130, 0.1), 0 0 0 5px rgba(255, 65, 130, 0.1), 0 0 0 10px rgba(255, 65, 130, 0.1);
}
100% {
box-shadow: 0 4px 10px rgba(255, 65, 130, 0.1), 0 0 0 5px rgba(255, 65, 130, 0.1), 0 0 0 10px rgba(255, 65, 130, 0.1), 0 0 0 20px rgba(255, 65, 130, 0);
}
}
@keyframes at-ripple-pink {
0% {
box-shadow: 0 4px 10px rgba(255, 65, 130, 0.1), 0 0 0 0 rgba(255, 65, 130, 0.1), 0 0 0 5px rgba(255, 65, 130, 0.1), 0 0 0 10px rgba(255, 65, 130, 0.1);
}
100% {
box-shadow: 0 4px 10px rgba(255, 65, 130, 0.1), 0 0 0 5px rgba(255, 65, 130, 0.1), 0 0 0 10px rgba(255, 65, 130, 0.1), 0 0 0 20px rgba(255, 65, 130, 0);
}
}
.plus {
position: relative;
z-index: 2;
position: fixed;
right: 24px;
bottom: 50px;
}
.plus:hover .tooltip {
visibility: visible;
opacity: 1;
}
.tooltip {
position:absolute;
bottom:6px;
right:65px;
display:table;
visibility: hidden;
opacity: 0;
transition: 0.5s;
white-space: nowrap;
}
.tooltip p {
color:#FFF;
background:rgba(51,51,51,0.5);
display:table-cell;
vertical-align:middle;
padding:10px;
border-radius:3px;
}
.tooltip i {
display:table-cell;
vertical-align:middle;
color:#333;
opacity:0.5;
}
.glow-shadow {
background:#fff;
width:100px;
height:100px;
left:50px;
margin-left:50px;
margin-top:15%;
border-radius:50%;
-webkit-animation: throb 1.5s infinite ease-in-out;
animation: glow 1.5s infinite ease-in-out;
}
@-webkit-keyframes glow {
0% {
-webkit-box-shadow: 0 0 50px 50px rgba(50, 160, 50, 0.9);
}
50% {
-webkit-box-shadow: 0 0 50px 0px rgba(50, 160, 50, .2);
}
100% {
-webkit-box-shadow: 0 0 50px 50px rgba(50, 160, 50, 0.9);
}
}
@keyframes glow {
0% {
box-shadow: 0 0 50px rgba(50, 160, 50, 0.9);
}
50% {
box-shadow: 0 0 50px rgba(50, 160, 50, .2);
}
100% {
box-shadow: 0 0 50px rgba(50, 160, 50, 0.9);
}
}