Lottie Animation End of Playback Identifier

Hey guys,

Does anyone know of a way to get Wix to identify that the playback of a Lottie animation has ended?

I need my animation to play once and then be hidden.

Currently, the code is as follows:

$w ( “#gOff” ). show ();
$w ( “#gOff” ). loop = false ;
$w ( “#gOff” ). play (() => {
$w ( “#gOff” ). hide ();
});

There is nothing in the wix lottie api that gives you this information, but if you know the length of the animation you could use setTimeout as a workaround to hide it after a particualr amount of time has passed.

Others that use lottie more often may have more insight

Thank you Amanda!