Handle empty text masks.
This allows themes to prevent text from being sent during password
entry. To enable, edit theme.hjson and set $.customization.defaults
.general.passwordChar to "". e.g.,
{
...
customization: {
defaults: {
general: {
passwordChar: ""
}
}
...
}
}
This commit is contained in:
@@ -68,8 +68,9 @@ EditTextView.prototype.onKeyPress = function(ch, key) {
|
|||||||
} else {
|
} else {
|
||||||
this.cursorPos.col += 1;
|
this.cursorPos.col += 1;
|
||||||
|
|
||||||
if(this.textMaskChar) {
|
if(_.isString(this.textMaskChar)) {
|
||||||
this.client.term.write(this.textMaskChar);
|
if(this.textMaskChar.length > 0)
|
||||||
|
this.client.term.write(this.textMaskChar);
|
||||||
} else {
|
} else {
|
||||||
this.client.term.write(ch);
|
this.client.term.write(ch);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user