Skip to main content
cngx-src documentation

onTransitionDone

Functioncore/utils

projects/core/utils/transition.util.ts

Description#

Listens for the longest CSS transition on an element, then invokes onDone.

Automatically falls back to a timeout if transitionend never fires.

Signature#

onTransitionDone(el: HTMLElement, onDone)

Parameters#

@paramelHTMLElement
@paramonDone

Returns#

void

A cleanup function that removes the listener and clears the fallback timer.