Commit 450a39ed authored by Phil Hughes's avatar Phil Hughes

Fixed alignment on issuable new form

Fixes #13802
parent 4087bd16
...@@ -316,3 +316,9 @@ ...@@ -316,3 +316,9 @@
color: #8c8c8c; color: #8c8c8c;
} }
} }
.issuable-form-padding-top {
@media (min-width: $screen-sm-min) {
padding-top: 7px;
}
}
...@@ -70,13 +70,13 @@ ...@@ -70,13 +70,13 @@
- if can? current_user, :admin_milestone, issuable.project - if can? current_user, :admin_milestone, issuable.project
= link_to 'Create new milestone', new_namespace_project_milestone_path(issuable.project.namespace, issuable.project), target: :blank = link_to 'Create new milestone', new_namespace_project_milestone_path(issuable.project.namespace, issuable.project), target: :blank
.form-group .form-group
- has_labels = issuable.project.labels.any?
= f.label :label_ids, "Labels", class: 'control-label' = f.label :label_ids, "Labels", class: 'control-label'
.col-sm-10 .col-sm-10{ class: ('issuable-form-padding-top' if !has_labels) }
- if issuable.project.labels.any? - if has_labels
= f.collection_select :label_ids, issuable.project.labels.all, :id, :name, = f.collection_select :label_ids, issuable.project.labels.all, :id, :name,
{ selected: issuable.label_ids }, multiple: true, class: 'select2', data: { placeholder: "Select labels" } { selected: issuable.label_ids }, multiple: true, class: 'select2', data: { placeholder: "Select labels" }
- else - else
.prepend-top-10
%span.light No labels yet. %span.light No labels yet.
   
- if can? current_user, :admin_label, issuable.project - if can? current_user, :admin_label, issuable.project
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment