gitlab-org--gitlab-foss/app/views/profiles/keys/_form.html.haml
Robert Speicher 7a2370f740 Standardize the way we check for and display form errors
- Some views had a "Close" button. We've removed this, because we don't
  want users accidentally hiding the validation errors and not knowing
  what needs to be fixed.
- Some views used `li`, some used `p`, some used `span`. We've
  standardized on `li`.
- Some views only showed the first error. We've standardized on showing
  all of them.
- Some views added an `#error_explanation` div, which we've made
  standard.
2016-04-04 21:37:07 -04:00

13 lines
443 B
Text

%div
= form_for [:profile, @key], html: { class: 'js-requires-input' } do |f|
= form_errors(@key)
.form-group
= f.label :key, class: 'label-light'
= f.text_area :key, class: "form-control", rows: 8, required: true
.form-group
= f.label :title, class: 'label-light'
= f.text_field :title, class: "form-control", required: true
.prepend-top-default
= f.submit 'Add key', class: "btn btn-create"