Set a maximum height to auto-expanding text fields

Limit the height of an auto-expanding text field such that the buttons
below the textarea do not scroll off-screen.

Bug: 58657
Change-Id: I3fbed3f7764a8331cdfc313dfdaa781340032ab5