summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryce Johnson <bryce@gitlab.com>2016-11-11 10:49:31 +0100
committerBryce Johnson <bryce@gitlab.com>2016-11-11 10:49:31 +0100
commit2bd0e1ed7b0e0f569ac17feaea2e826963269359 (patch)
treefb797e12cd30ab49ec29c3b9145ec5ee8efda907
parent5b695dbbda58323d3ea751bf4194f80e686ad067 (diff)
downloadgitlab-ce-login-tab-order-fix.tar.gz
Experiment with setting tabindex to +1.login-tab-order-fix
-rw-r--r--app/assets/stylesheets/pages/login.scss4
-rw-r--r--app/views/devise/sessions/_new_base.html.haml12
2 files changed, 8 insertions, 8 deletions
diff --git a/app/assets/stylesheets/pages/login.scss b/app/assets/stylesheets/pages/login.scss
index 10f67b47998..16b7d680427 100644
--- a/app/assets/stylesheets/pages/login.scss
+++ b/app/assets/stylesheets/pages/login.scss
@@ -257,7 +257,7 @@
// For sign in pane only, to improve tab order, the following removes the submit button from
// normal document flow and pins it to the bottom of the form. For context, see !6867 & !6928
-
+/*
.login-box {
.new_user {
position: relative;
@@ -277,4 +277,4 @@
bottom: 0;
}
}
-
+*/
diff --git a/app/views/devise/sessions/_new_base.html.haml b/app/views/devise/sessions/_new_base.html.haml
index 21b89580818..13bfb7cdafd 100644
--- a/app/views/devise/sessions/_new_base.html.haml
+++ b/app/views/devise/sessions/_new_base.html.haml
@@ -1,16 +1,16 @@
= form_for(resource, as: resource_name, url: session_path(resource_name), html: { class: 'new_user gl-show-field-errors', 'aria-live' => 'assertive'}) do |f|
%div.form-group
= f.label "Username or email", for: :login
- = f.text_field :login, class: "form-control top", autofocus: "autofocus", autocapitalize: "off", autocorrect: "off", required: true, title: "This field is required."
+ = f.text_field :login, class: "form-control top", autofocus: "autofocus", autocapitalize: "off", autocorrect: "off", required: true, title: "This field is required.", tabindex: 1
%div.form-group
= f.label :password
- = f.password_field :password, class: "form-control bottom", required: true, title: "This field is required."
- %div.submit-container.move-submit-down
- = f.submit "Sign in", class: "btn btn-save"
+ = f.password_field :password, class: "form-control bottom", required: true, title: "This field is required.", tabindex: 2
- if devise_mapping.rememberable?
.remember-me.checkbox
%label{for: "user_remember_me"}
- = f.check_box :remember_me
+ = f.check_box :remember_me, tabindex: 3
%span Remember me
.pull-right.forgot-password
- = link_to "Forgot your password?", new_password_path(resource_name)
+ = link_to "Forgot your password?", new_password_path(resource_name), tabindex: 5
+ %div.submit-container
+ = f.submit "Sign in", class: "btn btn-save", tabindex: 4