airbnb / lottie-web

Render After Effects animations natively on Web, Android and iOS, and React Native. http://airbnb.io/lottie/
MIT License
29.85k stars 2.85k forks source link

[BUG]: dotLottie player makes icon disappear after animation is played in comparison with lottie player #3023

Open mstakh opened 10 months ago

mstakh commented 10 months ago

Environment:

What did you do? Please explain the steps you took before you encountered the problem.

Two players behave differently. In case of dotLottie player animation is played once (no loop, only autoplay) and than image disappears. In case of lottie player (same configs, no loop, only autoplay), animation is played and final frame remains.

What did you expect to happen? On both players, when animation is finished and no loop specified, remain last frame

What actually happened? Please include as much relevant detail as possible. dotLottie player plays the animation and hides/removes last frame in case no loop specified

Please provide a download link to the After Effects file that demonstrates the problem.

bodymovin commented 10 months ago

hi, can you report this issue on the lottieFiles repository? it seems that lottie-web is working correctly

yikZero commented 5 months ago

I encountered the same issue. I was initially using lottie-react along with a .json format, but I switched to the dotlottie format because it's tinier. Consequently, I switched to the @dotlottie/react-player.

When I was using lottie-react and .json, everything worked perfectly. However, upon switching to dotlottie and @dotlottie/react-player, disappearances occur when I hover to the last frame, and the graphic reappears and rewinds when moving away. All the code remained consistent throughout.

Solution

Upon troubleshooting, I found that the final frame in my AE file was blank, which turned out to be the cause. I am unsure of why the two players behave differently in processing the last frame. Nonetheless, as long as the final frame in AE is not blank, this issue should not arise.

@mstakh @bodymovin