If database textfield is empty, container box collapse

If I got you right, this video by the Code Queen should answer it for you