Add field-optional class for marking inputs as optional