moving timeline positions to javascript