blind changes - need updated sytleguide for verifying

This commit is contained in:
Ulf Gebhardt 2019-05-07 14:13:45 +02:00
parent e26b2eabcc
commit 34fa8cf29a
No known key found for this signature in database
GPG Key ID: 44C888923CC8E7F3
2 changed files with 7 additions and 9 deletions

View File

@ -19,7 +19,7 @@
type="password"
:label="$t('settings.security.change-password.label-new-password-confirm')"
/>
<!--<password-strength :password="newPassword" @change="e => passwordSecure = e.isSecure"/>-->
<password-strength :password="formData.newPassword" @change="handlePasswordStrength"/>
<ds-space margin-top="base">
<ds-button
:loading="loading"
@ -73,13 +73,9 @@ export default {
},
methods: {
async handleInput(data) {
//return 'abcabc1234567!' // this.formData.newPassword
console.log('validation')
console.log(data)
if (
this.formData.newPassword &&
this.formData.newPassword === this.formData.confirmPassword
) {
if (data.newPassword && data.newPassword === data.confirmPassword) {
this.disabled = false
} else {
this.disabled = true
@ -105,6 +101,9 @@ export default {
} finally {
this.loading = false
}
},
handlePasswordStrength(e) {
console.log(e.isSecure)
}
}
}

View File

@ -45,7 +45,7 @@ export default {
* @return {Number} Password Strength Score
*/
passwordStrength() {
/*const score = !isEmpty(this.pass) ? zxcvbn(this.pass).score : 0
const score = !isEmpty(this.pass) ? zxcvbn(this.pass).score : 0
if (score !== this.lastScore) {
this.lastScore = score
this.$emit('change', {
@ -53,8 +53,7 @@ export default {
isSecure: Boolean(score >= 3)
})
}
return score*/
return 0
return score
},
strengthClass() {
return `strength-${this.passwordStrength}`