🔐 Sid Gifari File Manager Pro
v8.0.5 | 2026-08-07 01:06:39 | PHP 8.2.32
📂
/ (Root)
/
home
/
eliteewa
/
public_html
/
wp-content
/
themes
/
blocksy
/
static
/
js
/
frontend
/
helpers
📍 /home/eliteewa/public_html/wp-content/themes/blocksy/static/js/frontend/helpers
🔄 Refresh
✏️
Editing: when-transition-ends.js
Writable
export function whenTransitionEnds(el, cb) { let timeoutId = null let didEnd = false const end = () => { clearTimeout(timeoutId) el.removeEventListener('transitionend', onEnd) if (!didEnd) { didEnd = true cb() } } const onEnd = (e) => { // Very important check. // // Sometimes transitionend event is propagated from children to parent // and the children transition might be shorter than the parent's one // and thus the parent's transitionend event is triggered too early. if (e.target === el) { end() } } const transitionDuration = parseFloat( getComputedStyle(el).transitionDuration ) if (!transitionDuration) { cb() return } el.addEventListener('transitionend', onEnd) timeoutId = setTimeout(() => { end() }, transitionDuration * 1000) }
💾 Save Changes
❌ Cancel