mirror of
https://github.com/home-assistant/core.git
synced 2025-07-18 02:37:08 +00:00
Clear password from input when logging out
This commit is contained in:
parent
5316762a64
commit
d4e9f26983
@ -112,10 +112,20 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
listeners: {
|
listeners: {
|
||||||
'passwordInput.keydown': 'passwordKeyDown',
|
'keydown': 'passwordKeyDown',
|
||||||
'loginButton.click': 'validatePassword',
|
'loginButton.click': 'validatePassword',
|
||||||
},
|
},
|
||||||
|
|
||||||
|
observers: [
|
||||||
|
'validatingChanged(isValidating, isInvalid)',
|
||||||
|
],
|
||||||
|
|
||||||
|
validatingChanged: function(isValidating, isInvalid) {
|
||||||
|
if (!isValidating && !isInvalid) {
|
||||||
|
this.$.passwordInput.value = '';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
isValidatingChanged: function(newVal) {
|
isValidatingChanged: function(newVal) {
|
||||||
if (!newVal) {
|
if (!newVal) {
|
||||||
this.debounce('focus-password', function() {
|
this.debounce('focus-password', function() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user