got rid of the easing
This commit is contained in:
parent
e42a570690
commit
d3fc7598f2
1 changed files with 3 additions and 3 deletions
|
@ -59,13 +59,13 @@ document.getElementById('dots').setAttribute('d',d);
|
|||
document.getElementById('dots').setAttribute('stroke-dasharray',`0.0000001 ${2*m}`);
|
||||
|
||||
function easeInOutSine(x) {
|
||||
return -(Math.cos(Math.PI * x) - 1) / 2;
|
||||
|
||||
return -(Math.cos(Math.PI * x) - 1) / 2;
|
||||
}
|
||||
|
||||
function frame() {
|
||||
const period = 1000;
|
||||
const t = (new Date()-0)/period % 1000;
|
||||
document.getElementById('dots').setAttribute('stroke-dashoffset',easeInOutSine(t)*m);
|
||||
document.getElementById('dots').setAttribute('stroke-dashoffset',(t)*m);
|
||||
requestAnimationFrame(frame);
|
||||
}
|
||||
frame();
|
Loading…
Add table
Add a link
Reference in a new issue