Make gradient elements optional.