added transition() to rect height and y value