diff options
author | Annabel Dunstone Gray <annabel.m.gray@gmail.com> | 2018-09-21 20:55:14 +0300 |
---|---|---|
committer | Clement Ho <clemmakesapps@gmail.com> | 2018-09-21 20:55:14 +0300 |
commit | 911341153e1e1ae6cc661fa793c065cbdf3235d5 (patch) | |
tree | 95dd977e2cb6166f0669967e78e27ac6add864ee | |
parent | b7dfe76ea49221bceddc251331de7825934610d4 (diff) |
Align form labels following Bootstrap 4 docs
-rw-r--r-- | app/assets/stylesheets/bootstrap_migration.scss | 1 | ||||
-rw-r--r-- | app/views/admin/appearances/_form.html.haml | 6 | ||||
-rw-r--r-- | app/views/admin/applications/_form.html.haml | 4 | ||||
-rw-r--r-- | app/views/groups/_group_admin_settings.html.haml | 4 | ||||
-rw-r--r-- | app/views/groups/settings/_permissions.html.haml | 2 | ||||
-rw-r--r-- | app/views/shared/_visibility_level.html.haml | 2 | ||||
-rw-r--r-- | changelogs/unreleased/align-form-labels.yml | 5 |
7 files changed, 14 insertions, 10 deletions
diff --git a/app/assets/stylesheets/bootstrap_migration.scss b/app/assets/stylesheets/bootstrap_migration.scss index c91f5e279ea..af73954bd2e 100644 --- a/app/assets/stylesheets/bootstrap_migration.scss +++ b/app/assets/stylesheets/bootstrap_migration.scss @@ -93,7 +93,6 @@ hr { } .form-group.row .col-form-label { - padding-top: 0; // Bootstrap 4 aligns labels to the left // for horizontal forms @include media-breakpoint-up(md) { diff --git a/app/views/admin/appearances/_form.html.haml b/app/views/admin/appearances/_form.html.haml index d71dac2574c..cb67079853e 100644 --- a/app/views/admin/appearances/_form.html.haml +++ b/app/views/admin/appearances/_form.html.haml @@ -5,7 +5,7 @@ %legend Navigation bar: .form-group.row - = f.label :header_logo, 'Header logo', class: 'col-sm-2 col-form-label' + = f.label :header_logo, 'Header logo', class: 'col-sm-2 col-form-label pt-0' .col-sm-10 - if @appearance.header_logo? = image_tag @appearance.header_logo_url, class: 'appearance-light-logo-preview' @@ -22,7 +22,7 @@ %legend Favicon: .form-group.row - = f.label :favicon, 'Favicon', class: 'col-sm-2 col-form-label' + = f.label :favicon, 'Favicon', class: 'col-sm-2 col-form-label pt-0' .col-sm-10 - if @appearance.favicon? = image_tag @appearance.favicon_url, class: 'appearance-light-logo-preview' @@ -51,7 +51,7 @@ .hint Description parsed with #{link_to "GitLab Flavored Markdown", help_page_path('user/markdown'), target: '_blank'}. .form-group.row - = f.label :logo, class: 'col-sm-2 col-form-label' + = f.label :logo, class: 'col-sm-2 col-form-label pt-0' .col-sm-10 - if @appearance.logo? = image_tag @appearance.logo_url, class: 'appearance-logo-preview' diff --git a/app/views/admin/applications/_form.html.haml b/app/views/admin/applications/_form.html.haml index 585576ec799..12690343f6e 100644 --- a/app/views/admin/applications/_form.html.haml +++ b/app/views/admin/applications/_form.html.haml @@ -21,14 +21,14 @@ for local tests = content_tag :div, class: 'form-group row' do - = f.label :trusted, class: 'col-sm-2 col-form-label' + = f.label :trusted, class: 'col-sm-2 col-form-label pt-0' .col-sm-10 = f.check_box :trusted %span.form-text.text-muted Trusted applications are automatically authorized on GitLab OAuth flow. .form-group.row - = f.label :scopes, class: 'col-sm-2 col-form-label' + = f.label :scopes, class: 'col-sm-2 col-form-label pt-0' .col-sm-10 = render 'shared/tokens/scopes_form', prefix: 'doorkeeper_application', token: application, scopes: @scopes diff --git a/app/views/groups/_group_admin_settings.html.haml b/app/views/groups/_group_admin_settings.html.haml index 935a8889d79..ff59013ed67 100644 --- a/app/views/groups/_group_admin_settings.html.haml +++ b/app/views/groups/_group_admin_settings.html.haml @@ -1,5 +1,5 @@ .form-group.row - = f.label :lfs_enabled, 'Large File Storage', class: 'col-form-label col-sm-2' + = f.label :lfs_enabled, 'Large File Storage', class: 'col-form-label col-sm-2 pt-0' .col-sm-10 .form-check = f.check_box :lfs_enabled, checked: @group.lfs_enabled?, class: 'form-check-input' @@ -11,7 +11,7 @@ %span.descr This setting can be overridden in each project. .form-group.row - = f.label :require_two_factor_authentication, 'Two-factor authentication', class: 'col-form-label col-sm-2' + = f.label :require_two_factor_authentication, 'Two-factor authentication', class: 'col-form-label col-sm-2 pt-0' .col-sm-10 .form-check = f.check_box :require_two_factor_authentication, class: 'form-check-input' diff --git a/app/views/groups/settings/_permissions.html.haml b/app/views/groups/settings/_permissions.html.haml index ffce2d4b14f..8dc88ec446c 100644 --- a/app/views/groups/settings/_permissions.html.haml +++ b/app/views/groups/settings/_permissions.html.haml @@ -10,7 +10,7 @@ = render 'shared/allow_request_access', form: f .form-group.row - %label.col-form-label.col-sm-2 + %label.col-form-label.col-sm-2.pt-0 = s_('GroupSettings|Share with group lock') .col-sm-10 .form-check diff --git a/app/views/shared/_visibility_level.html.haml b/app/views/shared/_visibility_level.html.haml index 01ce1225b8d..ba37b37a3b1 100644 --- a/app/views/shared/_visibility_level.html.haml +++ b/app/views/shared/_visibility_level.html.haml @@ -2,7 +2,7 @@ .form-group.row.visibility-level-setting - if with_label - = f.label :visibility_level, class: 'col-form-label col-sm-2' do + = f.label :visibility_level, class: 'col-form-label col-sm-2 pt-0' do Visibility Level = link_to icon('question-circle'), help_page_path("public_access/public_access") %div{ :class => (with_label ? "col-sm-10" : "col-sm-12") } diff --git a/changelogs/unreleased/align-form-labels.yml b/changelogs/unreleased/align-form-labels.yml new file mode 100644 index 00000000000..fd781e3b910 --- /dev/null +++ b/changelogs/unreleased/align-form-labels.yml @@ -0,0 +1,5 @@ +--- +title: Align form labels following Bootstrap 4 docs +merge_request: 21752 +author: +type: fixed |