diff options
author | Dmitriy Zaporozhets <dzaporozhets@gitlab.com> | 2015-01-15 22:20:43 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dzaporozhets@gitlab.com> | 2015-01-15 22:20:43 +0300 |
commit | 089df35f027034c9cd24ab09ad51bff83ef13ad8 (patch) | |
tree | e0e1d3795d4827ebbc9fde3653a0b6d04e41be6f /app | |
parent | 5254de907da2c8cd5ff09ccc3ddeba7c2f55db4b (diff) | |
parent | b79ada97bb8e85c85472e0cee269a28c0e6d5ef7 (diff) |
Merge branch 'remove-password-strength-indicator' into 'master'
Remove password strength indicator
We were having the following issues:
- the indicator would sometimes stay red even if the password that was
entered was long enough;
- the indicator had a middle yellow signal: what does that mean?
- the red/green backgrounds were not color-blind-friendly.
See merge request !1399
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/application.js.coffee | 1 | ||||
-rw-r--r-- | app/assets/javascripts/password_strength.js.coffee | 31 | ||||
-rw-r--r-- | app/assets/stylesheets/sections/profile.scss | 17 | ||||
-rw-r--r-- | app/views/devise/passwords/edit.html.haml | 4 | ||||
-rw-r--r-- | app/views/devise/registrations/new.html.haml | 4 | ||||
-rw-r--r-- | app/views/profiles/passwords/edit.html.haml | 2 | ||||
-rw-r--r-- | app/views/profiles/passwords/new.html.haml | 2 |
7 files changed, 6 insertions, 55 deletions
diff --git a/app/assets/javascripts/application.js.coffee b/app/assets/javascripts/application.js.coffee index 6d038f772e9..747035a9923 100644 --- a/app/assets/javascripts/application.js.coffee +++ b/app/assets/javascripts/application.js.coffee @@ -18,7 +18,6 @@ #= require jquery.turbolinks #= require turbolinks #= require bootstrap -#= require password_strength #= require select2 #= require raphael #= require g.raphael-min diff --git a/app/assets/javascripts/password_strength.js.coffee b/app/assets/javascripts/password_strength.js.coffee deleted file mode 100644 index 825f5630266..00000000000 --- a/app/assets/javascripts/password_strength.js.coffee +++ /dev/null @@ -1,31 +0,0 @@ -#= require pwstrength-bootstrap-1.2.2 -overwritten_messages = - wordSimilarToUsername: "Your password should not contain your username" - -overwritten_rules = - wordSequences: false - -options = - showProgressBar: false - showVerdicts: false - showPopover: true - showErrors: true - showStatus: true - errorMessages: overwritten_messages - -$(document).ready -> - profileOptions = {} - profileOptions.ui = options - profileOptions.rules = - activated: overwritten_rules - - deviseOptions = {} - deviseOptions.common = - usernameField: "#user_username" - deviseOptions.ui = options - deviseOptions.rules = - activated: overwritten_rules - - $("#user_password_profile").pwstrength profileOptions - $("#user_password_sign_up").pwstrength deviseOptions - $("#user_password_recover").pwstrength deviseOptions diff --git a/app/assets/stylesheets/sections/profile.scss b/app/assets/stylesheets/sections/profile.scss index b9f4e317e9c..086875582f3 100644 --- a/app/assets/stylesheets/sections/profile.scss +++ b/app/assets/stylesheets/sections/profile.scss @@ -111,20 +111,3 @@ height: 50px; } } - -//CSS for password-strength indicator -#password-strength { - margin-bottom: 0; -} - -.has-success input { - background-color: #D6F1D7 !important; -} - -.has-error input { - background-color: #F3CECE !important; -} - -.has-warning input { - background-color: #FFE9A4 !important; -} diff --git a/app/views/devise/passwords/edit.html.haml b/app/views/devise/passwords/edit.html.haml index f6cbf9b82ba..1326cc0aac9 100644 --- a/app/views/devise/passwords/edit.html.haml +++ b/app/views/devise/passwords/edit.html.haml @@ -6,8 +6,8 @@ .devise-errors = devise_error_messages! = f.hidden_field :reset_password_token - .form-group#password-strength - = f.password_field :password, class: "form-control top", id: "user_password_recover", placeholder: "New password", required: true + %div + = f.password_field :password, class: "form-control top", placeholder: "New password", required: true %div = f.password_field :password_confirmation, class: "form-control bottom", placeholder: "Confirm new password", required: true .clearfix.append-bottom-10 diff --git a/app/views/devise/registrations/new.html.haml b/app/views/devise/registrations/new.html.haml index 123de881f59..d6a952f3dc5 100644 --- a/app/views/devise/registrations/new.html.haml +++ b/app/views/devise/registrations/new.html.haml @@ -11,8 +11,8 @@ = f.text_field :username, class: "form-control middle", placeholder: "Username", required: true %div = f.email_field :email, class: "form-control middle", placeholder: "Email", required: true - .form-group#password-strength - = f.password_field :password, class: "form-control middle", id: "user_password_sign_up", placeholder: "Password", required: true + %div + = f.password_field :password, class: "form-control middle", placeholder: "Password", required: true %div = f.password_field :password_confirmation, class: "form-control bottom", placeholder: "Confirm password", required: true %div diff --git a/app/views/profiles/passwords/edit.html.haml b/app/views/profiles/passwords/edit.html.haml index 425200ff523..2a7d317aa3e 100644 --- a/app/views/profiles/passwords/edit.html.haml +++ b/app/views/profiles/passwords/edit.html.haml @@ -24,7 +24,7 @@ .form-group = f.label :password, 'New password', class: 'control-label' .col-sm-10 - = f.password_field :password, required: true, class: 'form-control', id: 'user_password_profile' + = f.password_field :password, required: true, class: 'form-control' .form-group = f.label :password_confirmation, class: 'control-label' .col-sm-10 diff --git a/app/views/profiles/passwords/new.html.haml b/app/views/profiles/passwords/new.html.haml index 42d2d0db29c..aef7348fd20 100644 --- a/app/views/profiles/passwords/new.html.haml +++ b/app/views/profiles/passwords/new.html.haml @@ -16,7 +16,7 @@ .col-sm-10= f.password_field :current_password, required: true, class: 'form-control' .form-group = f.label :password, class: 'control-label' - .col-sm-10= f.password_field :password, required: true, class: 'form-control', id: 'user_password_profile' + .col-sm-10= f.password_field :password, required: true, class: 'form-control' .form-group = f.label :password_confirmation, class: 'control-label' .col-sm-10 |