covidwatchorg / portal

Covid Watch Portal web app for diagnosis verification
Apache License 2.0
8 stars 3 forks source link

Add password strength meter #523

Open veeara282 opened 4 years ago

veeara282 commented 4 years ago

Closes #247

Add a password strength meter to the "New password" fields in ChangePasswordModal and ResetPasswordModal using a PasswordStrengthModalInput, which composes ModalInput. This component will always display validation text, even when the password is valid.

Password strength indicator colors:

TODO:

veeara282 commented 4 years ago

We should also consider adding some default and personalized strings to the user_inputs argument.

The optional user_inputs argument is an array of strings that zxcvbn will treat as an extra dictionary. This can be whatever list of strings you like, but is meant for user inputs from other fields of the form, like name and email. That way a password that includes a user's personal information can be heavily penalized. This list is also good for site-specific vocabulary — Acme Brick Co. might want to include ['acme', 'brick', 'acmebrick', etc].