mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-18 03:26:07 +08:00
added more neuron activation
This commit is contained in:
parent
7c8a41137a
commit
17cca6b693
1 changed files with 18 additions and 2 deletions
|
@ -181,16 +181,32 @@ async function flashLevel(): Promise<void> {
|
|||
|
||||
barEl.text(parseInt(barEl.text()) + 1);
|
||||
|
||||
const rand = Math.random() * 2 - 1;
|
||||
const rand2 = Math.random() + 1;
|
||||
|
||||
barEl
|
||||
.stop(true, true)
|
||||
.css({
|
||||
backgroundColor: themecolors.main,
|
||||
// transform: "scale(1.5) rotate(10deg)",
|
||||
borderSpacing: 100,
|
||||
})
|
||||
.animate(
|
||||
{
|
||||
backgroundColor: themecolors.sub,
|
||||
borderSpacing: 0,
|
||||
},
|
||||
1000,
|
||||
"easeOutExpo"
|
||||
{
|
||||
step(step) {
|
||||
barEl.css(
|
||||
"transform",
|
||||
`scale(${1 + (step / 200) * rand2}) rotate(${
|
||||
(step / 10) * rand
|
||||
}deg)`
|
||||
);
|
||||
},
|
||||
duration: 2000,
|
||||
easing: "easeOutCubic",
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue