[1030889] Added jsdocs and used a one liner for trimming the animation name