This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DOMAnimations { | |
/** | |
* Masque un élément avec un effet de repli | |
* @param {HTMLElement} element | |
* @param {Number} duration | |
* @returns {Promise<boolean>} | |
*/ | |
static slideUp (element, duration = 500) { | |
return new Promise(function (resolve, reject) { | |
element.style.height = element.offsetHeight + 'px' |