17 lines
393 B
JavaScript
17 lines
393 B
JavaScript
const anime = require('animejs').default;
|
|
|
|
const { TIMES } = require('../../constants');
|
|
|
|
function Invert(id) {
|
|
return anime({
|
|
targets: [document.getElementById(id)],
|
|
rotate: 180,
|
|
delay: TIMES.TARGET_DELAY_MS,
|
|
duration: TIMES.TARGET_DURATION_MS * 0.45,
|
|
easing: 'easeInOutElastic',
|
|
direction: 'alternate',
|
|
});
|
|
}
|
|
|
|
module.exports = Invert;
|